RE: [Intel-wired-lan] [PATCH net-next V2 5/6] e1000: call ndo_stop() instead of dev_close() when running offline selftest

2016-02-16 Thread Brown, Aaron F
> From: Rustad, Mark D
> Sent: Tuesday, February 16, 2016 9:23 AM
> To: Stefan Assmann
> Cc: intel-wired-...@lists.osuosl.org; netdev@vger.kernel.org; 
> da...@davemloft.net; Brown, Aaron F
> Subject: Re: [Intel-wired-lan] [PATCH net-next V2 5/6] e1000: call ndo_stop() 
>   instead of dev_close() when running offline selftest
> 
> > Checkpatch warns that externs should be avoided in .c files, but they
> > pre-existed and are just being flagged due to the name changing, so...
> >
> > Tested-by: Aaron Brown <aaron.f.br...@intel.com>
> 
> Actually, it is the forward declarations in the .c that should be deleted.
> The prototypes should only exist in the .h file.

Thanks Mark,  I completely missed that the patch added it to both files, too 
busy reviving older hardware to extend to run the diags against a larger set of 
parts I guess :")


Re: [Intel-wired-lan] [PATCH net-next V2 5/6] e1000: call ndo_stop() instead of dev_close() when running offline selftest

2016-02-16 Thread Rustad, Mark D

Aaron F  wrote:

From: Intel-wired-lan [intel-wired-lan-boun...@lists.osuosl.org] on  
behalf of Stefan Assmann [sassm...@kpanic.de]

Sent: Wednesday, February 03, 2016 12:20 AM
To: intel-wired-...@lists.osuosl.org
Cc: netdev@vger.kernel.org; da...@davemloft.net; sassm...@kpanic.de
Subject: [Intel-wired-lan] [PATCH net-next V2 5/6] e1000: 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.

Signed-off-by: Stefan Assmann 
---
 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(-)


Checkpatch warns that externs should be avoided in .c files, but they  
pre-existed and are just being flagged due to the name changing, so...


Tested-by: Aaron Brown 


Actually, it is the forward declarations in the .c that should be deleted.  
The prototypes should only exist in the .h file.


--
Mark Rustad, Networking Division, Intel Corporation


signature.asc
Description: Message signed with OpenPGP using GPGMail


RE: [Intel-wired-lan] [PATCH net-next V2 5/6] e1000: call ndo_stop() instead of dev_close() when running offline selftest

2016-02-12 Thread Brown, Aaron F
> From: Intel-wired-lan [intel-wired-lan-boun...@lists.osuosl.org] on behalf of 
> Stefan Assmann [sassm...@kpanic.de]
> Sent: Wednesday, February 03, 2016 12:20 AM
> To: intel-wired-...@lists.osuosl.org
> Cc: netdev@vger.kernel.org; da...@davemloft.net; sassm...@kpanic.de
> Subject: [Intel-wired-lan] [PATCH net-next V2 5/6] e1000: 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.
> 
> Signed-off-by: Stefan Assmann 
> ---
>  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(-)

Checkpatch warns that externs should be avoided in .c files, but they 
pre-existed and are just being flagged due to the name changing, so...

Tested-by: Aaron Brown