Commit 53f7c545 authored by Geoff Levand's avatar Geoff Levand Committed by Paul Mackerras

[POWERPC] PS3: Map SPU regions as non-guarded

Use ioremap_flags() to map SPU regions as non-guarded.
Change the use of _ioremap() to ioremap_flags().

CC: Arnd Bergmann <arnd.bergmann@de.ibm.com>
CC: Masato Noguchi <Masato.Noguchi@jp.sony.com>
CC: Takao Shinohara <shin@sm.sony.co.jp>
Signed-off-by: default avatarGeert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Signed-off-by: default avatarGeoff Levand <geoffrey.levand@am.sony.com>
Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
parent 1322810c
...@@ -273,7 +273,7 @@ void __init ps3_map_htab(void) ...@@ -273,7 +273,7 @@ void __init ps3_map_htab(void)
result = lv1_map_htab(0, &htab_addr); result = lv1_map_htab(0, &htab_addr);
htab = (struct hash_pte *)__ioremap(htab_addr, htab_size, htab = (__force struct hash_pte *)ioremap_flags(htab_addr, htab_size,
pgprot_val(PAGE_READONLY_X)); pgprot_val(PAGE_READONLY_X));
DBG("%s:%d: lpar %016lxh, virt %016lxh\n", __func__, __LINE__, DBG("%s:%d: lpar %016lxh, virt %016lxh\n", __func__, __LINE__,
......
...@@ -182,15 +182,18 @@ static int __init setup_areas(struct spu *spu) ...@@ -182,15 +182,18 @@ static int __init setup_areas(struct spu *spu)
{ {
struct table {char* name; unsigned long addr; unsigned long size;}; struct table {char* name; unsigned long addr; unsigned long size;};
spu_pdata(spu)->shadow = __ioremap( spu_pdata(spu)->shadow = ioremap_flags(spu_pdata(spu)->shadow_addr,
spu_pdata(spu)->shadow_addr, sizeof(struct spe_shadow), sizeof(struct spe_shadow),
pgprot_val(PAGE_READONLY) | _PAGE_NO_CACHE | _PAGE_GUARDED); pgprot_val(PAGE_READONLY) |
_PAGE_NO_CACHE);
if (!spu_pdata(spu)->shadow) { if (!spu_pdata(spu)->shadow) {
pr_debug("%s:%d: ioremap shadow failed\n", __func__, __LINE__); pr_debug("%s:%d: ioremap shadow failed\n", __func__, __LINE__);
goto fail_ioremap; goto fail_ioremap;
} }
spu->local_store = ioremap(spu->local_store_phys, LS_SIZE); spu->local_store = (__force void *)ioremap_flags(spu->local_store_phys,
LS_SIZE, _PAGE_NO_CACHE);
if (!spu->local_store) { if (!spu->local_store) {
pr_debug("%s:%d: ioremap local_store failed\n", pr_debug("%s:%d: ioremap local_store failed\n",
__func__, __LINE__); __func__, __LINE__);
...@@ -199,6 +202,7 @@ static int __init setup_areas(struct spu *spu) ...@@ -199,6 +202,7 @@ static int __init setup_areas(struct spu *spu)
spu->problem = ioremap(spu->problem_phys, spu->problem = ioremap(spu->problem_phys,
sizeof(struct spu_problem)); sizeof(struct spu_problem));
if (!spu->problem) { if (!spu->problem) {
pr_debug("%s:%d: ioremap problem failed\n", __func__, __LINE__); pr_debug("%s:%d: ioremap problem failed\n", __func__, __LINE__);
goto fail_ioremap; goto fail_ioremap;
...@@ -206,6 +210,7 @@ static int __init setup_areas(struct spu *spu) ...@@ -206,6 +210,7 @@ static int __init setup_areas(struct spu *spu)
spu->priv2 = ioremap(spu_pdata(spu)->priv2_addr, spu->priv2 = ioremap(spu_pdata(spu)->priv2_addr,
sizeof(struct spu_priv2)); sizeof(struct spu_priv2));
if (!spu->priv2) { if (!spu->priv2) {
pr_debug("%s:%d: ioremap priv2 failed\n", __func__, __LINE__); pr_debug("%s:%d: ioremap priv2 failed\n", __func__, __LINE__);
goto fail_ioremap; goto fail_ioremap;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment