summaryrefslogtreecommitdiffstats
path: root/arch/parisc/include/asm/io.h
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2017-06-08 22:09:18 +0200
committerHelge Deller <deller@gmx.de>2017-06-09 11:34:54 +0200
commit3f4fb1084d9453c0b0fa2a7f51fe7e7d99b6722f (patch)
treefaa66a4d5cfb5a9cc613efdae3f80771413e9c7c /arch/parisc/include/asm/io.h
parentparisc: Avoid zeroing gr[0] in fixup_exception() (diff)
downloadlinux-3f4fb1084d9453c0b0fa2a7f51fe7e7d99b6722f.tar.xz
linux-3f4fb1084d9453c0b0fa2a7f51fe7e7d99b6722f.zip
parisc: Don't hardcode PSW values in gsc_*() functions
Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'arch/parisc/include/asm/io.h')
-rw-r--r--arch/parisc/include/asm/io.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/arch/parisc/include/asm/io.h b/arch/parisc/include/asm/io.h
index 1a16f1d1075f..af98254f7257 100644
--- a/arch/parisc/include/asm/io.h
+++ b/arch/parisc/include/asm/io.h
@@ -34,10 +34,10 @@ static inline unsigned char gsc_readb(unsigned long addr)
unsigned char ret;
__asm__ __volatile__(
- " rsm 2,%0\n"
+ " rsm %3,%0\n"
" ldbx 0(%2),%1\n"
" mtsm %0\n"
- : "=&r" (flags), "=r" (ret) : "r" (addr) );
+ : "=&r" (flags), "=r" (ret) : "r" (addr), "i" (PSW_SM_D) );
return ret;
}
@@ -48,10 +48,10 @@ static inline unsigned short gsc_readw(unsigned long addr)
unsigned short ret;
__asm__ __volatile__(
- " rsm 2,%0\n"
+ " rsm %3,%0\n"
" ldhx 0(%2),%1\n"
" mtsm %0\n"
- : "=&r" (flags), "=r" (ret) : "r" (addr) );
+ : "=&r" (flags), "=r" (ret) : "r" (addr), "i" (PSW_SM_D) );
return ret;
}
@@ -87,20 +87,20 @@ static inline void gsc_writeb(unsigned char val, unsigned long addr)
{
long flags;
__asm__ __volatile__(
- " rsm 2,%0\n"
+ " rsm %3,%0\n"
" stbs %1,0(%2)\n"
" mtsm %0\n"
- : "=&r" (flags) : "r" (val), "r" (addr) );
+ : "=&r" (flags) : "r" (val), "r" (addr), "i" (PSW_SM_D) );
}
static inline void gsc_writew(unsigned short val, unsigned long addr)
{
long flags;
__asm__ __volatile__(
- " rsm 2,%0\n"
+ " rsm %3,%0\n"
" sths %1,0(%2)\n"
" mtsm %0\n"
- : "=&r" (flags) : "r" (val), "r" (addr) );
+ : "=&r" (flags) : "r" (val), "r" (addr), "i" (PSW_SM_D) );
}
static inline void gsc_writel(unsigned int val, unsigned long addr)