[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202101100351.kHuvVzrx-lkp@intel.com>
Date: Sun, 10 Jan 2021 03:40:00 +0800
From: kernel test robot <lkp@...el.com>
To: Luc Van Oostenryck <luc.vanoostenryck@...il.com>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
Subject: arch/sh/kernel/kgdb.c:310:38: sparse: sparse: incorrect type in
argument 1 (different base types)
Hi Luc,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 996e435fd401de35df62ac943ab9402cfe85c430
commit: e5fc436f06eef54ef512ea55a9db8eb9f2e76959 sparse: use static inline for __chk_{user,io}_ptr()
date: 4 months ago
config: sh-randconfig-s031-20210110 (attached as .config)
compiler: sh4-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-208-g46a52ca4-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e5fc436f06eef54ef512ea55a9db8eb9f2e76959
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout e5fc436f06eef54ef512ea55a9db8eb9f2e76959
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=sh
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
"sparse warnings: (new ones prefixed by >>)"
arch/sh/kernel/kgdb.c:49:26: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned long pc @@
arch/sh/kernel/kgdb.c:49:26: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/kernel/kgdb.c:49:26: sparse: got unsigned long pc
arch/sh/kernel/kgdb.c:146:26: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got long @@
arch/sh/kernel/kgdb.c:146:26: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/kernel/kgdb.c:146:26: sparse: got long
arch/sh/kernel/kgdb.c:160:17: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned long static [assigned] [toplevel] stepped_address @@
arch/sh/kernel/kgdb.c:160:17: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/kernel/kgdb.c:160:17: sparse: got unsigned long static [assigned] [toplevel] stepped_address
>> arch/sh/kernel/kgdb.c:310:38: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned long @@
arch/sh/kernel/kgdb.c:310:38: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/kernel/kgdb.c:310:38: sparse: got unsigned long
--
drivers/input/serio/serport.c:213:21: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned long const *__gu_addr @@ got unsigned long [noderef] __user * @@
drivers/input/serio/serport.c:213:21: sparse: expected unsigned long const *__gu_addr
drivers/input/serio/serport.c:213:21: sparse: got unsigned long [noderef] __user *
>> drivers/input/serio/serport.c:213:21: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned long const *__gu_addr @@
drivers/input/serio/serport.c:213:21: sparse: expected void const volatile [noderef] __user *ptr
drivers/input/serio/serport.c:213:21: sparse: got unsigned long const *__gu_addr
--
drivers/tee/tee_core.c:683:13: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned int const *__gu_addr @@ got unsigned int [noderef] __user * @@
drivers/tee/tee_core.c:683:13: sparse: expected unsigned int const *__gu_addr
drivers/tee/tee_core.c:683:13: sparse: got unsigned int [noderef] __user *
>> drivers/tee/tee_core.c:683:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned int const *__gu_addr @@
drivers/tee/tee_core.c:683:13: sparse: expected void const volatile [noderef] __user *ptr
drivers/tee/tee_core.c:683:13: sparse: got unsigned int const *__gu_addr
drivers/tee/tee_core.c:781:13: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned int const *__gu_addr @@ got unsigned int [noderef] __user * @@
drivers/tee/tee_core.c:781:13: sparse: expected unsigned int const *__gu_addr
drivers/tee/tee_core.c:781:13: sparse: got unsigned int [noderef] __user *
drivers/tee/tee_core.c:781:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned int const *__gu_addr @@
drivers/tee/tee_core.c:781:13: sparse: expected void const volatile [noderef] __user *ptr
drivers/tee/tee_core.c:781:13: sparse: got unsigned int const *__gu_addr
drivers/tee/tee_core.c:782:13: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned int const *__gu_addr @@ got unsigned int [noderef] __user * @@
drivers/tee/tee_core.c:782:13: sparse: expected unsigned int const *__gu_addr
drivers/tee/tee_core.c:782:13: sparse: got unsigned int [noderef] __user *
drivers/tee/tee_core.c:782:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned int const *__gu_addr @@
drivers/tee/tee_core.c:782:13: sparse: expected void const volatile [noderef] __user *ptr
drivers/tee/tee_core.c:782:13: sparse: got unsigned int const *__gu_addr
--
drivers/watchdog/shwdt.c: note: in included file:
arch/sh/include/asm/watchdog.h:144:16: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:144:16: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:144:16: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:156:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:156:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:156:9: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:134:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:134:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:134:9: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:144:16: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:144:16: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:144:16: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:156:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:156:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:156:9: sparse: got unsigned int
drivers/watchdog/shwdt.c: note: in included file (through arch/sh/include/cpu-sh2a/cpu/watchdog.h, arch/sh/include/asm/watchdog.h):
>> arch/sh/include/cpu-sh2/cpu/watchdog.h:44:16: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/cpu-sh2/cpu/watchdog.h:44:16: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/cpu-sh2/cpu/watchdog.h:44:16: sparse: got unsigned int
arch/sh/include/cpu-sh2/cpu/watchdog.h:62:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/cpu-sh2/cpu/watchdog.h:62:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/cpu-sh2/cpu/watchdog.h:62:9: sparse: got unsigned int
drivers/watchdog/shwdt.c: note: in included file:
arch/sh/include/asm/watchdog.h:144:16: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:144:16: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:144:16: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:156:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:156:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:156:9: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:144:16: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:144:16: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:144:16: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:156:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:156:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:156:9: sparse: got unsigned int
arch/sh/include/asm/watchdog.h:134:9: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected void const volatile [noderef] __iomem *ptr @@ got unsigned int @@
arch/sh/include/asm/watchdog.h:134:9: sparse: expected void const volatile [noderef] __iomem *ptr
arch/sh/include/asm/watchdog.h:134:9: sparse: got unsigned int
vim +310 arch/sh/kernel/kgdb.c
489022cc86ec8817 Jason Wessel 2010-05-20 300
ab6e570ba33dbee1 Paul Mundt 2008-12-11 301 /*
ab6e570ba33dbee1 Paul Mundt 2008-12-11 302 * The primary entry points for the kgdb debug trap table entries.
ab6e570ba33dbee1 Paul Mundt 2008-12-11 303 */
ab6e570ba33dbee1 Paul Mundt 2008-12-11 304 BUILD_TRAP_HANDLER(singlestep)
ab6e570ba33dbee1 Paul Mundt 2008-12-11 305 {
ab6e570ba33dbee1 Paul Mundt 2008-12-11 306 unsigned long flags;
ab6e570ba33dbee1 Paul Mundt 2008-12-11 307 TRAP_HANDLER_DECL;
ab6e570ba33dbee1 Paul Mundt 2008-12-11 308
ab6e570ba33dbee1 Paul Mundt 2008-12-11 309 local_irq_save(flags);
ab6e570ba33dbee1 Paul Mundt 2008-12-11 @310 regs->pc -= instruction_size(__raw_readw(regs->pc - 4));
489022cc86ec8817 Jason Wessel 2010-05-20 311 kgdb_handle_exception(0, SIGTRAP, 0, regs);
ab6e570ba33dbee1 Paul Mundt 2008-12-11 312 local_irq_restore(flags);
ab6e570ba33dbee1 Paul Mundt 2008-12-11 313 }
ab6e570ba33dbee1 Paul Mundt 2008-12-11 314
:::::: The code at line 310 was first introduced by commit
:::::: ab6e570ba33dbee18c2520d386e0f367a9b573c3 sh: Generic kgdb stub support.
:::::: TO: Paul Mundt <lethal@...ux-sh.org>
:::::: CC: Paul Mundt <lethal@...ux-sh.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (21316 bytes)
Powered by blists - more mailing lists