On 1/31/26 17:21, Ingyu Jang wrote:
Hi,I noticed that in drivers/net/ethernet/intel/ixgbe/ixgbe_common.c, the function ixgbe_init_eeprom_params_generic() always returns 0. The function (at line 860) performs EEPROM initialization and always ends with: return 0; However, in drivers/net/ethernet/intel/ixgbe/ixgbe_e610.c, there are multiple places where the return value is checked through the function pointer hw->eeprom.ops.init_params(hw): 1. ixgbe_read_ee_e610() at line 3627: err = hw->eeprom.ops.init_params(hw); if (err) return err; 2. ixgbe_write_ee_e610() at line 3660: err = hw->eeprom.ops.init_params(hw); if (err) return err; 3. ixgbe_validate_ee_e610() at line 3693: err = hw->eeprom.ops.init_params(hw); if (err) return err; The init_params function pointer points to ixgbe_init_eeprom_params_generic for 82598 and 82599 chips (ixgbe_82598.c:1164, ixgbe_82599.c:2225). Since ixgbe_init_eeprom_params_generic() never fails, these error checks appear to be dead code for those chip types. Is this intentional defensive coding for potential future changes, or could this be cleaned up? Thanks, Ingyu Jang
thank you this originates from our OOT implementation which is over 20 years old by now feel free to send patch that cleans this up (and similar stuff if you find more)
