From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: MIME-Version: 1.0 In-Reply-To: References: <201802161853.FKQRlYLX%fengguang.wu@intel.com> From: Greentime Hu Date: Wed, 21 Feb 2018 20:02:42 +0800 Message-ID: Subject: Re: [PATCH v7 02/37] asm-generic/io.h: move ioremap_nocache/ioremap_uc/ioremap_wc/ioremap_wt out of ifndef CONFIG_MMU Content-Type: text/plain; charset="UTF-8" To: Arnd Bergmann Cc: kbuild test robot , kbuild-all@01.org, Greentime , Linux Kernel Mailing List , linux-arch , Thomas Gleixner , Jason Cooper , Marc Zyngier , Rob Herring , netdev , Vincent Chen , DTML , Al Viro , David Howells , Will Deacon , Daniel Lezcano , linux-serial@vger.kernel.org, Geert Uytterhoeven , Linus Walleij , Mark Rutland , Greg KH , Guo Ren , Randy Dunlap , David Miller , Jonas Bonn , Stefan Kristiansson , Stafford Horne , Vincent Chen List-ID: 2018-02-21 19:37 GMT+08:00 Arnd Bergmann : > On Wed, Feb 21, 2018 at 12:21 PM, Greentime Hu wrote: >> 2018-02-16 18:47 GMT+08:00 kbuild test robot : > >> >> From: Greentime Hu >> Date: Wed, 21 Feb 2018 14:21:23 +0800 >> Subject: [PATCH] xtensa: add ioremap_nocache declaration before include >> asm-generic/io.h. >> >> A future commit for the nds32 architecture bootstrap("asm-generic/io.h: >> move ioremap_nocache/ioremap_uc/ioremap_wc/ioremap_wt out of ifndef >> CONFIG_MMU") will move the ioremap_nocache out of the CONFIG_MMU ifdef. >> This means that in order to suppress re-definition errors we need to >> setup #define's before importing asm-generic/io.h. >> >> Signed-off-by: Greentime Hu > > Don't you need to override both ioremap and ioremap_nocache? Hi, Arnd: It can fix the building error to override ioremap_nocache. Why should I override ioremap? Do you mean remove this implementation " static inline void __iomem *ioremap(unsigned long offset, unsigned long size) { return ioremap_nocache(offset, size); } " and replace it with #define ioremap ioremap_nocache Because I think this patch is just used to fix the build error. Thank you. >> --- >> arch/xtensa/include/asm/io.h | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/arch/xtensa/include/asm/io.h b/arch/xtensa/include/asm/io.h >> index c38e5a732d86..acc5bb2cf1c7 100644 >> --- a/arch/xtensa/include/asm/io.h >> +++ b/arch/xtensa/include/asm/io.h >> @@ -52,6 +52,7 @@ static inline void __iomem *ioremap_cache(unsigned >> long offset, >> return xtensa_ioremap_cache(offset, size); >> } >> #define ioremap_cache ioremap_cache >> +#define ioremap_nocache ioremap_nocache >> >> #define ioremap_wc ioremap_nocache