summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include/asm/io.h
diff options
context:
space:
mode:
authorMichael Ellerman <michael@ellerman.id.au>2013-11-29 13:27:18 +1100
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2013-12-05 16:08:21 +1100
commit0150a3dd92fc45b599bf2442b47d40921b4aa2d2 (patch)
tree284f52f36938fff298c3e0a0ae1fe55f78db6842 /arch/powerpc/include/asm/io.h
parentfb48dc22824daaa60ff1d6a6c9e22c79112dfb8e (diff)
downloadtalos-op-linux-0150a3dd92fc45b599bf2442b47d40921b4aa2d2.tar.gz
talos-op-linux-0150a3dd92fc45b599bf2442b47d40921b4aa2d2.zip
powerpc: Add real mode cache inhibited IO accessors
These accessors allow us to do cache inhibited accesses when in real mode. They should only be used in real mode. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/include/asm/io.h')
-rw-r--r--arch/powerpc/include/asm/io.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/io.h b/arch/powerpc/include/asm/io.h
index 575fbf81fad0..97d3869991ca 100644
--- a/arch/powerpc/include/asm/io.h
+++ b/arch/powerpc/include/asm/io.h
@@ -191,8 +191,24 @@ DEF_MMIO_OUT_D(out_le32, 32, stw);
#endif /* __BIG_ENDIAN */
+/*
+ * Cache inhibitied accessors for use in real mode, you don't want to use these
+ * unless you know what you're doing.
+ *
+ * NB. These use the cpu byte ordering.
+ */
+DEF_MMIO_OUT_X(out_rm8, 8, stbcix);
+DEF_MMIO_OUT_X(out_rm16, 16, sthcix);
+DEF_MMIO_OUT_X(out_rm32, 32, stwcix);
+DEF_MMIO_IN_X(in_rm8, 8, lbzcix);
+DEF_MMIO_IN_X(in_rm16, 16, lhzcix);
+DEF_MMIO_IN_X(in_rm32, 32, lwzcix);
+
#ifdef __powerpc64__
+DEF_MMIO_OUT_X(out_rm64, 64, stdcix);
+DEF_MMIO_IN_X(in_rm64, 64, ldcix);
+
#ifdef __BIG_ENDIAN__
DEF_MMIO_OUT_D(out_be64, 64, std);
DEF_MMIO_IN_D(in_be64, 64, ld);
OpenPOWER on IntegriCloud