diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-01-19 23:25:45 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-01-19 23:25:45 -0500 |
commit | 1268afe676ee9431a229fc68a2efb0dad4d5852f (patch) | |
tree | c252b969a51bd97317415cfc3b6465441f1b8aec /net/core | |
parent | c56eb8fb6dccb83d9fe62fd4dc00c834de9bc470 (diff) | |
parent | 4580ccc04ddd8c17a470573a7fdb8def2e036dfa (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (41 commits)
sctp: user perfect name for Delayed SACK Timer option
net: fix can_checksum_protocol() arguments swap
Revert "netlink: test for all flags of the NLM_F_DUMP composite"
gianfar: Fix misleading indentation in startup_gfar()
net/irda/sh_irda: return to RX mode when TX error
net offloading: Do not mask out NETIF_F_HW_VLAN_TX for vlan.
USB CDC NCM: tx_fixup() race condition fix
ns83820: Avoid bad pointer deref in ns83820_init_one().
ipv6: Silence privacy extensions initialization
bnx2x: Update bnx2x version to 1.62.00-4
bnx2x: Fix AER setting for BCM57712
bnx2x: Fix BCM84823 LED behavior
bnx2x: Mark full duplex on some external PHYs
bnx2x: Fix BCM8073/BCM8727 microcode loading
bnx2x: LED fix for BCM8727 over BCM57712
bnx2x: Common init will be executed only once after POR
bnx2x: Swap BCM8073 PHY polarity if required
iwlwifi: fix valid chain reading from EEPROM
ath5k: fix locking in tx_complete_poll_work
ath9k_hw: do PA offset calibration only on longcal interval
...
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/dev.c | 6 | ||||
-rw-r--r-- | net/core/rtnetlink.c | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index 54277df0f735..7c6a46f80372 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
@@ -2001,7 +2001,7 @@ static bool can_checksum_protocol(unsigned long features, __be16 protocol) | |||
2001 | 2001 | ||
2002 | static int harmonize_features(struct sk_buff *skb, __be16 protocol, int features) | 2002 | static int harmonize_features(struct sk_buff *skb, __be16 protocol, int features) |
2003 | { | 2003 | { |
2004 | if (!can_checksum_protocol(protocol, features)) { | 2004 | if (!can_checksum_protocol(features, protocol)) { |
2005 | features &= ~NETIF_F_ALL_CSUM; | 2005 | features &= ~NETIF_F_ALL_CSUM; |
2006 | features &= ~NETIF_F_SG; | 2006 | features &= ~NETIF_F_SG; |
2007 | } else if (illegal_highdma(skb->dev, skb)) { | 2007 | } else if (illegal_highdma(skb->dev, skb)) { |
@@ -2023,13 +2023,13 @@ int netif_skb_features(struct sk_buff *skb) | |||
2023 | return harmonize_features(skb, protocol, features); | 2023 | return harmonize_features(skb, protocol, features); |
2024 | } | 2024 | } |
2025 | 2025 | ||
2026 | features &= skb->dev->vlan_features; | 2026 | features &= (skb->dev->vlan_features | NETIF_F_HW_VLAN_TX); |
2027 | 2027 | ||
2028 | if (protocol != htons(ETH_P_8021Q)) { | 2028 | if (protocol != htons(ETH_P_8021Q)) { |
2029 | return harmonize_features(skb, protocol, features); | 2029 | return harmonize_features(skb, protocol, features); |
2030 | } else { | 2030 | } else { |
2031 | features &= NETIF_F_SG | NETIF_F_HIGHDMA | NETIF_F_FRAGLIST | | 2031 | features &= NETIF_F_SG | NETIF_F_HIGHDMA | NETIF_F_FRAGLIST | |
2032 | NETIF_F_GEN_CSUM; | 2032 | NETIF_F_GEN_CSUM | NETIF_F_HW_VLAN_TX; |
2033 | return harmonize_features(skb, protocol, features); | 2033 | return harmonize_features(skb, protocol, features); |
2034 | } | 2034 | } |
2035 | } | 2035 | } |
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c index a5f7535aab5b..750db57f3bb3 100644 --- a/net/core/rtnetlink.c +++ b/net/core/rtnetlink.c | |||
@@ -1820,7 +1820,7 @@ static int rtnetlink_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
1820 | if (kind != 2 && security_netlink_recv(skb, CAP_NET_ADMIN)) | 1820 | if (kind != 2 && security_netlink_recv(skb, CAP_NET_ADMIN)) |
1821 | return -EPERM; | 1821 | return -EPERM; |
1822 | 1822 | ||
1823 | if (kind == 2 && (nlh->nlmsg_flags & NLM_F_DUMP) == NLM_F_DUMP) { | 1823 | if (kind == 2 && nlh->nlmsg_flags&NLM_F_DUMP) { |
1824 | struct sock *rtnl; | 1824 | struct sock *rtnl; |
1825 | rtnl_dumpit_func dumpit; | 1825 | rtnl_dumpit_func dumpit; |
1826 | 1826 | ||