lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Sun, 9 Aug 2020 01:02:08 +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/amd-k7-agp.c:46:28: sparse: sparse: incorrect type
 in assignment (different address spaces)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   449dc8c97089a6e09fb2dac4d92b1b7ac0eb7c1e
commit: 670d0a4b10704667765f7d18f7592993d02783aa sparse: use identifiers to define address spaces
date:   7 weeks ago
config: i386-randconfig-s002-20200809 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.2-118-ge1578773-dirty
        git checkout 670d0a4b10704667765f7d18f7592993d02783aa
        # save the attached .config to linux build tree
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386 

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/amd-k7-agp.c:46:28: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected unsigned long [noderef] __iomem *remapped @@     got unsigned long *real @@
>> drivers/char/agp/amd-k7-agp.c:46:28: sparse:     expected unsigned long [noderef] __iomem *remapped
   drivers/char/agp/amd-k7-agp.c:46:28: sparse:     got unsigned long *real
--
>> drivers/scsi/pcmcia/nsp_cs.c:1669:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void volatile [noderef] __iomem *addr @@     got void * @@
>> drivers/scsi/pcmcia/nsp_cs.c:1669:34: sparse:     expected void volatile [noderef] __iomem *addr
   drivers/scsi/pcmcia/nsp_cs.c:1669:34: sparse:     got void *
   drivers/scsi/pcmcia/nsp_cs.c: note: in included file:
   drivers/scsi/pcmcia/nsp_io.h:231:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void const volatile [noderef] __iomem *addr @@     got unsigned long *ptr @@
   drivers/scsi/pcmcia/nsp_io.h:231:30: sparse:     expected void const volatile [noderef] __iomem *addr
   drivers/scsi/pcmcia/nsp_io.h:231:30: sparse:     got unsigned long *ptr
   drivers/scsi/pcmcia/nsp_io.h:257:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@     expected void volatile [noderef] __iomem *addr @@     got unsigned long *ptr @@
   drivers/scsi/pcmcia/nsp_io.h:257:30: sparse:     expected void volatile [noderef] __iomem *addr
   drivers/scsi/pcmcia/nsp_io.h:257:30: sparse:     got unsigned long *ptr

vim +46 drivers/char/agp/amd-k7-agp.c

^1da177e4c3f41 Linus Torvalds    2005-04-16  36  
^1da177e4c3f41 Linus Torvalds    2005-04-16  37  static int amd_create_page_map(struct amd_page_map *page_map)
^1da177e4c3f41 Linus Torvalds    2005-04-16  38  {
^1da177e4c3f41 Linus Torvalds    2005-04-16  39  	int i;
^1da177e4c3f41 Linus Torvalds    2005-04-16  40  
^1da177e4c3f41 Linus Torvalds    2005-04-16  41  	page_map->real = (unsigned long *) __get_free_page(GFP_KERNEL);
^1da177e4c3f41 Linus Torvalds    2005-04-16  42  	if (page_map->real == NULL)
^1da177e4c3f41 Linus Torvalds    2005-04-16  43  		return -ENOMEM;
^1da177e4c3f41 Linus Torvalds    2005-04-16  44  
44a207fc66c13c Dave Airlie       2008-02-20  45  	set_memory_uc((unsigned long)page_map->real, 1);
fcea424d31868a Arjan van dev Ven 2008-02-06 @46  	page_map->remapped = page_map->real;
^1da177e4c3f41 Linus Torvalds    2005-04-16  47  
^1da177e4c3f41 Linus Torvalds    2005-04-16  48  	for (i = 0; i < PAGE_SIZE / sizeof(unsigned long); i++) {
^1da177e4c3f41 Linus Torvalds    2005-04-16  49  		writel(agp_bridge->scratch_page, page_map->remapped+i);
^1da177e4c3f41 Linus Torvalds    2005-04-16  50  		readl(page_map->remapped+i);	/* PCI Posting. */
^1da177e4c3f41 Linus Torvalds    2005-04-16  51  	}
^1da177e4c3f41 Linus Torvalds    2005-04-16  52  
^1da177e4c3f41 Linus Torvalds    2005-04-16  53  	return 0;
^1da177e4c3f41 Linus Torvalds    2005-04-16  54  }
^1da177e4c3f41 Linus Torvalds    2005-04-16  55  

:::::: The code at line 46 was first introduced by commit
:::::: fcea424d31868a78366ad5ee0cb3cc2a4cbe689b fix historic ioremap() abuse in AGP

:::::: TO: Arjan van dev Ven <arjan@...ux.intel.com>
:::::: CC: Dave Airlie <airlied@...ux.ie>

---
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" (33268 bytes)

Powered by blists - more mailing lists