Messages in this thread | | | Date | Mon, 29 Nov 2021 09:04:38 +0800 | From | kernel test robot <> | Subject | [ogabbay:habanalabs-next 37/42] drivers/misc/habanalabs/common/firmware_if.c:972:18: sparse: sparse: incorrect type in assignment (different base types) |
| |
tree: https://git.kernel.org/pub/scm/linux/kernel/git/ogabbay/linux.git habanalabs-next head: f21fb20b7d0cbd7c09fbe870be75060528aea0c5 commit: 1d21e1077cef48e54f263a75af31448f9f68ee5b [37/42] habanalabs: add power information type to POWER_GET packet config: i386-randconfig-s002-20211128 (https://download.01.org/0day-ci/archive/20211129/202111290912.9nnXuUjM-lkp@intel.com/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/ogabbay/linux.git/commit/?id=1d21e1077cef48e54f263a75af31448f9f68ee5b git remote add ogabbay https://git.kernel.org/pub/scm/linux/kernel/git/ogabbay/linux.git git fetch --no-tags ogabbay habanalabs-next git checkout 1d21e1077cef48e54f263a75af31448f9f68ee5b # save the config file to linux build tree make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=i386 SHELL=/bin/bash drivers/misc/
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 >>) >> drivers/misc/habanalabs/common/firmware_if.c:972:18: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __le16 [addressable] [assigned] [usertype] type @@ got int @@ drivers/misc/habanalabs/common/firmware_if.c:972:18: sparse: expected restricted __le16 [addressable] [assigned] [usertype] type drivers/misc/habanalabs/common/firmware_if.c:972:18: sparse: got int
vim +972 drivers/misc/habanalabs/common/firmware_if.c
961 962 int hl_fw_cpucp_power_get(struct hl_device *hdev, u64 *power) 963 { 964 struct cpucp_packet pkt; 965 u64 result; 966 int rc; 967 968 memset(&pkt, 0, sizeof(pkt)); 969 970 pkt.ctl = cpu_to_le32(CPUCP_PACKET_POWER_GET << 971 CPUCP_PKT_CTL_OPCODE_SHIFT); > 972 pkt.type = CPUCP_POWER_INPUT; 973 974 rc = hdev->asic_funcs->send_cpu_message(hdev, (u32 *) &pkt, sizeof(pkt), 975 HL_CPUCP_INFO_TIMEOUT_USEC, &result); 976 if (rc) { 977 dev_err(hdev->dev, "Failed to read power, error %d\n", rc); 978 return rc; 979 } 980 981 *power = result; 982 983 return rc; 984 } 985
--- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
| |