Re: [PATCH] net: make WARN_ON in dev_disable_lro() useful

David Miller
2011-04-25T18:57:14Z

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Fri, 22 Apr 2011 07:11:53 +0200

> Le vendredi 22 avril 2011 à 00:42 +0200, Michał Mirosław a écrit :
>> Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
>> ---
>> net/core/dev.c | 3 ++-
>> 1 files changed, 2 insertions(+), 1 deletions(-)
>>
>> diff --git a/net/core/dev.c b/net/core/dev.c
>> index 3871bf6..3421184 100644
>> --- a/net/core/dev.c
>> +++ b/net/core/dev.c
>> @@ -1315,7 +1315,8 @@ void dev_disable_lro(struct net_device *dev)
>> return;
>>
>> __ethtool_set_flags(dev, flags & ~ETH_FLAG_LRO);
>> - WARN_ON(dev->features & NETIF_F_LRO);
>> + if (unlikely(dev->features & NETIF_F_LRO))
>> + netdev_WARN(dev, "failed to disable LRO!\n");
>> }
>> EXPORT_SYMBOL(dev_disable_lro);
>>
>
> Yes, as suggested one month ago
> http://permalink.gmane.org/gmane.linux.network/189951
>
> Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>

Applied, thanks.