diff options
author | Jesus Sanchez-Palencia <jesus.sanchez-palencia@intel.com> | 2018-07-03 18:42:58 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-07-04 09:30:28 -0400 |
commit | 1b9231e7e148520a3ba63a604b27f11093f21bee (patch) | |
tree | 0fb3c23698d38dc566190efb8bd0678b9c31eb68 /drivers/net/ethernet/intel/igb/igb_main.c | |
parent | 8080e6ab4e99216f414c5c314264fd7cf3b6e4c1 (diff) |
igb: Only call skb_tx_timestamp after descriptors are ready
Currently, skb_tx_timestamp() is being called before the Tx
descriptors are prepared in igb_xmit_frame_ring(), which happens
during either the igb_tso() or igb_tx_csum() calls.
Given that now the skb->tstamp might be used to carry the timestamp
for SO_TXTIME, we must only call skb_tx_timestamp() after the
information has been copied into the Tx descriptors.
Signed-off-by: Jesus Sanchez-Palencia <jesus.sanchez-palencia@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/intel/igb/igb_main.c')
-rw-r--r-- | drivers/net/ethernet/intel/igb/igb_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c index c30ab7b260cc..445da8285d9b 100644 --- a/drivers/net/ethernet/intel/igb/igb_main.c +++ b/drivers/net/ethernet/intel/igb/igb_main.c | |||
@@ -6033,8 +6033,6 @@ netdev_tx_t igb_xmit_frame_ring(struct sk_buff *skb, | |||
6033 | } | 6033 | } |
6034 | } | 6034 | } |
6035 | 6035 | ||
6036 | skb_tx_timestamp(skb); | ||
6037 | |||
6038 | if (skb_vlan_tag_present(skb)) { | 6036 | if (skb_vlan_tag_present(skb)) { |
6039 | tx_flags |= IGB_TX_FLAGS_VLAN; | 6037 | tx_flags |= IGB_TX_FLAGS_VLAN; |
6040 | tx_flags |= (skb_vlan_tag_get(skb) << IGB_TX_FLAGS_VLAN_SHIFT); | 6038 | tx_flags |= (skb_vlan_tag_get(skb) << IGB_TX_FLAGS_VLAN_SHIFT); |
@@ -6050,6 +6048,8 @@ netdev_tx_t igb_xmit_frame_ring(struct sk_buff *skb, | |||
6050 | else if (!tso) | 6048 | else if (!tso) |
6051 | igb_tx_csum(tx_ring, first); | 6049 | igb_tx_csum(tx_ring, first); |
6052 | 6050 | ||
6051 | skb_tx_timestamp(skb); | ||
6052 | |||
6053 | if (igb_tx_map(tx_ring, first, hdr_len)) | 6053 | if (igb_tx_map(tx_ring, first, hdr_len)) |
6054 | goto cleanup_tx_tstamp; | 6054 | goto cleanup_tx_tstamp; |
6055 | 6055 | ||