[kees:flexcpy/next-20220502 8/34] drivers/net/wireless/intel/iwlwifi/dvm/calib.c:68:20: error: 'struct iwl_calib_result' has no member named 'hdr'

From: kernel test robot
Date: Wed May 04 2022 - 04:14:07 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git flexcpy/next-20220502
head: 1dbd8181297512b190aca23477043ac635daba4e
commit: ebd8c465eee86d64d9d8f2204db5971e6588174a [8/34] iwlwifi: calib: Prepare to use mem_to_flex_dup()
config: arc-allyesconfig (https://download.01.org/0day-ci/archive/20220504/202205041603.z4FBgjkQ-lkp@xxxxxxxxx/config)
compiler: arceb-elf-gcc (GCC) 11.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git/commit/?id=ebd8c465eee86d64d9d8f2204db5971e6588174a
git remote add kees https://git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git
git fetch --no-tags kees flexcpy/next-20220502
git checkout ebd8c465eee86d64d9d8f2204db5971e6588174a
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=arc SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

Note: the kees/flexcpy/next-20220502 HEAD 1dbd8181297512b190aca23477043ac635daba4e builds fine.
It only hurts bisectability.

All errors (new ones prefixed by >>):

drivers/net/wireless/intel/iwlwifi/dvm/calib.c: In function 'iwl_calib_set':
>> drivers/net/wireless/intel/iwlwifi/dvm/calib.c:68:20: error: 'struct iwl_calib_result' has no member named 'hdr'
68 | memcpy(&res->hdr, cmd, len);
| ^~


vim +68 drivers/net/wireless/intel/iwlwifi/dvm/calib.c

6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 58
e19918855dc482 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2012-03-06 59 int iwl_calib_set(struct iwl_priv *priv,
ebd8c465eee86d drivers/net/wireless/intel/iwlwifi/dvm/calib.c Kees Cook 2021-07-31 60 const struct iwl_calib_cmd *cmd, int len)
6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 61 {
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 62 struct iwl_calib_result *res, *tmp;
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 63
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 64 res = kmalloc(sizeof(*res) + len - sizeof(struct iwl_calib_hdr),
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 65 GFP_ATOMIC);
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 66 if (!res)
6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 67 return -ENOMEM;
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 @68 memcpy(&res->hdr, cmd, len);
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 69 res->cmd_len = len;
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 70
e19918855dc482 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2012-03-06 71 list_for_each_entry(tmp, &priv->calib_results, list) {
ebd8c465eee86d drivers/net/wireless/intel/iwlwifi/dvm/calib.c Kees Cook 2021-07-31 72 if (tmp->cmd.hdr.op_code == res->cmd.hdr.op_code) {
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 73 list_replace(&tmp->list, &res->list);
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 74 kfree(tmp);
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 75 return 0;
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 76 }
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 77 }
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 78
f02c2fd383f4c7 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2011-11-17 79 /* wasn't in list already */
e19918855dc482 drivers/net/wireless/iwlwifi/iwl-agn-calib.c Johannes Berg 2012-03-06 80 list_add_tail(&res->list, &priv->calib_results);
6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 81
6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 82 return 0;
6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 83 }
6e21f2c109edd7 drivers/net/wireless/iwlwifi/iwl-calib.c Tomas Winkler 2008-09-03 84

:::::: The code at line 68 was first introduced by commit
:::::: f02c2fd383f4c771c75daf391abdbdcb88848439 iwlagn: dynamically allocate & reflect calibration data

:::::: TO: Johannes Berg <johannes.berg@xxxxxxxxx>
:::::: CC: Wey-Yi Guy <wey-yi.w.guy@xxxxxxxxx>

--
0-DAY CI Kernel Test Service
https://01.org/lkp