linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* arch/x86/kernel/signal.c:936:9: sparse: sparse: incorrect type in argument 1 (different address spaces)
@ 2021-11-17 19:30 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-11-17 19:30 UTC (permalink / raw)
  To: Thomas Gleixner; +Cc: kbuild-all, linux-kernel, Borislav Petkov, Chang S. Bae

[-- Attachment #1: Type: text/plain, Size: 5147 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   ee1703cda8dc777e937dec172da55beaf1a74919
commit: 3aac3ebea08f2d342364f827c8979ab0e1dd591e x86/signal: Implement sigaltstack size validation
date:   3 weeks ago
config: i386-randconfig-s001-20211109 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.4-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=3aac3ebea08f2d342364f827c8979ab0e1dd591e
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout 3aac3ebea08f2d342364f827c8979ab0e1dd591e
        # 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@intel.com>


sparse warnings: (new ones prefixed by >>)
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void const volatile [noderef] __user *ptr @@     got unsigned long long [usertype] * @@
   arch/x86/kernel/signal.c:358:9: sparse:     expected void const volatile [noderef] __user *ptr
   arch/x86/kernel/signal.c:358:9: sparse:     got unsigned long long [usertype] *
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:358:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void const volatile [noderef] __user *ptr @@     got unsigned long long [usertype] * @@
   arch/x86/kernel/signal.c:418:9: sparse:     expected void const volatile [noderef] __user *ptr
   arch/x86/kernel/signal.c:418:9: sparse:     got unsigned long long [usertype] *
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
   arch/x86/kernel/signal.c:418:9: sparse: sparse: cast removes address space '__user' of expression
>> arch/x86/kernel/signal.c:936:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct lockdep_map const *lock @@     got struct lockdep_map [noderef] __rcu * @@
   arch/x86/kernel/signal.c:936:9: sparse:     expected struct lockdep_map const *lock
   arch/x86/kernel/signal.c:936:9: sparse:     got struct lockdep_map [noderef] __rcu *

vim +936 arch/x86/kernel/signal.c

   924	
   925	/*
   926	 * MINSIGSTKSZ is 2048 and can't be changed despite the fact that AVX512
   927	 * exceeds that size already. As such programs might never use the
   928	 * sigaltstack they just continued to work. While always checking against
   929	 * the real size would be correct, this might be considered a regression.
   930	 *
   931	 * Therefore avoid the sanity check, unless enforced by kernel config or
   932	 * command line option.
   933	 */
   934	bool sigaltstack_size_valid(size_t ss_size)
   935	{
 > 936		lockdep_assert_held(&current->sighand->siglock);
   937	
   938		if (strict_sigaltstack_size)
   939			return ss_size > get_sigframe_size();
   940	
   941		return true;
   942	}
   943	#endif /* CONFIG_DYNAMIC_SIGFRAME */
   944	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 40986 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-11-17 19:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-17 19:30 arch/x86/kernel/signal.c:936:9: sparse: sparse: incorrect type in argument 1 (different address spaces) kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).