[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202008131311.jfeURnZL%lkp@intel.com>
Date: Thu, 13 Aug 2020 13:16:22 +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
Subject: drivers/char/agp/i460-agp.c:254:19: sparse: sparse: incorrect type
in assignment (different address spaces)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: dc06fe51d26efc100ac74121607c01a454867c91
commit: 670d0a4b10704667765f7d18f7592993d02783aa sparse: use identifiers to define address spaces
date: 8 weeks ago
config: ia64-randconfig-s031-20200813 (attached as .config)
compiler: ia64-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.2-168-g9554805c-dirty
git checkout 670d0a4b10704667765f7d18f7592993d02783aa
# 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=ia64
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 >>)
>> drivers/char/agp/i460-agp.c:254:19: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected void *static [assigned] [toplevel] gatt @@ got void [noderef] __iomem * @@
drivers/char/agp/i460-agp.c:254:19: sparse: expected void *static [assigned] [toplevel] gatt
>> drivers/char/agp/i460-agp.c:254:19: sparse: got void [noderef] __iomem *
>> drivers/char/agp/i460-agp.c:266:17: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
>> drivers/char/agp/i460-agp.c:266:17: sparse: expected void volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:266:17: sparse: got unsigned int [usertype] *
>> drivers/char/agp/i460-agp.c:267:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
>> drivers/char/agp/i460-agp.c:267:9: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:267:9: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:281:17: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:281:17: sparse: expected void volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:281:17: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:282:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:282:9: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:282:9: sparse: got unsigned int [usertype] *
>> drivers/char/agp/i460-agp.c:284:21: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got void *static [assigned] [toplevel] gatt @@
drivers/char/agp/i460-agp.c:284:21: sparse: expected void volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:284:21: sparse: got void *static [assigned] [toplevel] gatt
drivers/char/agp/i460-agp.c:318:22: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:318:22: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:318:22: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:318:22: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:318:22: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:318:22: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:319:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:319:25: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:319:25: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:330:25: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:330:25: sparse: expected void volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:330:25: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:332:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:332:9: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:332:9: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:347:17: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:347:17: sparse: expected void volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:347:17: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:348:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int [usertype] * @@
drivers/char/agp/i460-agp.c:348:9: sparse: expected void const volatile [noderef] __iomem *addr
drivers/char/agp/i460-agp.c:348:9: sparse: got unsigned int [usertype] *
drivers/char/agp/i460-agp.c:556:32: sparse: sparse: symbol 'intel_i460_driver' was not declared. Should it be static?
drivers/char/agp/i460-agp.c: note: in included file (through arch/ia64/include/asm/io.h, arch/ia64/include/asm/smp.h, include/linux/smp.h, ...):
include/asm-generic/io.h:225:22: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int [usertype] value @@ got restricted __le32 [usertype] @@
include/asm-generic/io.h:225:22: sparse: expected unsigned int [usertype] value
include/asm-generic/io.h:225:22: sparse: got restricted __le32 [usertype]
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
include/asm-generic/io.h:225:22: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int [usertype] value @@ got restricted __le32 [usertype] @@
include/asm-generic/io.h:225:22: sparse: expected unsigned int [usertype] value
include/asm-generic/io.h:225:22: sparse: got restricted __le32 [usertype]
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
include/asm-generic/io.h:225:22: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int [usertype] value @@ got restricted __le32 [usertype] @@
include/asm-generic/io.h:225:22: sparse: expected unsigned int [usertype] value
include/asm-generic/io.h:225:22: sparse: got restricted __le32 [usertype]
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
include/asm-generic/io.h:225:22: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int [usertype] value @@ got restricted __le32 [usertype] @@
include/asm-generic/io.h:225:22: sparse: expected unsigned int [usertype] value
include/asm-generic/io.h:225:22: sparse: got restricted __le32 [usertype]
include/asm-generic/io.h:179:15: sparse: sparse: cast to restricted __le32
vim +254 drivers/char/agp/i460-agp.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 241
^1da177e4c3f41 Linus Torvalds 2005-04-16 242 static int i460_create_gatt_table (struct agp_bridge_data *bridge)
^1da177e4c3f41 Linus Torvalds 2005-04-16 243 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 244 int page_order, num_entries, i;
^1da177e4c3f41 Linus Torvalds 2005-04-16 245 void *temp;
^1da177e4c3f41 Linus Torvalds 2005-04-16 246
^1da177e4c3f41 Linus Torvalds 2005-04-16 247 /*
^1da177e4c3f41 Linus Torvalds 2005-04-16 248 * Load up the fixed address of the GART SRAMS which hold our GATT table.
^1da177e4c3f41 Linus Torvalds 2005-04-16 249 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 250 temp = agp_bridge->current_size;
^1da177e4c3f41 Linus Torvalds 2005-04-16 251 page_order = A_SIZE_8(temp)->page_order;
^1da177e4c3f41 Linus Torvalds 2005-04-16 252 num_entries = A_SIZE_8(temp)->num_entries;
^1da177e4c3f41 Linus Torvalds 2005-04-16 253
^1da177e4c3f41 Linus Torvalds 2005-04-16 @254 i460.gatt = ioremap(INTEL_I460_ATTBASE, PAGE_SIZE << page_order);
5bdbc7dc2c07d5 Scott Thompson 2007-08-25 255 if (!i460.gatt) {
5bdbc7dc2c07d5 Scott Thompson 2007-08-25 256 printk(KERN_ERR PFX "ioremap failed\n");
5bdbc7dc2c07d5 Scott Thompson 2007-08-25 257 return -ENOMEM;
5bdbc7dc2c07d5 Scott Thompson 2007-08-25 258 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 259
^1da177e4c3f41 Linus Torvalds 2005-04-16 260 /* These are no good, the should be removed from the agp_bridge strucure... */
^1da177e4c3f41 Linus Torvalds 2005-04-16 261 agp_bridge->gatt_table_real = NULL;
^1da177e4c3f41 Linus Torvalds 2005-04-16 262 agp_bridge->gatt_table = NULL;
^1da177e4c3f41 Linus Torvalds 2005-04-16 263 agp_bridge->gatt_bus_addr = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 264
^1da177e4c3f41 Linus Torvalds 2005-04-16 265 for (i = 0; i < num_entries; ++i)
^1da177e4c3f41 Linus Torvalds 2005-04-16 @266 WR_GATT(i, 0);
^1da177e4c3f41 Linus Torvalds 2005-04-16 @267 WR_FLUSH_GATT(i - 1);
^1da177e4c3f41 Linus Torvalds 2005-04-16 268 return 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 269 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 270
^1da177e4c3f41 Linus Torvalds 2005-04-16 271 static int i460_free_gatt_table (struct agp_bridge_data *bridge)
^1da177e4c3f41 Linus Torvalds 2005-04-16 272 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 273 int num_entries, i;
^1da177e4c3f41 Linus Torvalds 2005-04-16 274 void *temp;
^1da177e4c3f41 Linus Torvalds 2005-04-16 275
^1da177e4c3f41 Linus Torvalds 2005-04-16 276 temp = agp_bridge->current_size;
^1da177e4c3f41 Linus Torvalds 2005-04-16 277
^1da177e4c3f41 Linus Torvalds 2005-04-16 278 num_entries = A_SIZE_8(temp)->num_entries;
^1da177e4c3f41 Linus Torvalds 2005-04-16 279
^1da177e4c3f41 Linus Torvalds 2005-04-16 280 for (i = 0; i < num_entries; ++i)
^1da177e4c3f41 Linus Torvalds 2005-04-16 281 WR_GATT(i, 0);
^1da177e4c3f41 Linus Torvalds 2005-04-16 282 WR_FLUSH_GATT(num_entries - 1);
^1da177e4c3f41 Linus Torvalds 2005-04-16 283
^1da177e4c3f41 Linus Torvalds 2005-04-16 @284 iounmap(i460.gatt);
^1da177e4c3f41 Linus Torvalds 2005-04-16 285 return 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 286 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 287
:::::: The code at line 254 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2
:::::: TO: Linus Torvalds <torvalds@...970.osdl.org>
:::::: CC: Linus Torvalds <torvalds@...970.osdl.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" (27025 bytes)
Powered by blists - more mailing lists