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

Rustad, Mark D mark.d.rustad at intel.com
Tue Feb 16 17:24:34 UTC 2016


Aaron F <aaron.f.brown at intel.com> wrote:

>> From: Intel-wired-lan [intel-wired-lan-bounces at lists.osuosl.org] on  
>> behalf of Stefan Assmann [sassmann at kpanic.de]
>> Sent: Wednesday, February 03, 2016 12:20 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 V2 4/6] igb: 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 <sassmann at kpanic.de>
>> ---
>>  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(-)
>
> 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.brown at intel.com>

Again, the prototypes in the .c should be deleted in favor of the ones that  
were added to the .h file.

--
Mark Rustad, Networking Division, Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 841 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.osuosl.org/pipermail/intel-wired-lan/attachments/20160216/c30b8ef1/attachment.asc>


More information about the Intel-wired-lan mailing list