1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00
linux/drivers/net/ethernet/intel/fm10k
Jacob Keller 1343c65f70 fm10k: always check init_hw for errors
A recent change modified init_hw in some flows the function may fail on
VF devices. For example, if a VF doesn't yet own its own queues.
However, many callers of init_hw didn't bother to check the error code.
Other callers checked but only displayed diagnostic messages without
actually handling the consequences.

Fix this by (a) always returning and preventing the netdevice from going
up, and (b) printing the diagnostic in every flow for consistency. This
should resolve an issue where VF drivers would attempt to come up
before the PF has finished assigning queues.

In addition, change the dmesg output to explicitly show the actual
function that failed, instead of combining reset_hw and init_hw into a
single check, to help for future debugging.

Fixes: 1d568b0f6424 ("fm10k: do not assume VF always has 1 queue")
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Reviewed-by: Bruce Allan <bruce.w.allan@intel.com>
Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2015-12-05 23:55:15 -08:00
..
fm10k.h fm10k: set netdev features in one location 2015-12-05 23:55:13 -08:00
fm10k_common.c fm10k: Resolve various spelling errors and checkpatch warnings 2015-03-03 01:07:23 -08:00
fm10k_common.h fm10k: Add support for ptp to hw specific files 2014-09-23 03:59:22 -07:00
fm10k_dcbnl.c fm10k: fix unused warnings 2015-04-14 15:23:36 -07:00
fm10k_debugfs.c fm10k: use snprintf() instead of sprintf() to avoid buffer overflow 2015-10-13 23:49:13 -07:00
fm10k_ethtool.c drivers/net: get rid of unnecessary initializations in .get_drvinfo() 2015-10-16 00:24:10 -07:00
fm10k_iov.c fm10k: add support for extra debug statistics 2015-09-22 15:58:27 -07:00
fm10k_main.c fm10k: Fix handling of NAPI budget when multiple queues are enabled per vector 2015-11-23 11:08:49 -08:00
fm10k_mbx.c fm10k: TRIVIAL remove unnecessary comma 2015-09-22 15:58:27 -07:00
fm10k_mbx.h fm10k: Add support for PF <-> VF mailbox 2014-09-23 03:59:20 -07:00
fm10k_netdev.c fm10k: set netdev features in one location 2015-12-05 23:55:13 -08:00
fm10k_pci.c fm10k: always check init_hw for errors 2015-12-05 23:55:15 -08:00
fm10k_pf.c fm10k: fix iov_msg_mac_vlan_pf VID checks 2015-09-15 17:06:23 -07:00
fm10k_pf.h fm10k: pack TLV overlay structures 2015-06-17 14:21:22 -07:00
fm10k_ptp.c fm10k: fix incorrect free on skb in ts_tx_enqueue 2015-06-17 14:20:36 -07:00
fm10k_tlv.c fm10k: Resolve various spelling errors and checkpatch warnings 2015-03-03 01:07:23 -08:00
fm10k_tlv.h fm10k: Add support for mailbox 2014-09-23 03:59:14 -07:00
fm10k_type.h fm10k: do not assume VF always has 1 queue 2015-11-23 11:08:47 -08:00
fm10k_vf.c fm10k: reset max_queues on init_hw_vf failure 2015-12-05 23:55:14 -08:00
fm10k_vf.h fm10k: Add support for ptp to hw specific files 2014-09-23 03:59:22 -07:00
Makefile fm10k: Add support for PTP 2014-09-23 03:59:23 -07:00