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: <202412192017.t0ZPK7sM-lkp@intel.com>
Date: Thu, 19 Dec 2024 20:36:29 +0800
From: kernel test robot <lkp@...el.com>
To: Anup Patel <apatel@...tanamicro.com>
Cc: oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
	Atish Patra <atishp@...osinc.com>
Subject: arch/riscv/kvm/vcpu_timer.c:75:9: sparse: sparse: incorrect type in
 assignment (different base types)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   eabcdba3ad4098460a376538df2ae36500223c1e
commit: e28e6b69767b3aea73eda0fd3e7b4e1c15a7ebec RISC-V: KVM: Use nacl_csr_xyz() for accessing H-extension CSRs
date:   7 weeks ago
config: riscv-randconfig-r113-20241219 (https://download.01.org/0day-ci/archive/20241219/202412192017.t0ZPK7sM-lkp@intel.com/config)
compiler: riscv32-linux-gcc (GCC) 14.2.0
reproduce: (https://download.01.org/0day-ci/archive/20241219/202412192017.t0ZPK7sM-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/202412192017.t0ZPK7sM-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> arch/riscv/kvm/vcpu_timer.c:75:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu_timer.c:75:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu_timer.c:75:9: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu_timer.c:76:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu_timer.c:76:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu_timer.c:76:9: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu_timer.c:292:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu_timer.c:292:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu_timer.c:292:9: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu_timer.c:293:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu_timer.c:293:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu_timer.c:293:9: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu_timer.c:309:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu_timer.c:309:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu_timer.c:309:9: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu_timer.c:310:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu_timer.c:310:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu_timer.c:310:9: sparse:     got restricted __le32 [usertype]
>> arch/riscv/kvm/vcpu_timer.c:330:26: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu_timer.c:331:32: sparse: sparse: cast to restricted __le32
--
>> arch/riscv/kvm/mmu.c:735:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/mmu.c:735:9: sparse:     expected unsigned long
   arch/riscv/kvm/mmu.c:735:9: sparse:     got restricted __le32 [usertype]
--
   arch/riscv/kvm/vcpu.c:27:49: sparse: sparse: array of flexible structures
   arch/riscv/kvm/vcpu.c: note: in included file:
   include/linux/kvm_host.h:2033:56: sparse: sparse: array of flexible structures
>> arch/riscv/kvm/vcpu.c:371:21: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:374:16: sparse: sparse: cast to restricted __le32
>> arch/riscv/kvm/vcpu.c:577:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:577:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:577:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:578:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:578:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:578:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:579:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:579:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:579:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:580:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:580:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:580:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:581:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:581:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:581:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:582:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:582:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:582:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:583:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:583:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:583:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:584:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:584:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:584:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:585:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:585:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:585:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:586:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:586:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:586:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:587:17: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:587:17: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:587:17: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:589:25: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:589:25: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:589:25: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:591:25: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:591:25: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:591:25: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:593:33: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:593:33: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:593:33: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:654:33: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:655:29: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:656:31: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:657:34: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:658:30: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:659:32: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:660:31: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:661:29: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:662:30: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:728:9: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:728:9: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:728:9: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:775:26: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:775:26: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long @@     got restricted __le32 [usertype] @@
   arch/riscv/kvm/vcpu.c:775:26: sparse:     expected unsigned long
   arch/riscv/kvm/vcpu.c:775:26: sparse:     got restricted __le32 [usertype]
   arch/riscv/kvm/vcpu.c:912:30: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c:913:31: sparse: sparse: cast to restricted __le32
   arch/riscv/kvm/vcpu.c: note: in included file (through include/linux/notifier.h, include/linux/memory_hotplug.h, include/linux/mmzone.h, ...):
   include/linux/srcu.h:320:9: sparse: sparse: context imbalance in 'kvm_riscv_check_vcpu_requests' - unexpected unlock

vim +75 arch/riscv/kvm/vcpu_timer.c

    71	
    72	static int kvm_riscv_vcpu_update_vstimecmp(struct kvm_vcpu *vcpu, u64 ncycles)
    73	{
    74	#if defined(CONFIG_32BIT)
  > 75		ncsr_write(CSR_VSTIMECMP, ncycles & 0xFFFFFFFF);
    76		ncsr_write(CSR_VSTIMECMPH, ncycles >> 32);
    77	#else
    78		ncsr_write(CSR_VSTIMECMP, ncycles);
    79	#endif
    80		return 0;
    81	}
    82	

-- 
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