tree: https://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue.git dev-queue head: 692375ca2a4e6916ddc2ef0d73faa37c7a93cd1a commit: 6b998cf3e55cb55c817e12fdd5b05b3ab162cca7 [41/50] ixgbe: extend .info_get with stored versions config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20250221/[email protected]/config) compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250221/[email protected]/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 <[email protected]> | Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ All warnings (new ones prefixed by >>): In file included from drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:4: In file included from drivers/net/ethernet/intel/ixgbe/ixgbe.h:9: In file included from include/linux/pci.h:37: In file included from include/linux/device.h:32: In file included from include/linux/device/driver.h:21: In file included from include/linux/module.h:19: In file included from include/linux/elf.h:6: In file included from arch/s390/include/asm/elf.h:181: In file included from arch/s390/include/asm/mmu_context.h:11: In file included from arch/s390/include/asm/pgalloc.h:18: In file included from include/linux/mm.h:2224: include/linux/vmstat.h:504:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion] 504 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~ ^ 505 | item]; | ~~~~ include/linux/vmstat.h:511:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion] 511 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~ ^ 512 | NR_VM_NUMA_EVENT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~~ include/linux/vmstat.h:524:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion] 524 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~ ^ 525 | NR_VM_NUMA_EVENT_ITEMS + | ~~~~~~~~~~~~~~~~~~~~~~ >> drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:45:12: warning: variable >> 'orom' is used uninitialized whenever 'if' condition is false >> [-Wsometimes-uninitialized] 45 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:49:5: note: uninitialized use occurs here 49 | orom->major, orom->build, orom->patch); | ^~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:45:8: note: remove the 'if' if its condition is always true 45 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 46 | orom = &ctx->pending_orom; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:41:31: note: initialize the variable 'orom' to silence this warning 41 | struct ixgbe_orom_info *orom; | ^ | = NULL >> drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:80:12: warning: variable >> 'eetrack' is used uninitialized whenever 'if' condition is false >> [-Wsometimes-uninitialized] 80 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:83:50: note: uninitialized use occurs here 83 | snprintf(ctx->buf, sizeof(ctx->buf), "0x%08x", eetrack); | ^~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:80:8: note: remove the 'if' if its condition is always true 80 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 81 | eetrack = ctx->pending_nvm.eetrack; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:76:14: note: initialize the variable 'eetrack' to silence this warning 76 | u32 eetrack; | ^ | = 0 >> drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:124:11: warning: variable >> 'nvm' is used uninitialized whenever 'if' condition is false >> [-Wsometimes-uninitialized] 124 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:127:45: note: uninitialized use occurs here 127 | snprintf(ctx->buf, sizeof(ctx->buf), "%u", nvm->srev); | ^~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:124:7: note: remove the 'if' if its condition is always true 124 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 125 | nvm = &ctx->pending_nvm; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:120:28: note: initialize the variable 'nvm' to silence this warning 120 | struct ixgbe_nvm_info *nvm; | ^ | = NULL drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:138:11: warning: variable 'orom' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] 138 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:141:45: note: uninitialized use occurs here 141 | snprintf(ctx->buf, sizeof(ctx->buf), "%u", orom->srev); | ^~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:138:7: note: remove the 'if' if its condition is always true 138 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 139 | orom = &ctx->pending_orom; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:134:30: note: initialize the variable 'orom' to silence this warning 134 | struct ixgbe_orom_info *orom; | ^ | = NULL drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:152:11: warning: variable 'nvm' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] 152 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:155:50: note: uninitialized use occurs here 155 | snprintf(ctx->buf, sizeof(ctx->buf), "%x.%02x", nvm->major, nvm->minor); | ^~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:152:7: note: remove the 'if' if its condition is always true 152 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 153 | nvm = &ctx->pending_nvm; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:148:28: note: initialize the variable 'nvm' to silence this warning 148 | struct ixgbe_nvm_info *nvm; | ^ | = NULL >> drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:166:11: warning: variable >> 'netlist' is used uninitialized whenever 'if' condition is false >> [-Wsometimes-uninitialized] 166 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:171:4: note: uninitialized use occurs here 171 | netlist->major, netlist->minor, | ^~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:166:7: note: remove the 'if' if its condition is always true 166 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 167 | netlist = &ctx->pending_netlist; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:162:36: note: initialize the variable 'netlist' to silence this warning 162 | struct ixgbe_netlist_info *netlist; | ^ | = NULL drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:184:11: warning: variable 'netlist' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] 184 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:187:49: note: uninitialized use occurs here 187 | snprintf(ctx->buf, sizeof(ctx->buf), "0x%08x", netlist->hash); | ^~~~~~~ drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:184:7: note: remove the 'if' if its condition is always true 184 | else if (type == IXGBE_DL_VERSION_STORED) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 185 | netlist = &ctx->pending_netlist; drivers/net/ethernet/intel/ixgbe/devlink/devlink.c:180:36: note: initialize the variable 'netlist' to silence this warning 180 | struct ixgbe_netlist_info *netlist; | ^ | = NULL 10 warnings generated. vim +45 drivers/net/ethernet/intel/ixgbe/devlink/devlink.c 30 31 static void ixgbe_info_orom_ver(struct ixgbe_adapter *adapter, 32 struct ixgbe_info_ctx *ctx, 33 enum ixgbe_devlink_version_type type) 34 { 35 struct ixgbe_hw *hw = &adapter->hw; 36 struct ixgbe_nvm_version nvm_ver; 37 38 ctx->buf[0] = '\0'; 39 40 if (hw->mac.type == ixgbe_mac_e610) { 41 struct ixgbe_orom_info *orom; 42 43 if (type == IXGBE_DL_VERSION_RUNNING) 44 orom = &adapter->hw.flash.orom; > 45 else if (type == IXGBE_DL_VERSION_STORED) 46 orom = &ctx->pending_orom; 47 48 snprintf(ctx->buf, sizeof(ctx->buf), "%d.%d.%d", 49 orom->major, orom->build, orom->patch); 50 return; 51 } 52 53 ixgbe_get_oem_prod_version(hw, &nvm_ver); 54 if (nvm_ver.oem_valid) { 55 snprintf(ctx->buf, sizeof(ctx->buf), "%x.%x.%x", 56 nvm_ver.oem_major, nvm_ver.oem_minor, 57 nvm_ver.oem_release); 58 59 return; 60 } 61 62 ixgbe_get_orom_version(hw, &nvm_ver); 63 if (nvm_ver.or_valid) 64 snprintf(ctx->buf, sizeof(ctx->buf), "%d.%d.%d", 65 nvm_ver.or_major, nvm_ver.or_build, nvm_ver.or_patch); 66 } 67 68 static void ixgbe_info_eetrack(struct ixgbe_adapter *adapter, 69 struct ixgbe_info_ctx *ctx, 70 enum ixgbe_devlink_version_type type) 71 { 72 struct ixgbe_hw *hw = &adapter->hw; 73 struct ixgbe_nvm_version nvm_ver; 74 75 if (hw->mac.type == ixgbe_mac_e610) { 76 u32 eetrack; 77 78 if (type == IXGBE_DL_VERSION_RUNNING) 79 eetrack = hw->flash.nvm.eetrack; > 80 else if (type == IXGBE_DL_VERSION_STORED) 81 eetrack = ctx->pending_nvm.eetrack; 82 83 snprintf(ctx->buf, sizeof(ctx->buf), "0x%08x", eetrack); 84 return; 85 } 86 87 ixgbe_get_oem_prod_version(hw, &nvm_ver); 88 89 /* No ETRACK version for OEM */ 90 if (nvm_ver.oem_valid) { 91 ctx->buf[0] = '\0'; 92 return; 93 } 94 95 ixgbe_get_etk_id(hw, &nvm_ver); 96 snprintf(ctx->buf, sizeof(ctx->buf), "0x%08x", nvm_ver.etk_id); 97 } 98 99 static void ixgbe_info_fw_api(struct ixgbe_adapter *adapter, 100 struct ixgbe_info_ctx *ctx) 101 { 102 struct ixgbe_hw *hw = &adapter->hw; 103 104 snprintf(ctx->buf, sizeof(ctx->buf), "%u.%u.%u", 105 hw->api_maj_ver, hw->api_min_ver, hw->api_patch); 106 } 107 108 static void ixgbe_info_fw_build(struct ixgbe_adapter *adapter, 109 struct ixgbe_info_ctx *ctx) 110 { 111 struct ixgbe_hw *hw = &adapter->hw; 112 113 snprintf(ctx->buf, sizeof(ctx->buf), "0x%08x", hw->fw_build); 114 } 115 116 static void ixgbe_info_fw_srev(struct ixgbe_adapter *adapter, 117 struct ixgbe_info_ctx *ctx, 118 enum ixgbe_devlink_version_type type) 119 { 120 struct ixgbe_nvm_info *nvm; 121 122 if (type == IXGBE_DL_VERSION_RUNNING) 123 nvm = &adapter->hw.flash.nvm; > 124 else if (type == IXGBE_DL_VERSION_STORED) 125 nvm = &ctx->pending_nvm; 126 127 snprintf(ctx->buf, sizeof(ctx->buf), "%u", nvm->srev); 128 } 129 130 static void ixgbe_info_orom_srev(struct ixgbe_adapter *adapter, 131 struct ixgbe_info_ctx *ctx, 132 enum ixgbe_devlink_version_type type) 133 { 134 struct ixgbe_orom_info *orom; 135 136 if (type == IXGBE_DL_VERSION_RUNNING) 137 orom = &adapter->hw.flash.orom; 138 else if (type == IXGBE_DL_VERSION_STORED) 139 orom = &ctx->pending_orom; 140 141 snprintf(ctx->buf, sizeof(ctx->buf), "%u", orom->srev); 142 } 143 144 static void ixgbe_info_nvm_ver(struct ixgbe_adapter *adapter, 145 struct ixgbe_info_ctx *ctx, 146 enum ixgbe_devlink_version_type type) 147 { 148 struct ixgbe_nvm_info *nvm; 149 150 if (type == IXGBE_DL_VERSION_RUNNING) 151 nvm = &adapter->hw.flash.nvm; 152 else if (type == IXGBE_DL_VERSION_STORED) 153 nvm = &ctx->pending_nvm; 154 155 snprintf(ctx->buf, sizeof(ctx->buf), "%x.%02x", nvm->major, nvm->minor); 156 } 157 158 static void ixgbe_info_netlist_ver(struct ixgbe_adapter *adapter, 159 struct ixgbe_info_ctx *ctx, 160 enum ixgbe_devlink_version_type type) 161 { 162 struct ixgbe_netlist_info *netlist; 163 164 if (type == IXGBE_DL_VERSION_RUNNING) 165 netlist = &adapter->hw.flash.netlist; > 166 else if (type == IXGBE_DL_VERSION_STORED) 167 netlist = &ctx->pending_netlist; 168 169 /* The netlist version fields are BCD formatted */ 170 snprintf(ctx->buf, sizeof(ctx->buf), "%x.%x.%x-%x.%x.%x", 171 netlist->major, netlist->minor, 172 netlist->type >> 16, netlist->type & 0xFFFF, 173 netlist->rev, netlist->cust_ver); 174 } 175 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
