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]
Message-ID: <202311191039.4P3HiiKh-lkp@intel.com>
Date:   Sun, 19 Nov 2023 10:40:10 +0800
From:   kernel test robot <lkp@...el.com>
To:     Peter Zijlstra <peterz@...radead.org>
Cc:     oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
        Ingo Molnar <mingo@...nel.org>
Subject: arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast
 truncates bits from constant value (ffffffff becomes ff)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   b8f1fa2419c19c81bc386a6b350879ba54a573e1
commit: 0e34600ac9317dbe5f0a7bfaa3d7187d757572ed sched: Misc cleanups
date:   10 weeks ago
config: arm64-randconfig-r122-20231119 (https://download.01.org/0day-ci/archive/20231119/202311191039.4P3HiiKh-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 13.2.0
reproduce: (https://download.01.org/0day-ci/archive/20231119/202311191039.4P3HiiKh-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202311191039.4P3HiiKh-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
   kernel/sched/core.c:6298:46: sparse:    struct task_struct *
   kernel/sched/core.c:6298:46: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/core.c:6358:9: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected struct sched_domain *[assigned] sd @@     got struct sched_domain [noderef] __rcu *parent @@
   kernel/sched/core.c:6358:9: sparse:     expected struct sched_domain *[assigned] sd
   kernel/sched/core.c:6358:9: sparse:     got struct sched_domain [noderef] __rcu *parent
   kernel/sched/core.c:6569:14: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected struct task_struct *prev @@     got struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:6569:14: sparse:     expected struct task_struct *prev
   kernel/sched/core.c:6569:14: sparse:     got struct task_struct [noderef] __rcu *curr
   kernel/sched/core.c:7095:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/core.c:7095:17: sparse:    struct task_struct *
   kernel/sched/core.c:7095:17: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/core.c:7310:22: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/core.c:7310:22: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/core.c:7310:22: sparse:    struct task_struct *
   kernel/sched/core.c:7357:48: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/core.c:7357:48: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/core.c:7357:48: sparse:    struct task_struct *
   kernel/sched/core.c:11435:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct task_struct *p @@     got struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:11435:25: sparse:     expected struct task_struct *p
   kernel/sched/core.c:11435:25: sparse:     got struct task_struct [noderef] __rcu *curr
   kernel/sched/core.c:338:9: sparse: sparse: context imbalance in 'sched_core_lock' - different lock contexts for basic block
   kernel/sched/core.c:348:17: sparse: sparse: context imbalance in 'sched_core_unlock' - unexpected unlock
   kernel/sched/core.c:551:6: sparse: sparse: context imbalance in 'raw_spin_rq_lock_nested' - wrong count at exit
   kernel/sched/core.c:576:6: sparse: sparse: context imbalance in 'raw_spin_rq_trylock' - wrong count at exit
   kernel/sched/core.c: note: in included file:
   kernel/sched/sched.h:1235:30: sparse: sparse: context imbalance in 'raw_spin_rq_unlock' - unexpected unlock
   kernel/sched/core.c:638:36: sparse: sparse: context imbalance in '__task_rq_lock' - wrong count at exit
   kernel/sched/core.c:679:36: sparse: sparse: context imbalance in 'task_rq_lock' - wrong count at exit
   kernel/sched/core.c: note: in included file:
   kernel/sched/pelt.h:97:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct task_struct const *p @@     got struct task_struct [noderef] __rcu *curr @@
   kernel/sched/pelt.h:97:13: sparse:     expected struct task_struct const *p
   kernel/sched/pelt.h:97:13: sparse:     got struct task_struct [noderef] __rcu *curr
   kernel/sched/core.c:1086:5: sparse: sparse: context imbalance in 'get_nohz_timer_target' - wrong count at exit
   kernel/sched/core.c:1481:13: sparse: sparse: context imbalance in 'uclamp_update_util_min_rt_default' - wrong count at exit
   kernel/sched/core.c:1775:13: sparse: sparse: context imbalance in 'uclamp_update_root_tg' - wrong count at exit
   kernel/sched/core.c:1813:9: sparse: sparse: context imbalance in 'uclamp_sync_util_min_rt_default' - wrong count at exit
   kernel/sched/core.c:2217:33: sparse: sparse: dereference of noderef expression
   kernel/sched/core.c:2218:19: sparse: sparse: dereference of noderef expression
   kernel/sched/core.c:2219:18: sparse: sparse: dereference of noderef expression
   kernel/sched/core.c:2272:15: sparse: sparse: context imbalance in 'wait_task_inactive' - different lock contexts for basic block
   kernel/sched/core.c: note: in included file:
   kernel/sched/sched.h:2138:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/core.c:2192:38: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/core.c:2192:38: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/core.c:2192:38: sparse:    struct task_struct const *
   kernel/sched/sched.h:2138:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/sched.h:2138:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/sched.h:2138:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/sched.h:2138:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/core.c:8241:5: sparse: sparse: context imbalance in 'dl_task_check_affinity' - wrong count at exit
   kernel/sched/core.c:8345:44: sparse: sparse: context imbalance in 'sched_setaffinity' - different lock contexts for basic block
   kernel/sched/core.c:8407:6: sparse: sparse: context imbalance in 'sched_getaffinity' - wrong count at exit
   kernel/sched/core.c:8570:28: sparse: sparse: context imbalance in '__cond_resched_lock' - unexpected unlock
   kernel/sched/core.c:8588:17: sparse: sparse: context imbalance in '__cond_resched_rwlock_read' - unexpected unlock
   kernel/sched/core.c:8606:17: sparse: sparse: context imbalance in '__cond_resched_rwlock_write' - unexpected unlock
   kernel/sched/core.c: note: in included file (through include/linux/mmu_context.h, include/linux/cpuset.h):
   arch/arm64/include/asm/mmu_context.h:252:22: sparse: sparse: self-comparison always evaluates to true
   kernel/sched/core.c: note: in included file:
   kernel/sched/sched.h:2138:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2138:25: sparse:    struct task_struct *
   kernel/sched/sched.h:2302:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct [noderef] __rcu *
   kernel/sched/sched.h:2302:9: sparse:    struct task_struct *
   kernel/sched/core.c:11600:5: sparse: sparse: context imbalance in '__sched_mm_cid_migrate_from_fetch_cid' - different lock contexts for basic block
   kernel/sched/core.c: note: in included file (through arch/arm64/include/asm/atomic.h, include/linux/atomic.h, include/linux/jump_label.h, ...):
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ffff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ffff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ffff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ffff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ff)
>> arch/arm64/include/asm/cmpxchg.h:171:1: sparse: sparse: cast truncates bits from constant value (ffffffff becomes ffff)

vim +171 arch/arm64/include/asm/cmpxchg.h

10b663aef1c247 Catalin Marinas 2012-03-05  167  
305d454aaa292b Will Deacon     2015-10-08  168  __CMPXCHG_GEN()
305d454aaa292b Will Deacon     2015-10-08  169  __CMPXCHG_GEN(_acq)
305d454aaa292b Will Deacon     2015-10-08  170  __CMPXCHG_GEN(_rel)
305d454aaa292b Will Deacon     2015-10-08 @171  __CMPXCHG_GEN(_mb)
10b663aef1c247 Catalin Marinas 2012-03-05  172  

:::::: The code at line 171 was first introduced by commit
:::::: 305d454aaa292be3a09a9d674e6c35f5b4249a13 arm64: atomics: implement native {relaxed, acquire, release} atomics

:::::: TO: Will Deacon <will.deacon@....com>
:::::: CC: Catalin Marinas <catalin.marinas@....com>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ