Skip to content

Commit

Permalink
parisc: hide ioread64 declaration on 32-bit
Browse files Browse the repository at this point in the history
The definition of ioread64 etc is hidden on 32-bit, but the declaration
remained by accident, which led to the generic definition getting left
out:

ERROR: modpost: "ioread64" [drivers/pci/switch/switchtec.ko] undefined!

Hide the declaration and #define under the same #ifdef.

Reported-by: kernel test robot <lkp@intel.com>
Fixes: 77bfc8b ("parisc: Remove 64bit access on 32bit machines")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
  • Loading branch information
Arnd Bergmann committed Sep 12, 2022
1 parent 97c318b commit fdc5beb
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/parisc/include/asm/io.h
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,7 @@ extern void outsl (unsigned long port, const void *src, unsigned long count);
* value for either 32 or 64 bit mode */
#define F_EXTEND(x) ((unsigned long)((x) | (0xffffffff00000000ULL)))

#ifdef CONFIG_64BIT
#define ioread64 ioread64
#define ioread64be ioread64be
#define iowrite64 iowrite64
Expand All @@ -235,6 +236,7 @@ extern u64 ioread64(const void __iomem *addr);
extern u64 ioread64be(const void __iomem *addr);
extern void iowrite64(u64 val, void __iomem *addr);
extern void iowrite64be(u64 val, void __iomem *addr);
#endif

#include <asm-generic/iomap.h>
/*
Expand Down

0 comments on commit fdc5beb

Please sign in to comment.