tree: https://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git master head: 119aadf816f5373dc82ca4109d6d5b777e00475b commit: f2bc8ad31a7f814237bc6301d59296d76505a688 [2177/2199] net: ethtool: Allow PHY cable test TDR data to configured config: arm64-randconfig-r011-20200527 (attached as .config) compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project 3393cc4cebf9969db94dc424b7a2b6195589c33b) 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 # install arm64 cross compiling tool for clang build # apt-get install binutils-aarch64-linux-gnu git checkout f2bc8ad31a7f814237bc6301d59296d76505a688 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64 If you fix the issue, kindly add following tag as appropriate Reported-by: kbuild test robot <lkp@xxxxxxxxx> All warnings (new ones prefixed by >>, old ones prefixed by <<): >> net/ethtool/cabletest.c:230:5: warning: no previous prototype for function 'ethnl_act_cable_test_tdr_cfg' [-Wmissing-prototypes] int ethnl_act_cable_test_tdr_cfg(const struct nlattr *nest, ^ net/ethtool/cabletest.c:230:1: note: declare 'static' if the function is not intended to be used outside of this translation unit int ethnl_act_cable_test_tdr_cfg(const struct nlattr *nest, ^ static 1 warning generated. vim +/ethnl_act_cable_test_tdr_cfg +230 net/ethtool/cabletest.c 228 229 /* CABLE_TEST_TDR_ACT */ > 230 int ethnl_act_cable_test_tdr_cfg(const struct nlattr *nest, 231 struct genl_info *info, 232 struct phy_tdr_config *cfg) 233 { 234 struct nlattr *tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_MAX + 1]; 235 int ret; 236 237 ret = nla_parse_nested(tb, ETHTOOL_A_CABLE_TEST_TDR_CFG_MAX, nest, 238 cable_test_tdr_act_cfg_policy, info->extack); 239 if (ret < 0) 240 return ret; 241 242 if (tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_FIRST]) 243 cfg->first = nla_get_u32( 244 tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_FIRST]); 245 else 246 cfg->first = 100; 247 if (tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_LAST]) 248 cfg->last = nla_get_u32(tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_LAST]); 249 else 250 cfg->last = MAX_CABLE_LENGTH_CM; 251 252 if (tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_STEP]) 253 cfg->step = nla_get_u32(tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_STEP]); 254 else 255 cfg->step = 100; 256 257 if (tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_PAIR]) { 258 cfg->pair = nla_get_u8(tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_PAIR]); 259 if (cfg->pair > ETHTOOL_A_CABLE_PAIR_D) { 260 NL_SET_ERR_MSG_ATTR( 261 info->extack, 262 tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_PAIR], 263 "invalid pair parameter"); 264 return -EINVAL; 265 } 266 } else { 267 cfg->pair = PHY_PAIR_ALL; 268 } 269 270 if (cfg->first > MAX_CABLE_LENGTH_CM) { 271 NL_SET_ERR_MSG_ATTR(info->extack, 272 tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_FIRST], 273 "invalid first parameter"); 274 return -EINVAL; 275 } 276 277 if (cfg->last > MAX_CABLE_LENGTH_CM) { 278 NL_SET_ERR_MSG_ATTR(info->extack, 279 tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_LAST], 280 "invalid last parameter"); 281 return -EINVAL; 282 } 283 284 if (cfg->first > cfg->last) { 285 NL_SET_ERR_MSG(info->extack, "invalid first/last parameter"); 286 return -EINVAL; 287 } 288 289 if (!cfg->step) { 290 NL_SET_ERR_MSG_ATTR(info->extack, 291 tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_STEP], 292 "invalid step parameter"); 293 return -EINVAL; 294 } 295 296 if (cfg->step > (cfg->last - cfg->first)) { 297 NL_SET_ERR_MSG_ATTR(info->extack, 298 tb[ETHTOOL_A_CABLE_TEST_TDR_CFG_STEP], 299 "step parameter too big"); 300 return -EINVAL; 301 } 302 303 return 0; 304 } 305 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx
Attachment:
.config.gz
Description: application/gzip