[xilinx-xlnx:xlnx_rebase_v5.15 537/1049] drivers/usb/misc/usb5744.c:64:55: sparse: sparse: incorrect type in argument 3 (different base types)
kernel test robot
lkp at intel.com
Mon Apr 4 12:20:06 PDT 2022
tree: https://github.com/Xilinx/linux-xlnx xlnx_rebase_v5.15
head: 4cf4408c2dbe725bb8530f851fbf277b9343f602
commit: a72cdbc061595029cbe60bc7f5b33015d391cf18 [537/1049] usb: misc: usb5744: add support for USB hub controller
config: sh-randconfig-s032-20220404 (https://download.01.org/0day-ci/archive/20220405/202204050314.OPOaZ49I-lkp@intel.com/config)
compiler: sh4-linux-gcc (GCC) 11.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.4-dirty
# https://github.com/Xilinx/linux-xlnx/commit/a72cdbc061595029cbe60bc7f5b33015d391cf18
git remote add xilinx-xlnx https://github.com/Xilinx/linux-xlnx
git fetch --no-tags xilinx-xlnx xlnx_rebase_v5.15
git checkout a72cdbc061595029cbe60bc7f5b33015d391cf18
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=sh SHELL=/bin/bash drivers/staging/ drivers/usb/misc/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp at intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/usb/misc/usb5744.c:64:55: sparse: sparse: incorrect type in argument 3 (different base types) @@ expected unsigned short [usertype] value @@ got restricted __be16 [usertype] @@
drivers/usb/misc/usb5744.c:64:55: sparse: expected unsigned short [usertype] value
drivers/usb/misc/usb5744.c:64:55: sparse: got restricted __be16 [usertype]
vim +64 drivers/usb/misc/usb5744.c
49
50 static int usb5744_i2c_dev_init(struct i2c_client *client)
51 {
52 struct device *dev = &client->dev;
53 struct usb5744 *data = NULL;
54 int ret = 0;
55
56 i2c_set_clientdata(client, data);
57
58 /* Trigger gpio reset to the hub. */
59 ret = usb5744_init_hw(dev, data);
60 if (ret)
61 return ret;
62
63 /* Send SMBus command to boot hub. */
> 64 ret = i2c_smbus_write_word_data(client, 0xAA, htons(0x5600));
65 if (ret < 0)
66 dev_err(dev, "Sending boot command failed");
67
68 return ret;
69 }
70
--
0-DAY CI Kernel Test Service
https://01.org/lkp
More information about the linux-arm-kernel
mailing list