[patch 05/30] PS3: Use ioremap_flags

Takao Shinohara shin at sm.sony.co.jp
Thu Jun 14 12:31:29 EST 2007


On 2007/06/13, at 3:43, Geoff Levand wrote:
> -	spu->problem = ioremap(spu->problem_phys,
> -		sizeof(struct spu_problem));
> +	spu->problem = (__force void *)ioremap_flags(spu->problem_phys,
> +		sizeof(struct spu_problem), _PAGE_NO_CACHE);
> +
>  	if (!spu->problem) {
>  		pr_debug("%s:%d: ioremap problem failed\n", __func__, __LINE__);
>  		goto fail_ioremap;
>  	}
>
> -	spu->priv2 = ioremap(spu_pdata(spu)->priv2_addr,
> -		sizeof(struct spu_priv2));
> +	spu->priv2 = (__force void 
> *)ioremap_flags(spu_pdata(spu)->priv2_addr,
> +		sizeof(struct spu_priv2), _PAGE_NO_CACHE);
> +
>  	if (!spu->priv2) {
>  		pr_debug("%s:%d: ioremap priv2 failed\n", __func__, __LINE__);
>  		goto fail_ioremap;

spu->problem and spu->priv2 needs _PAGE_GUARDED, because they are
MMIO register region.

-- Takao Shinohara




More information about the Linuxppc-dev mailing list