[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <RAoD2jLl8oMTRwtBmAR-ulz4YFtWgKdqDy27huG3gwHewm5Os2Ce0lD8sECV1w0lIjH3wAQDdecTbSnJKwfQCpnnYYA39NKuiUi00xiBoB0=@pm.me>
Date: Sat, 20 Jun 2020 09:34:43 +0000
From: Alexander Lobakin <alobakin@...me>
To: Thomas Bogendoerfer <tsbogend@...ha.franken.de>
Cc: Alexandre Belloni <alexandre.belloni@...tlin.com>,
Paul Burton <paulburton@...nel.org>,
Alexander Lobakin <alobakin@...me>, linux-mips@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH mips-next 1/3] MIPS: generic/ip32: io: fix __mem_ioswabq()
*readq() family operates with u64 arguments, so they need 64-bit
byteswaps.
Correct macros for Generic MIPS and IP-32 to match other machines'
implementations.
Signed-off-by: Alexander Lobakin <alobakin@...me>
---
arch/mips/include/asm/mach-generic/mangle-port.h | 2 +-
arch/mips/include/asm/mach-ip32/mangle-port.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/mips/include/asm/mach-generic/mangle-port.h b/arch/mips/include/asm/mach-generic/mangle-port.h
index f49dc990214b..e4daf163706c 100644
--- a/arch/mips/include/asm/mach-generic/mangle-port.h
+++ b/arch/mips/include/asm/mach-generic/mangle-port.h
@@ -45,7 +45,7 @@
# define ioswabl(a, x) (x)
# define __mem_ioswabl(a, x) cpu_to_le32(x)
# define ioswabq(a, x) (x)
-# define __mem_ioswabq(a, x) cpu_to_le32(x)
+# define __mem_ioswabq(a, x) cpu_to_le64(x)
#endif
diff --git a/arch/mips/include/asm/mach-ip32/mangle-port.h b/arch/mips/include/asm/mach-ip32/mangle-port.h
index f1d0f1756a9f..c5ef72ccb0d5 100644
--- a/arch/mips/include/asm/mach-ip32/mangle-port.h
+++ b/arch/mips/include/asm/mach-ip32/mangle-port.h
@@ -21,6 +21,6 @@
# define ioswabl(a, x) (x)
# define __mem_ioswabl(a, x) cpu_to_le32(x)
# define ioswabq(a, x) (x)
-# define __mem_ioswabq(a, x) cpu_to_le32(x)
+# define __mem_ioswabq(a, x) cpu_to_le64(x)
#endif /* __ASM_MACH_IP32_MANGLE_PORT_H */
--
2.27.0
Powered by blists - more mailing lists