summaryrefslogtreecommitdiffstats
path: root/drivers/misc/sgi-xp/xpc_sn2.c
diff options
context:
space:
mode:
authorDean Nelson2008-11-06 00:27:22 +0100
committerH. Peter Anvin2008-11-06 05:32:20 +0100
commit6c1c325de908cbc444cf284f59c3a892161012e9 (patch)
tree9e1eaff01127dbe50fee94cbb75b35621c32c215 /drivers/misc/sgi-xp/xpc_sn2.c
parentx86: uv: Add UV reserved page bios call (diff)
downloadkernel-qcow2-linux-6c1c325de908cbc444cf284f59c3a892161012e9.tar.gz
kernel-qcow2-linux-6c1c325de908cbc444cf284f59c3a892161012e9.tar.xz
kernel-qcow2-linux-6c1c325de908cbc444cf284f59c3a892161012e9.zip
sgi-xp: define xp_expand_memprotect() and xp_restrict_memprotect()
Define xp_expand_memprotect() and xp_restrict_memprotect() so they can be tailered to the hardware they are run on. Signed-off-by: Dean Nelson <dcn@sgi.com> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'drivers/misc/sgi-xp/xpc_sn2.c')
-rw-r--r--drivers/misc/sgi-xp/xpc_sn2.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/drivers/misc/sgi-xp/xpc_sn2.c b/drivers/misc/sgi-xp/xpc_sn2.c
index b4882ccf6344..73b7fb8de47a 100644
--- a/drivers/misc/sgi-xp/xpc_sn2.c
+++ b/drivers/misc/sgi-xp/xpc_sn2.c
@@ -553,22 +553,17 @@ static u64 xpc_prot_vec_sn2[MAX_NUMNODES];
static enum xp_retval
xpc_allow_amo_ops_sn2(struct amo *amos_page)
{
- u64 nasid_array = 0;
- int ret;
+ enum xp_retval ret = xpSuccess;
/*
* On SHUB 1.1, we cannot call sn_change_memprotect() since the BIST
* collides with memory operations. On those systems we call
* xpc_allow_amo_ops_shub_wars_1_1_sn2() instead.
*/
- if (!enable_shub_wars_1_1()) {
- ret = sn_change_memprotect(ia64_tpa((u64)amos_page), PAGE_SIZE,
- SN_MEMPROT_ACCESS_CLASS_1,
- &nasid_array);
- if (ret != 0)
- return xpSalError;
- }
- return xpSuccess;
+ if (!enable_shub_wars_1_1())
+ ret = xp_expand_memprotect(ia64_tpa((u64)amos_page), PAGE_SIZE);
+
+ return ret;
}
/*