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  linux-cve-announce  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:   Fri, 26 Aug 2016 10:33:12 +0800
From:   kbuild test robot <fengguang.wu@...el.com>
To:     Johannes Berg <johannes.berg@...el.com>
Cc:     kbuild-all@...org, linux-kernel@...r.kernel.org,
        Ingo Molnar <mingo@...nel.org>,
        "Peter Zijlstra (Intel)" <peterz@...radead.org>
Subject: include/linux/radix-tree.h:199:16: sparse: expression using
 sizeof(void)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   61c04572de404e52a655a36752e696bbcb483cf5
commit: 112dc0c8069e5554e0ad29c58228f1e6ca49e13d locking/barriers: Suppress sparse warnings in lockless_dereference()
date:   8 days ago
reproduce:
        # apt-get install sparse
        git checkout 112dc0c8069e5554e0ad29c58228f1e6ca49e13d
        make ARCH=x86_64 allmodconfig
        make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

>> include/linux/radix-tree.h:199:16: sparse: expression using sizeof(void)
   include/linux/radix-tree.h:199:16: sparse: incompatible types in comparison expression (different address spaces)

vim +199 include/linux/radix-tree.h

7cf9c2c7 Nick Piggin 2006-12-06  183  
7cf9c2c7 Nick Piggin 2006-12-06  184  /**
7cf9c2c7 Nick Piggin 2006-12-06  185   * radix_tree_deref_slot	- dereference a slot
7cf9c2c7 Nick Piggin 2006-12-06  186   * @pslot:	pointer to slot, returned by radix_tree_lookup_slot
7cf9c2c7 Nick Piggin 2006-12-06  187   * Returns:	item that was stored in that slot with any direct pointer flag
7cf9c2c7 Nick Piggin 2006-12-06  188   *		removed.
7cf9c2c7 Nick Piggin 2006-12-06  189   *
7cf9c2c7 Nick Piggin 2006-12-06  190   * For use with radix_tree_lookup_slot().  Caller must hold tree at least read
27d20fdd Nick Piggin 2010-11-11  191   * locked across slot lookup and dereference. Not required if write lock is
27d20fdd Nick Piggin 2010-11-11  192   * held (ie. items cannot be concurrently inserted).
27d20fdd Nick Piggin 2010-11-11  193   *
27d20fdd Nick Piggin 2010-11-11  194   * radix_tree_deref_retry must be used to confirm validity of the pointer if
27d20fdd Nick Piggin 2010-11-11  195   * only the read lock is held.
7cf9c2c7 Nick Piggin 2006-12-06  196   */
7cf9c2c7 Nick Piggin 2006-12-06  197  static inline void *radix_tree_deref_slot(void **pslot)
7cf9c2c7 Nick Piggin 2006-12-06  198  {
27d20fdd Nick Piggin 2010-11-11 @199  	return rcu_dereference(*pslot);
7cf9c2c7 Nick Piggin 2006-12-06  200  }
27d20fdd Nick Piggin 2010-11-11  201  
27d20fdd Nick Piggin 2010-11-11  202  /**
29c1f677 Mel Gorman  2011-01-13  203   * radix_tree_deref_slot_protected	- dereference a slot without RCU lock but with tree lock held
29c1f677 Mel Gorman  2011-01-13  204   * @pslot:	pointer to slot, returned by radix_tree_lookup_slot
29c1f677 Mel Gorman  2011-01-13  205   * Returns:	item that was stored in that slot with any direct pointer flag
29c1f677 Mel Gorman  2011-01-13  206   *		removed.
29c1f677 Mel Gorman  2011-01-13  207   *

:::::: The code at line 199 was first introduced by commit
:::::: 27d20fddc8af539464fc3ba499d6a830054c3bd6 radix-tree: fix RCU bug

:::::: TO: Nick Piggin <npiggin@...nel.dk>
:::::: CC: Linus Torvalds <torvalds@...ux-foundation.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ