]> www.infradead.org Git - users/jedix/linux-maple.git/commit
hexagon: simplify asm/io.h for !HAS_IOPORT
authorArnd Bergmann <arnd@arndb.de>
Mon, 28 Oct 2024 21:05:41 +0000 (21:05 +0000)
committerArnd Bergmann <arnd@arndb.de>
Mon, 28 Oct 2024 21:44:29 +0000 (21:44 +0000)
commita8cb1e92d29096b1fe58ef6fdcee699196eac1bd
tree70751aa2793b529ebee2a84480d7534579ce20d8
parent6e3f5e626cb9a046133eef9fbaa82ac67cfa9ff2
hexagon: simplify asm/io.h for !HAS_IOPORT

Hexagon fails to build after the final patch that makes CONFIG_HAS_IOPORT
optional:

In file included from arch/hexagon/include/asm/io.h:328:
include/asm-generic/io.h:854:18: error: static declaration of 'ioread8' follows non-static declaration
  854 | static inline u8 ioread8(const volatile void __iomem *addr)
      |                  ^
include/asm-generic/io.h:853:17: note: expanded from macro 'ioread8'
  853 | #define ioread8 ioread8
      |                 ^
include/asm-generic/iomap.h:29:21: note: previous declaration is here
   29 | extern unsigned int ioread8(const void __iomem *);
      |                     ^

As it turns out, most of its asm/io.h and lib/io.c files is redundant now,
and just removing all that makes it build again.

As with the other architectures, defining the __raw_readl()/__raw_writel()
type functions instead of the non-__raw ones is better here for consistency.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
arch/hexagon/Kconfig
arch/hexagon/include/asm/io.h
arch/hexagon/lib/Makefile
arch/hexagon/lib/io.c [deleted file]