Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1518478 > unrolled thread
| Started by | Sudip Mukherjee <sudipm.mukherjee@gmail.com> |
|---|---|
| First post | 2016-11-09 21:50 +0100 |
| Last post | 2016-11-10 13:40 +0100 |
| Articles | 3 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH v2] MIPS: fix duplicate define Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2016-11-09 21:50 +0100
Re: [PATCH v2] MIPS: fix duplicate define kbuild test robot <lkp@intel.com> - 2016-11-10 13:30 +0100
Re: [PATCH v2] MIPS: fix duplicate define Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2016-11-10 13:40 +0100
| From | Sudip Mukherjee <sudipm.mukherjee@gmail.com> |
|---|---|
| Date | 2016-11-09 21:50 +0100 |
| Subject | [PATCH v2] MIPS: fix duplicate define |
| Message-ID | <sBHYK-3NU-37@gated-at.bofh.it> |
The mips build of ip27_defconfig is failing with the error:
In file included from ../arch/mips/include/asm/mach-ip27/spaces.h:29:0,
from ../arch/mips/include/asm/page.h:12,
from ../arch/mips/vdso/vdso.h:26,
from ../arch/mips/vdso/gettimeofday.c:11:
../arch/mips/include/asm/mach-generic/spaces.h:28:0:
error: "CAC_BASE" redefined [-Werror]
#define CAC_BASE _AC(0x80000000, UL)
In file included from ../arch/mips/include/asm/page.h:12:0,
from ../arch/mips/vdso/vdso.h:26,
from ../arch/mips/vdso/gettimeofday.c:11:
../arch/mips/include/asm/mach-ip27/spaces.h:22:0:
note: this is the location of the previous definition
#define CAC_BASE 0xa800000000000000
Add a condition to check if CAC_BASE is already defined, and define it
only if it is not yet defined.
Fixes: 3ffc17d8768b ("MIPS: Adjust MIPS64 CAC_BASE to reflect Config.K0")
Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk>
---
v2: corrected a silly mistake of overlooking #else
Build log is at:
https://travis-ci.org/sudipm-mukherjee/parport/jobs/174134289
arch/mips/include/asm/mach-generic/spaces.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/mips/include/asm/mach-generic/spaces.h b/arch/mips/include/asm/mach-generic/spaces.h
index 952b0fd..3d6d3b0 100644
--- a/arch/mips/include/asm/mach-generic/spaces.h
+++ b/arch/mips/include/asm/mach-generic/spaces.h
@@ -22,11 +22,13 @@
#endif
#ifdef CONFIG_32BIT
+#ifndef CAC_BASE
#ifdef CONFIG_KVM_GUEST
#define CAC_BASE _AC(0x40000000, UL)
#else
#define CAC_BASE _AC(0x80000000, UL)
#endif
+#endif
#ifndef IO_BASE
#define IO_BASE _AC(0xa0000000, UL)
#endif
--
1.9.1
[toc] | [next] | [standalone]
| From | kbuild test robot <lkp@intel.com> |
|---|---|
| Date | 2016-11-10 13:30 +0100 |
| Message-ID | <sBWEp-6aV-3@gated-at.bofh.it> |
| In reply to | #1518478 |
[Multipart message — attachments visible in raw view] — view raw
Hi Sudip,
[auto build test ERROR on linus/master]
[also build test ERROR on v4.9-rc4 next-20161110]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Sudip-Mukherjee/MIPS-fix-duplicate-define/20161110-044738
config: mips-ip27_defconfig (attached as .config)
compiler: mips64-linux-gnuabi64-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=mips
All errors (new ones prefixed by >>):
In file included from arch/mips/include/asm/page.h:194:0,
from arch/mips/vdso/vdso.h:26,
from arch/mips/vdso/gettimeofday.c:11:
arch/mips/include/asm/io.h: In function 'phys_to_virt':
>> arch/mips/include/asm/io.h:138:9: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
return (void *)(address + PAGE_OFFSET - PHYS_OFFSET);
^
arch/mips/include/asm/io.h: In function 'isa_bus_to_virt':
arch/mips/include/asm/io.h:151:9: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
return (void *)(address + PAGE_OFFSET);
^
cc1: all warnings being treated as errors
vim +138 arch/mips/include/asm/io.h
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 122 }
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 123
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 124 /*
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 125 * phys_to_virt - map physical address to virtual
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 126 * @address: address to remap
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 127 *
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 128 * The returned virtual address is a current CPU mapping for
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 129 * the memory address given. It is only valid to use this function on
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 130 * addresses that have a kernel mapping
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 131 *
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 132 * This function does not handle bus mappings for DMA transfers. In
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 133 * almost all conceivable cases a device driver should not be using
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 134 * this function
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 135 */
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 136 static inline void * phys_to_virt(unsigned long address)
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 137 {
6f284a2c include/asm-mips/io.h Franck Bui-Huu 2007-01-10 @138 return (void *)(address + PAGE_OFFSET - PHYS_OFFSET);
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 139 }
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 140
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 141 /*
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 142 * ISA I/O bus memory addresses are 1:1 with the physical address.
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 143 */
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 144 static inline unsigned long isa_virt_to_bus(volatile void * address)
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 145 {
^1da177e include/asm-mips/io.h Linus Torvalds 2005-04-16 146 return (unsigned long)address - PAGE_OFFSET;
:::::: The code at line 138 was first introduced by commit
:::::: 6f284a2ce7b8bc49cb8455b1763357897a899abb [MIPS] FLATMEM: introduce PHYS_OFFSET.
:::::: TO: Franck Bui-Huu <fbuihuu@gmail.com>
:::::: CC: Ralf Baechle <ralf@linux-mips.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[toc] | [prev] | [next] | [standalone]
| From | Sudip Mukherjee <sudipm.mukherjee@gmail.com> |
|---|---|
| Date | 2016-11-10 13:40 +0100 |
| Message-ID | <sBWO5-6e8-17@gated-at.bofh.it> |
| In reply to | #1518939 |
On Thu, Nov 10, 2016 at 08:23:58PM +0800, kbuild test robot wrote: > Hi Sudip, > > [auto build test ERROR on linus/master] > [also build test ERROR on v4.9-rc4 next-20161110] > [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] > > url: https://github.com/0day-ci/linux/commits/Sudip-Mukherjee/MIPS-fix-duplicate-define/20161110-044738 > config: mips-ip27_defconfig (attached as .config) > compiler: mips64-linux-gnuabi64-gcc (Debian 6.1.1-9) 6.1.1 20160705 > reproduce: > wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross > chmod +x ~/bin/make.cross > # save the attached .config to linux build tree > make.cross ARCH=mips > > All errors (new ones prefixed by >>): > > In file included from arch/mips/include/asm/page.h:194:0, > from arch/mips/vdso/vdso.h:26, > from arch/mips/vdso/gettimeofday.c:11: > arch/mips/include/asm/io.h: In function 'phys_to_virt': > >> arch/mips/include/asm/io.h:138:9: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] > return (void *)(address + PAGE_OFFSET - PHYS_OFFSET); > ^ > arch/mips/include/asm/io.h: In function 'isa_bus_to_virt': > arch/mips/include/asm/io.h:151:9: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] > return (void *)(address + PAGE_OFFSET); > ^ > cc1: all warnings being treated as errors I have seen this before submitting and it is not related to the patch I submitted. My patch fixed one build failure, the build continued and it again failed in some other error which needs to be fixed also. I will have a look after this patch is accepted. Thanks Sudip
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web