net/intel: call ndo_stop() instead of dev_close() when running offline selftest
Subsystems (3)
cover net/intel: call ndo_stop() instead of dev_close() when running offline selftest
Calling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
Tested this with igb, e1000e, ixgbe and i40e. All drivers now are able to resume operation without restoring the IP address, gateway or such.
Stefan Assmann (6):
i40e: call ndo_stop() instead of dev_close() when running offline
selftest
ixgbe: call ndo_stop() instead of dev_close() when running offline
selftest
ixgbevf: call ndo_stop() instead of dev_close() when running offline
selftest
igb: call ndo_stop() instead of dev_close() when running offline
selftest
e1000: call ndo_stop() instead of dev_close() when running offline
selftest
e1000e: call ndo_stop() instead of dev_close() when running offline
selftest
drivers/net/ethernet/intel/e1000/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000/e1000_ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000/e1000_main.c | 8 ++++---- drivers/net/ethernet/intel/e1000e/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000e/ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++-- drivers/net/ethernet/intel/i40e/i40e.h | 2 +- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 4 ++-- drivers/net/ethernet/intel/i40e/i40e_main.c | 4 ---- drivers/net/ethernet/intel/igb/igb.h | 2 ++ drivers/net/ethernet/intel/igb/igb_ethtool.c | 4 ++-- drivers/net/ethernet/intel/igb/igb_main.c | 8 ++++---- drivers/net/ethernet/intel/ixgbe/ixgbe.h | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ++-- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 4 ++-- drivers/net/ethernet/intel/ixgbevf/ethtool.c | 4 ++-- drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 2 ++ drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 4 ++-- 18 files changed, 37 insertions(+), 31 deletions(-)
Signature · 1 line
2.5.0
PATCH 1/6 i40e: call ndo_stop() instead of dev_close() when running offline selftest
Calling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
--- drivers/net/ethernet/intel/i40e/i40e.h | 2 +- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 4 ++-- drivers/net/ethernet/intel/i40e/i40e_main.c | 4 ---- 3 files changed, 3 insertions(+), 7 deletions(-)
drivers/net/ethernet/intel/i40e/i40e.h +1 -1
@@ -773,6 +773,7 @@ int i40e_vlan_rx_kill_vid(struct net_device *netdev, __always_unused __be16 proto, u16 vid);#endif int i40e_open (struct net_device *netdev); +int i40e_close (struct net_device *netdev);int i40e_vsi_open (struct i40e_vsi *vsi);void i40e_vlan_stripping_disable (struct i40e_vsi *vsi);int i40e_vsi_add_vlan (struct i40e_vsi *vsi,s16 vid);
@@ -785,7 +786,6 @@ bool i40e_is_vsi_in_vlan(struct i40e_vsi *vsi);struct i40e_mac_filter *i40e_find_mac (struct i40e_vsi *vsi,u8 *macaddr,bool is_vf,bool is_netdev);#ifdef I40E_FCOE -int i40e_close (struct net_device *netdev);int i40e_setup_tc (struct net_device *netdev,u8 tc);void i40e_netpoll (struct net_device *netdev);int i40e_fcoe_enable (struct net_device *netdev);
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +2 -2
@@ -1704,7 +1704,7 @@ static void i40e_diag_test(struct net_device *netdev,/* If the device is online then take it offline */ if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +i40e_close (netdev);else /* This reset does not affect link - if it is * changed to a type of reset that does affect
@@ -1733,7 +1733,7 @@ static void i40e_diag_test(struct net_device *netdev,i40e_do_reset (pf,BIT (__I40E_PF_RESET_REQUESTED));if (if_running) -dev_open (netdev); +i40e_open (netdev); }else {/* Online tests */ netif_info (pf, drv, netdev,"online testing starting\n" );
drivers/net/ethernet/intel/i40e/i40e_main.c +0 -4
@@ -5459,11 +5459,7 @@ static void i40e_fdir_filter_exit(struct i40e_pf *pf)* * Returns 0, this is not allowed to fail **/ -#ifdef I40E_FCOE int i40e_close (struct net_device *netdev) -#else -static int i40e_close(struct net_device *netdev) -#endif {struct i40e_netdev_priv *np =netdev_priv (netdev);struct i40e_vsi *vsi = np->vsi;
Signature · 1 line
2.5.0
PATCH 2/6 ixgbe: call ndo_stop() instead of dev_close() when running offline selftest
In reply to Stefan AssmannCalling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
--- drivers/net/ethernet/intel/ixgbe/ixgbe.h | 2 ++ drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ++-- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/ixgbe/ixgbe.h +2 -0
@@ -875,6 +875,8 @@ extern const char ixgbe_driver_version[];extern char ixgbe_default_device_descr[];#endif /* IXGBE_FCOE */ +int ixgbe_open (struct net_device *netdev); +int ixgbe_close (struct net_device *netdev);void ixgbe_up (struct ixgbe_adapter *adapter);void ixgbe_down (struct ixgbe_adapter *adapter);void ixgbe_reinit_locked (struct ixgbe_adapter *adapter);
drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c +2 -2
@@ -2053,7 +2053,7 @@ static void ixgbe_diag_test(struct net_device *netdev,if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +ixgbe_close (netdev);else ixgbe_reset (adapter);
@@ -2091,7 +2091,7 @@ skip_loopback:/* clear testing bit and return adapter to previous state */ clear_bit (__IXGBE_TESTING, &adapter->state);if (if_running) -dev_open (netdev); +ixgbe_open (netdev);else if (hw->mac.ops.disable_tx_laser) hw->mac.ops.disable_tx_laser (hw); }else {
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +2 -2
@@ -5988,7 +5988,7 @@ static int ixgbe_change_mtu(struct net_device *netdev, int new_mtu)* handler is registered with the OS, the watchdog timer is started, * and the stack is notified that the interface is ready. **/ -static int ixgbe_open (struct net_device *netdev) +int ixgbe_open (struct net_device *netdev) {struct ixgbe_adapter *adapter =netdev_priv (netdev);struct ixgbe_hw *hw = &adapter->hw;
@@ -6090,7 +6090,7 @@ static void ixgbe_close_suspend(struct ixgbe_adapter *adapter)* needs to be disabled. A global MAC reset is issued to stop the * hardware, and all transmit and receive resources are freed. **/ -static int ixgbe_close (struct net_device *netdev) +int ixgbe_close (struct net_device *netdev) {struct ixgbe_adapter *adapter =netdev_priv (netdev);
Signature · 1 line
2.5.0
PATCH 3/6 ixgbevf: call ndo_stop() instead of dev_close() when running offline selftest
In reply to Stefan AssmannCalling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
--- drivers/net/ethernet/intel/ixgbevf/ethtool.c | 4 ++-- drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 2 ++ drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/ixgbevf/ethtool.c +2 -2
@@ -680,7 +680,7 @@ static void ixgbevf_diag_test(struct net_device *netdev,if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +ixgbevf_close (netdev);else ixgbevf_reset (adapter);
@@ -692,7 +692,7 @@ static void ixgbevf_diag_test(struct net_device *netdev,clear_bit (__IXGBEVF_TESTING, &adapter->state);if (if_running) -dev_open (netdev); +ixgbevf_open (netdev); }else {hw_dbg (&adapter->hw,"online testing starting\n" );/* Online tests */
drivers/net/ethernet/intel/ixgbevf/ixgbevf.h +2 -0
@@ -486,6 +486,8 @@ extern const struct ixgbe_mbx_operations ixgbevf_mbx_ops;extern const char ixgbevf_driver_name[];extern const char ixgbevf_driver_version[]; +int ixgbevf_open (struct net_device *netdev); +int ixgbevf_close (struct net_device *netdev);void ixgbevf_up (struct ixgbevf_adapter *adapter);void ixgbevf_down (struct ixgbevf_adapter *adapter);void ixgbevf_reinit_locked (struct ixgbevf_adapter *adapter);
drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c +2 -2
@@ -3122,7 +3122,7 @@ static void ixgbevf_free_all_rx_resources(struct ixgbevf_adapter *adapter)* handler is registered with the OS, the watchdog timer is started, * and the stack is notified that the interface is ready. **/ -static int ixgbevf_open (struct net_device *netdev) +int ixgbevf_open (struct net_device *netdev) {struct ixgbevf_adapter *adapter =netdev_priv (netdev);struct ixgbe_hw *hw = &adapter->hw;
@@ -3205,7 +3205,7 @@ err_setup_reset:* needs to be disabled. A global MAC reset is issued to stop the * hardware, and all transmit and receive resources are freed. **/ -static int ixgbevf_close (struct net_device *netdev) +int ixgbevf_close (struct net_device *netdev) {struct ixgbevf_adapter *adapter =netdev_priv (netdev);
Signature · 1 line
2.5.0
Bowers
PATCH 3/6 ixgbevf: call ndo_stop() instead of dev_close() when running offline selftest
Quoted 17 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Stefan Assmann
Sent: Tuesday, February 02, 2016 2:14 AM
To: intel-wired-lan at lists.osuosl.org
Cc: netdev at vger.kernel.org; davem at davemloft.net; sassmann at kpanic.de
Subject: [Intel-wired-lan] [PATCH net-next 3/6] ixgbevf: callndo_stop()instead ofdev_close()when running offline selftestCalling
dev_close()causesIFF_UPto be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call thenet_device_opsndo_stopfunction directly and avoid touchingIFF_UPat all.
Quoted 6 lines
Signed-off-by Stefan Assmann <[email protected]>--- drivers/net/ethernet/intel/ixgbevf/ethtool.c | 4 ++-- drivers/net/ethernet/intel/ixgbevf/ixgbevf.h | 2 ++ drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-)
ethtool offline selftest does not wipe information from interface (route, etc...)
PATCH 4/6 igb: call ndo_stop() instead of dev_close() when running offline selftest
In reply to Stefan AssmannCalling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
--- drivers/net/ethernet/intel/igb/igb.h | 2 ++ drivers/net/ethernet/intel/igb/igb_ethtool.c | 4 ++-- drivers/net/ethernet/intel/igb/igb_main.c | 8 ++++---- 3 files changed, 8 insertions(+), 6 deletions(-)
drivers/net/ethernet/intel/igb/igb.h +2 -0
@@ -510,6 +510,8 @@ enum igb_boards {extern char igb_driver_name[];extern char igb_driver_version[]; +int igb_open (struct net_device *netdev); +int igb_close (struct net_device *netdev);int igb_up (struct igb_adapter *);void igb_down (struct igb_adapter *);void igb_reinit_locked (struct igb_adapter *);
drivers/net/ethernet/intel/igb/igb_ethtool.c +2 -2
@@ -2017,7 +2017,7 @@ static void igb_diag_test(struct net_device *netdev,if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +igb_close (netdev);else igb_reset (adapter);
@@ -2050,7 +2050,7 @@ static void igb_diag_test(struct net_device *netdev,clear_bit (__IGB_TESTING, &adapter->state);if (if_running) -dev_open (netdev); +igb_open (netdev); }else {dev_info (&adapter->pdev->dev,"online testing starting\n" );
drivers/net/ethernet/intel/igb/igb_main.c +4 -4
@@ -122,8 +122,8 @@ static void igb_setup_mrqc(struct igb_adapter *);static int igb_probe (struct pci_dev *,const struct pci_device_id *);static void igb_remove (struct pci_dev *pdev);static int igb_sw_init (struct igb_adapter *); -static int igb_open (struct net_device *); -static int igb_close (struct net_device *); +int igb_open (struct net_device *); +int igb_close (struct net_device *);static void igb_configure (struct igb_adapter *);static void igb_configure_tx (struct igb_adapter *);static void igb_configure_rx (struct igb_adapter *);
@@ -3132,7 +3132,7 @@ err_setup_tx:return err; } -static int igb_open (struct net_device *netdev) +int igb_open (struct net_device *netdev) {return __igb_open (netdev, false); }
@@ -3169,7 +3169,7 @@ static int __igb_close(struct net_device *netdev, bool suspending)return 0 ; } -static int igb_close (struct net_device *netdev) +int igb_close (struct net_device *netdev) {return __igb_close (netdev, false); }
Signature · 1 line
2.5.0
PATCH 5/6 e1000: call ndo_stop() instead of dev_close() when running offline selftest
In reply to Stefan AssmannCalling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
--- drivers/net/ethernet/intel/e1000/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000/e1000_ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000/e1000_main.c | 8 ++++---- 3 files changed, 8 insertions(+), 6 deletions(-)
drivers/net/ethernet/intel/e1000/e1000.h +2 -0
@@ -358,6 +358,8 @@ struct net_device *e1000_get_hw_dev(struct e1000_hw *hw);extern char e1000_driver_name[];extern const char e1000_driver_version[]; +int e1000_open (struct net_device *netdev); +int e1000_close (struct net_device *netdev);int e1000_up (struct e1000_adapter *adapter);void e1000_down (struct e1000_adapter *adapter);void e1000_reinit_locked (struct e1000_adapter *adapter);
drivers/net/ethernet/intel/e1000/e1000_ethtool.c +2 -2
@@ -1553,7 +1553,7 @@ static void e1000_diag_test(struct net_device *netdev,if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +e1000_close (netdev);else e1000_reset (adapter);
@@ -1582,7 +1582,7 @@ static void e1000_diag_test(struct net_device *netdev,e1000_reset (adapter);clear_bit (__E1000_TESTING, &adapter->flags);if (if_running) -dev_open (netdev); +e1000_open (netdev); }else {e_info (hw,"online testing starting\n" );/* Online tests */
drivers/net/ethernet/intel/e1000/e1000_main.c +4 -4
@@ -114,8 +114,8 @@ static int e1000_probe(struct pci_dev *pdev, const struct pci_device_id *ent);static void e1000_remove (struct pci_dev *pdev);static int e1000_alloc_queues (struct e1000_adapter *adapter);static int e1000_sw_init (struct e1000_adapter *adapter); -static int e1000_open (struct net_device *netdev); -static int e1000_close (struct net_device *netdev); +int e1000_open (struct net_device *netdev); +int e1000_close (struct net_device *netdev);static void e1000_configure_tx (struct e1000_adapter *adapter);static void e1000_configure_rx (struct e1000_adapter *adapter);static void e1000_setup_rctl (struct e1000_adapter *adapter);
@@ -1360,7 +1360,7 @@ static int e1000_alloc_queues(struct e1000_adapter *adapter)* handler is registered with the OS, the watchdog task is started, * and the stack is notified that the interface is ready. **/ -static int e1000_open (struct net_device *netdev) +int e1000_open (struct net_device *netdev) {struct e1000_adapter *adapter =netdev_priv (netdev);struct e1000_hw *hw = &adapter->hw;
@@ -1437,7 +1437,7 @@ err_setup_tx:* needs to be disabled. A global MAC reset is issued to stop the * hardware, and all transmit and receive resources are freed. **/ -static int e1000_close (struct net_device *netdev) +int e1000_close (struct net_device *netdev) {struct e1000_adapter *adapter =netdev_priv (netdev);struct e1000_hw *hw = &adapter->hw;
Signature · 1 line
2.5.0
PATCH 6/6 e1000e: call ndo_stop() instead of dev_close() when running offline selftest
In reply to Stefan AssmannCalling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
--- drivers/net/ethernet/intel/e1000e/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000e/ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/e1000e/e1000.h +2 -0
@@ -480,6 +480,8 @@ extern const char e1000e_driver_version[];void e1000e_check_options (struct e1000_adapter *adapter);void e1000e_set_ethtool_ops (struct net_device *netdev); +int e1000_open (struct net_device *netdev); +int e1000_close (struct net_device *netdev);void e1000e_up (struct e1000_adapter *adapter);void e1000e_down (struct e1000_adapter *adapter,bool reset);void e1000e_reinit_locked (struct e1000_adapter *adapter);
drivers/net/ethernet/intel/e1000e/ethtool.c +2 -2
@@ -1816,7 +1816,7 @@ static void e1000_diag_test(struct net_device *netdev,if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +e1000_close (netdev);if (e1000_reg_test (adapter, &data[0 ])) eth_test->flags |=ETH_TEST_FL_FAILED ;
@@ -1849,7 +1849,7 @@ static void e1000_diag_test(struct net_device *netdev,clear_bit (__E1000_TESTING, &adapter->state);if (if_running) -dev_open (netdev); +e1000_open (netdev); }else {/* Online tests */
drivers/net/ethernet/intel/e1000e/netdev.c +2 -2
@@ -4506,7 +4506,7 @@ static int e1000_test_msi(struct e1000_adapter *adapter)* handler is registered with the OS, the watchdog timer is started, * and the stack is notified that the interface is ready. **/ -static int e1000_open (struct net_device *netdev) +int e1000_open (struct net_device *netdev) {struct e1000_adapter *adapter =netdev_priv (netdev);struct e1000_hw *hw = &adapter->hw;
@@ -4614,7 +4614,7 @@ err_setup_tx:* needs to be disabled. A global MAC reset is issued to stop the * hardware, and all transmit and receive resources are freed. **/ -static int e1000_close (struct net_device *netdev) +int e1000_close (struct net_device *netdev) {struct e1000_adapter *adapter =netdev_priv (netdev);struct pci_dev *pdev = adapter->pdev;
Signature · 1 line
2.5.0
kbuild test robot
build botRe: [PATCH net-next 6/6] e1000e: call ndo_stop() instead of dev_close() when running offline selftest
reproduce:
Hi Stefan,
[auto build test ERROR on net-next/master]
url: https://github.com/0day-ci/linux/commits/Stefan-Assmann/net-intel-call-ndo_stop-instead-of-dev_close-when-running-offline-selftest/20160202-182015 config: i386-defconfig (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=i386
All errors (new ones prefixed by >>):
drivers/net/ethernet/intel/e1000e/built-in.o: In function `e1000_close':
>> (.text+0x1c1a0): multiple definition of `e1000_close' drivers/net/ethernet/intel/e1000/built-in.o:(.text+0x5290): first defined here drivers/net/ethernet/intel/e1000e/built-in.o: In function `e1000_open': >> (.text+0x1a950): multiple definition of `e1000_open'
drivers/net/ethernet/intel/e1000/built-in.o:(.text+0x7b70): first defined here
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Re: [PATCH net-next 6/6] e1000e: call ndo_stop() instead of dev_close() when running offline selftest
In reply to Stefan AssmannHere's a V2 that fixes the name collision.
From 8f617672b97324058adf5b8981c4b91defad8c3a Mon Sep 17 00:00:00 2001
From: Stefan Assmann <[email protected]>
Date: Mon, 1 Feb 2016 13:18:24 +0100
Subject: [PATCH net-next] e1000e: call ndo_stop() instead of dev_close() when
running offline selftest
Calling dev_close() causes IFF_UP to be cleared which will remove the interfaces routes and some addresses. That's probably not what the user intended when running the offline selftest. Besides this does not happen if the interface is brought down before the test, so the current behaviour is inconsistent.
Instead call the net_device_ops ndo_stop function directly and avoid touching IFF_UP at all.
V2: rename e1000_open(), e1000_close() to e1000e_open(), e1000e_close() to avoid name clash with e1000.
--- drivers/net/ethernet/intel/e1000e/e1000.h | 2 ++ drivers/net/ethernet/intel/e1000e/ethtool.c | 4 ++-- drivers/net/ethernet/intel/e1000e/netdev.c | 12 ++++++------ 3 files changed, 10 insertions(+), 8 deletions(-)
drivers/net/ethernet/intel/e1000e/e1000.h +2 -0
@@ -480,6 +480,8 @@ extern const char e1000e_driver_version[];void e1000e_check_options (struct e1000_adapter *adapter);void e1000e_set_ethtool_ops (struct net_device *netdev); +int e1000e_open (struct net_device *netdev); +int e1000e_close (struct net_device *netdev);void e1000e_up (struct e1000_adapter *adapter);void e1000e_down (struct e1000_adapter *adapter,bool reset);void e1000e_reinit_locked (struct e1000_adapter *adapter);
drivers/net/ethernet/intel/e1000e/ethtool.c +2 -2
@@ -1816,7 +1816,7 @@ static void e1000_diag_test(struct net_device *netdev,if (if_running)/* indicate we're in test mode */ -dev_close (netdev); +e1000e_close (netdev);if (e1000_reg_test (adapter, &data[0 ])) eth_test->flags |=ETH_TEST_FL_FAILED ;
@@ -1849,7 +1849,7 @@ static void e1000_diag_test(struct net_device *netdev,clear_bit (__E1000_TESTING, &adapter->state);if (if_running) -dev_open (netdev); +e1000e_open (netdev); }else {/* Online tests */
drivers/net/ethernet/intel/e1000e/netdev.c +6 -6
@@ -4495,7 +4495,7 @@ static int e1000_test_msi(struct e1000_adapter *adapter) }/** -* e1000_open - Called when a network interface is made active +* e1000e_open - Called when a network interface is made active * @netdev: network interface device structure * * Returns 0 on success, negative value on failure
@@ -4506,7 +4506,7 @@ static int e1000_test_msi(struct e1000_adapter *adapter)* handler is registered with the OS, the watchdog timer is started, * and the stack is notified that the interface is ready. **/ -static int e1000_open (struct net_device *netdev) +int e1000e_open (struct net_device *netdev) {struct e1000_adapter *adapter =netdev_priv (netdev);struct e1000_hw *hw = &adapter->hw;
@@ -4604,7 +4604,7 @@ err_setup_tx: }/** -* e1000_close - Disables a network interface +* e1000e_close - Disables a network interface * @netdev: network interface device structure * * Returns 0, this is not allowed to fail
@@ -4614,7 +4614,7 @@ err_setup_tx:* needs to be disabled. A global MAC reset is issued to stop the * hardware, and all transmit and receive resources are freed. **/ -static int e1000_close (struct net_device *netdev) +int e1000e_close (struct net_device *netdev) {struct e1000_adapter *adapter =netdev_priv (netdev);struct pci_dev *pdev = adapter->pdev;
@@ -6920,8 +6920,8 @@ static int e1000_set_features(struct net_device *netdev, }static const struct net_device_ops e1000e_netdev_ops = { - .ndo_open = e1000_open, - .ndo_stop = e1000_close, + .ndo_open = e1000e_open, + .ndo_stop = e1000e_close, .ndo_start_xmit = e1000_xmit_frame, .ndo_get_stats64 = e1000e_get_stats64, .ndo_set_rx_mode = e1000e_set_rx_mode,
Signature · 1 line
2.5.0
David Miller
maintainerRe: [PATCH net-next 6/6] e1000e: call ndo_stop() instead of dev_close() when running offline selftest
Always, when sending an updated version of a patch which is part of a series, always resubmit the entire series rather than just the patch which is changing.
Thanks.
Re: [PATCH net-next 6/6] e1000e: call ndo_stop() instead of dev_close() when running offline selftest
Quoted 7 lines · David Miller
Always, when sending an updated version of a patch which is part of a series, always resubmit the entire series rather than just the patch which is changing.
Thanks.
Sorry Dave, going to send out a complete V2 right away.
Stefan