diff options
Diffstat (limited to 'include/asm-ia64/sn')
-rw-r--r-- | include/asm-ia64/sn/sn_sal.h | 6 | ||||
-rw-r--r-- | include/asm-ia64/sn/xp.h | 22 | ||||
-rw-r--r-- | include/asm-ia64/sn/xpc.h | 4 |
3 files changed, 21 insertions, 11 deletions
diff --git a/include/asm-ia64/sn/sn_sal.h b/include/asm-ia64/sn/sn_sal.h index bd4452bda357..ba826b3f75bb 100644 --- a/include/asm-ia64/sn/sn_sal.h +++ b/include/asm-ia64/sn/sn_sal.h | |||
@@ -706,12 +706,9 @@ static inline int | |||
706 | sn_change_memprotect(u64 paddr, u64 len, u64 perms, u64 *nasid_array) | 706 | sn_change_memprotect(u64 paddr, u64 len, u64 perms, u64 *nasid_array) |
707 | { | 707 | { |
708 | struct ia64_sal_retval ret_stuff; | 708 | struct ia64_sal_retval ret_stuff; |
709 | unsigned long irq_flags; | ||
710 | 709 | ||
711 | local_irq_save(irq_flags); | ||
712 | ia64_sal_oemcall_nolock(&ret_stuff, SN_SAL_MEMPROTECT, paddr, len, | 710 | ia64_sal_oemcall_nolock(&ret_stuff, SN_SAL_MEMPROTECT, paddr, len, |
713 | (u64)nasid_array, perms, 0, 0, 0); | 711 | (u64)nasid_array, perms, 0, 0, 0); |
714 | local_irq_restore(irq_flags); | ||
715 | return ret_stuff.status; | 712 | return ret_stuff.status; |
716 | } | 713 | } |
717 | #define SN_MEMPROT_ACCESS_CLASS_0 0x14a080 | 714 | #define SN_MEMPROT_ACCESS_CLASS_0 0x14a080 |
@@ -1143,12 +1140,9 @@ static inline int | |||
1143 | sn_inject_error(u64 paddr, u64 *data, u64 *ecc) | 1140 | sn_inject_error(u64 paddr, u64 *data, u64 *ecc) |
1144 | { | 1141 | { |
1145 | struct ia64_sal_retval ret_stuff; | 1142 | struct ia64_sal_retval ret_stuff; |
1146 | unsigned long irq_flags; | ||
1147 | 1143 | ||
1148 | local_irq_save(irq_flags); | ||
1149 | ia64_sal_oemcall_nolock(&ret_stuff, SN_SAL_INJECT_ERROR, paddr, (u64)data, | 1144 | ia64_sal_oemcall_nolock(&ret_stuff, SN_SAL_INJECT_ERROR, paddr, (u64)data, |
1150 | (u64)ecc, 0, 0, 0, 0); | 1145 | (u64)ecc, 0, 0, 0, 0); |
1151 | local_irq_restore(irq_flags); | ||
1152 | return ret_stuff.status; | 1146 | return ret_stuff.status; |
1153 | } | 1147 | } |
1154 | 1148 | ||
diff --git a/include/asm-ia64/sn/xp.h b/include/asm-ia64/sn/xp.h index 9bd2f9bf329b..6f807e0193b7 100644 --- a/include/asm-ia64/sn/xp.h +++ b/include/asm-ia64/sn/xp.h | |||
@@ -60,23 +60,37 @@ | |||
60 | * the bte_copy() once in the hope that the failure was due to a temporary | 60 | * the bte_copy() once in the hope that the failure was due to a temporary |
61 | * aberration (i.e., the link going down temporarily). | 61 | * aberration (i.e., the link going down temporarily). |
62 | * | 62 | * |
63 | * See bte_copy for definition of the input parameters. | 63 | * src - physical address of the source of the transfer. |
64 | * vdst - virtual address of the destination of the transfer. | ||
65 | * len - number of bytes to transfer from source to destination. | ||
66 | * mode - see bte_copy() for definition. | ||
67 | * notification - see bte_copy() for definition. | ||
64 | * | 68 | * |
65 | * Note: xp_bte_copy() should never be called while holding a spinlock. | 69 | * Note: xp_bte_copy() should never be called while holding a spinlock. |
66 | */ | 70 | */ |
67 | static inline bte_result_t | 71 | static inline bte_result_t |
68 | xp_bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification) | 72 | xp_bte_copy(u64 src, u64 vdst, u64 len, u64 mode, void *notification) |
69 | { | 73 | { |
70 | bte_result_t ret; | 74 | bte_result_t ret; |
75 | u64 pdst = ia64_tpa(vdst); | ||
71 | 76 | ||
72 | 77 | ||
73 | ret = bte_copy(src, dest, len, mode, notification); | 78 | /* |
79 | * Ensure that the physically mapped memory is contiguous. | ||
80 | * | ||
81 | * We do this by ensuring that the memory is from region 7 only. | ||
82 | * If the need should arise to use memory from one of the other | ||
83 | * regions, then modify the BUG_ON() statement to ensure that the | ||
84 | * memory from that region is always physically contiguous. | ||
85 | */ | ||
86 | BUG_ON(REGION_NUMBER(vdst) != RGN_KERNEL); | ||
74 | 87 | ||
88 | ret = bte_copy(src, pdst, len, mode, notification); | ||
75 | if (ret != BTE_SUCCESS) { | 89 | if (ret != BTE_SUCCESS) { |
76 | if (!in_interrupt()) { | 90 | if (!in_interrupt()) { |
77 | cond_resched(); | 91 | cond_resched(); |
78 | } | 92 | } |
79 | ret = bte_copy(src, dest, len, mode, notification); | 93 | ret = bte_copy(src, pdst, len, mode, notification); |
80 | } | 94 | } |
81 | 95 | ||
82 | return ret; | 96 | return ret; |
diff --git a/include/asm-ia64/sn/xpc.h b/include/asm-ia64/sn/xpc.h index b72af597878d..35e1386f37ab 100644 --- a/include/asm-ia64/sn/xpc.h +++ b/include/asm-ia64/sn/xpc.h | |||
@@ -683,7 +683,9 @@ extern struct xpc_vars *xpc_vars; | |||
683 | extern struct xpc_rsvd_page *xpc_rsvd_page; | 683 | extern struct xpc_rsvd_page *xpc_rsvd_page; |
684 | extern struct xpc_vars_part *xpc_vars_part; | 684 | extern struct xpc_vars_part *xpc_vars_part; |
685 | extern struct xpc_partition xpc_partitions[XP_MAX_PARTITIONS + 1]; | 685 | extern struct xpc_partition xpc_partitions[XP_MAX_PARTITIONS + 1]; |
686 | extern char xpc_remote_copy_buffer[]; | 686 | extern char *xpc_remote_copy_buffer; |
687 | extern void *xpc_remote_copy_buffer_base; | ||
688 | extern void *xpc_kmalloc_cacheline_aligned(size_t, gfp_t, void **); | ||
687 | extern struct xpc_rsvd_page *xpc_rsvd_page_init(void); | 689 | extern struct xpc_rsvd_page *xpc_rsvd_page_init(void); |
688 | extern void xpc_allow_IPI_ops(void); | 690 | extern void xpc_allow_IPI_ops(void); |
689 | extern void xpc_restrict_IPI_ops(void); | 691 | extern void xpc_restrict_IPI_ops(void); |