diff options
author | Patrick Ohly <patrick.ohly@intel.com> | 2009-02-21 05:42:18 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-02-21 05:42:18 -0500 |
commit | cd4d8fdad1f13205c769266dfa99015e226b6e07 (patch) | |
tree | 23861c718a558e457971cca009c3ac944f90891e /net/core | |
parent | be0c22a46cfb79ab2342bb28fde99afa94ef868e (diff) |
net: kernel panic in dev_hard_start_xmit: remove faulty software TX time stamping
The current implementation of the TX software time stamping fallback is
faulty because it accesses the skb after ndo_start_xmit() returns
successfully. This patch removes the fallback, which fixes kernel panics
seen during stress tests. Hardware time stamping is not affected by this
removal.
Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/dev.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index 5493394118fb..88dc082b47d1 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
@@ -1672,16 +1672,6 @@ static int dev_gso_segment(struct sk_buff *skb) | |||
1672 | return 0; | 1672 | return 0; |
1673 | } | 1673 | } |
1674 | 1674 | ||
1675 | static void tstamp_tx(struct sk_buff *skb) | ||
1676 | { | ||
1677 | union skb_shared_tx *shtx = | ||
1678 | skb_tx(skb); | ||
1679 | if (unlikely(shtx->software && | ||
1680 | !shtx->in_progress)) { | ||
1681 | skb_tstamp_tx(skb, NULL); | ||
1682 | } | ||
1683 | } | ||
1684 | |||
1685 | int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev, | 1675 | int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev, |
1686 | struct netdev_queue *txq) | 1676 | struct netdev_queue *txq) |
1687 | { | 1677 | { |
@@ -1715,8 +1705,6 @@ int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev, | |||
1715 | * the skb destructor before the call and restoring it | 1705 | * the skb destructor before the call and restoring it |
1716 | * afterwards, then doing the skb_orphan() ourselves? | 1706 | * afterwards, then doing the skb_orphan() ourselves? |
1717 | */ | 1707 | */ |
1718 | if (likely(!rc)) | ||
1719 | tstamp_tx(skb); | ||
1720 | return rc; | 1708 | return rc; |
1721 | } | 1709 | } |
1722 | 1710 | ||
@@ -1732,7 +1720,6 @@ gso: | |||
1732 | skb->next = nskb; | 1720 | skb->next = nskb; |
1733 | return rc; | 1721 | return rc; |
1734 | } | 1722 | } |
1735 | tstamp_tx(skb); | ||
1736 | if (unlikely(netif_tx_queue_stopped(txq) && skb->next)) | 1723 | if (unlikely(netif_tx_queue_stopped(txq) && skb->next)) |
1737 | return NETDEV_TX_BUSY; | 1724 | return NETDEV_TX_BUSY; |
1738 | } while (skb->next); | 1725 | } while (skb->next); |