diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/s390/include/asm/page.h | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/arch/s390/include/asm/page.h b/arch/s390/include/asm/page.h index 75ce9b065f9f..5d64fb7619cc 100644 --- a/arch/s390/include/asm/page.h +++ b/arch/s390/include/asm/page.h | |||
@@ -32,7 +32,7 @@ | |||
32 | 32 | ||
33 | void storage_key_init_range(unsigned long start, unsigned long end); | 33 | void storage_key_init_range(unsigned long start, unsigned long end); |
34 | 34 | ||
35 | static unsigned long pfmf(unsigned long function, unsigned long address) | 35 | static inline unsigned long pfmf(unsigned long function, unsigned long address) |
36 | { | 36 | { |
37 | asm volatile( | 37 | asm volatile( |
38 | " .insn rre,0xb9af0000,%[function],%[address]" | 38 | " .insn rre,0xb9af0000,%[function],%[address]" |
@@ -44,17 +44,13 @@ static unsigned long pfmf(unsigned long function, unsigned long address) | |||
44 | 44 | ||
45 | static inline void clear_page(void *page) | 45 | static inline void clear_page(void *page) |
46 | { | 46 | { |
47 | if (MACHINE_HAS_PFMF) { | 47 | register unsigned long reg1 asm ("1") = 0; |
48 | pfmf(0x10000, (unsigned long)page); | 48 | register void *reg2 asm ("2") = page; |
49 | } else { | 49 | register unsigned long reg3 asm ("3") = 4096; |
50 | register unsigned long reg1 asm ("1") = 0; | 50 | asm volatile( |
51 | register void *reg2 asm ("2") = page; | 51 | " mvcl 2,0" |
52 | register unsigned long reg3 asm ("3") = 4096; | 52 | : "+d" (reg2), "+d" (reg3) : "d" (reg1) |
53 | asm volatile( | 53 | : "memory", "cc"); |
54 | " mvcl 2,0" | ||
55 | : "+d" (reg2), "+d" (reg3) : "d" (reg1) | ||
56 | : "memory", "cc"); | ||
57 | } | ||
58 | } | 54 | } |
59 | 55 | ||
60 | static inline void copy_page(void *to, void *from) | 56 | static inline void copy_page(void *to, void *from) |