Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1697623

[PATCH v5 2/6] powerpc: iomap.c: introduce io{read|write}64_{lo_hi|hi_lo}

From Logan Gunthorpe <logang@deltatee.com>
Newsgroups linux.kernel
Subject [PATCH v5 2/6] powerpc: iomap.c: introduce io{read|write}64_{lo_hi|hi_lo}
Date 2017-07-27 01:30 +0200
Message-ID <u7DUB-6Ny-1@gated-at.bofh.it> (permalink)
References <u7DKV-6Kh-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


These functions will be introduced into the generic iomap.c so
they can deal with PIO accesses in hi-lo/lo-hi variants. Thus,
the powerpc version of iomap.c will need to provide the same
functions even though, in this arch, they are identical to the
regular io{read|write}64 functions.
---
 arch/powerpc/kernel/iomap.c | 40 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)

diff --git a/arch/powerpc/kernel/iomap.c b/arch/powerpc/kernel/iomap.c
index a1854d1ded8b..b43dbadfd24f 100644
--- a/arch/powerpc/kernel/iomap.c
+++ b/arch/powerpc/kernel/iomap.c
@@ -44,12 +44,32 @@ u64 ioread64(void __iomem *addr)
 {
 	return readq(addr);
 }
+u64 ioread64_lo_hi(void __iomem *addr)
+{
+	return readq(addr);
+}
+u64 ioread64_hi_lo(void __iomem *addr)
+{
+	return readq(addr);
+}
 u64 ioread64be(void __iomem *addr)
 {
 	return readq_be(addr);
 }
+u64 ioread64be_lo_hi(void __iomem *addr)
+{
+	return readq_be(addr);
+}
+u64 ioread64be_hi_lo(void __iomem *addr)
+{
+	return readq_be(addr);
+}
 EXPORT_SYMBOL(ioread64);
+EXPORT_SYMBOL(ioread64_lo_hi);
+EXPORT_SYMBOL(ioread64_hi_lo);
 EXPORT_SYMBOL(ioread64be);
+EXPORT_SYMBOL(ioread64be_lo_hi);
+EXPORT_SYMBOL(ioread64be_hi_lo);
 #endif /* __powerpc64__ */
 
 void iowrite8(u8 val, void __iomem *addr)
@@ -82,12 +102,32 @@ void iowrite64(u64 val, void __iomem *addr)
 {
 	writeq(val, addr);
 }
+void iowrite64_lo_hi(u64 val, void __iomem *addr)
+{
+	writeq(val, addr);
+}
+void iowrite64_hi_lo(u64 val, void __iomem *addr)
+{
+	writeq(val, addr);
+}
 void iowrite64be(u64 val, void __iomem *addr)
 {
 	writeq_be(val, addr);
 }
+void iowrite64be_lo_hi(u64 val, void __iomem *addr)
+{
+	writeq_be(val, addr);
+}
+void iowrite64be_hi_lo(u64 val, void __iomem *addr)
+{
+	writeq_be(val, addr);
+}
 EXPORT_SYMBOL(iowrite64);
+EXPORT_SYMBOL(iowrite64_lo_hi);
+EXPORT_SYMBOL(iowrite64_hi_lo);
 EXPORT_SYMBOL(iowrite64be);
+EXPORT_SYMBOL(iowrite64be_lo_hi);
+EXPORT_SYMBOL(iowrite64be_hi_lo);
 #endif /* __powerpc64__ */
 
 /*
-- 
2.11.0

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v5 0/6] make io{read|write}64 globally usable Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:20 +0200
  [PATCH v5 1/6] powerpc: io.h: move iomap.h include so that it can use readq/writeq defs Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:20 +0200
  [PATCH v5 2/6] powerpc: iomap.c: introduce io{read|write}64_{lo_hi|hi_lo} Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:30 +0200
  [PATCH v5 5/6] ntb: ntb_hw_intel: use io-64-nonatomic instead of in-driver hacks Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:30 +0200
  [PATCH v5 3/6] iomap: introduce io{read|write}64_{lo_hi|hi_lo} Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:30 +0200
    Re: [PATCH v5 3/6] iomap: introduce io{read|write}64_{lo_hi|hi_lo} Andy Shevchenko <andy.shevchenko@gmail.com> - 2017-07-30 18:10 +0200
  [PATCH v5 4/6] io-64-nonatomic: add io{read|write}64[be]{_lo_hi|_hi_lo} macros Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:30 +0200
  [PATCH v5 6/6] crypto: caam: cleanup CONFIG_64BIT ifdefs when using io{read|write}64 Logan Gunthorpe <logang@deltatee.com> - 2017-07-27 01:30 +0200
  Re: [PATCH v5 0/6] make io{read|write}64 globally usable Horia Geantă <horia.geanta@nxp.com> - 2017-07-31 12:30 +0200

csiph-web