diff options
author | Tejun Heo <tj@kernel.org> | 2011-05-24 03:59:36 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2011-05-24 03:59:36 -0400 |
commit | 6988f20fe04e9ef3aea488cb8ab57fbeb78e12f0 (patch) | |
tree | c9d7fc50a2e2147a5ca07e3096e7eeb916ad2da9 /net/core/dev.c | |
parent | 0415b00d175e0d8945e6785aad21b5f157976ce0 (diff) | |
parent | 6ea0c34dac89611126455537552cffe6c7e832ad (diff) |
Merge branch 'fixes-2.6.39' into for-2.6.40
Diffstat (limited to 'net/core/dev.c')
-rw-r--r-- | net/core/dev.c | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index 0b88eba97da..f453370131a 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
@@ -1353,14 +1353,17 @@ EXPORT_SYMBOL(dev_close); | |||
1353 | */ | 1353 | */ |
1354 | void dev_disable_lro(struct net_device *dev) | 1354 | void dev_disable_lro(struct net_device *dev) |
1355 | { | 1355 | { |
1356 | if (dev->ethtool_ops && dev->ethtool_ops->get_flags && | 1356 | u32 flags; |
1357 | dev->ethtool_ops->set_flags) { | 1357 | |
1358 | u32 flags = dev->ethtool_ops->get_flags(dev); | 1358 | if (dev->ethtool_ops && dev->ethtool_ops->get_flags) |
1359 | if (flags & ETH_FLAG_LRO) { | 1359 | flags = dev->ethtool_ops->get_flags(dev); |
1360 | flags &= ~ETH_FLAG_LRO; | 1360 | else |
1361 | dev->ethtool_ops->set_flags(dev, flags); | 1361 | flags = ethtool_op_get_flags(dev); |
1362 | } | 1362 | |
1363 | } | 1363 | if (!(flags & ETH_FLAG_LRO)) |
1364 | return; | ||
1365 | |||
1366 | __ethtool_set_flags(dev, flags & ~ETH_FLAG_LRO); | ||
1364 | WARN_ON(dev->features & NETIF_F_LRO); | 1367 | WARN_ON(dev->features & NETIF_F_LRO); |
1365 | } | 1368 | } |
1366 | EXPORT_SYMBOL(dev_disable_lro); | 1369 | EXPORT_SYMBOL(dev_disable_lro); |