diff options
author | Alexander Duyck <alexander.h.duyck@intel.com> | 2012-02-08 07:50:56 +0000 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2012-03-17 01:08:23 -0700 |
commit | fd0db0ed02a6abce5427e90d1e8522322107d62b (patch) | |
tree | 0fa1df643c68e44d7c0a77e67a67d6e72526e57a /drivers/net/ethernet/intel/ixgbe/ixgbe.h | |
parent | 7d7ce682f8437ff91c964c478b8845ed98a3207d (diff) | |
download | lwn-fd0db0ed02a6abce5427e90d1e8522322107d62b.tar.gz lwn-fd0db0ed02a6abce5427e90d1e8522322107d62b.zip |
ixgbe: Place skb on first buffer_info structure to avoid using stack space
Instead of keeping a local copy of the skb on the stack for as long as long
as we do it makes sense to instead just place it on the first tx_buffer
structure so that we can save space on the stack and avoid unnecessary
read/write operations copying the pointer out of the stack and onto the
ring later.
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Tested-by: Stephen Ko <stephen.s.ko@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ixgbe/ixgbe.h')
-rw-r--r-- | drivers/net/ethernet/intel/ixgbe/ixgbe.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe.h b/drivers/net/ethernet/intel/ixgbe/ixgbe.h index 6d4ef1a30890..55f31fe58e41 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe.h +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe.h @@ -150,12 +150,12 @@ struct vf_macvlans { struct ixgbe_tx_buffer { union ixgbe_adv_tx_desc *next_to_watch; unsigned long time_stamp; + struct sk_buff *skb; + unsigned int bytecount; + unsigned short gso_segs; dma_addr_t dma; - u32 length; + unsigned int length; u32 tx_flags; - struct sk_buff *skb; - u32 bytecount; - u16 gso_segs; }; struct ixgbe_rx_buffer { @@ -631,7 +631,8 @@ extern void ixgbe_tx_ctxtdesc(struct ixgbe_ring *, u32, u32, u32, u32); extern void ixgbe_do_reset(struct net_device *netdev); #ifdef IXGBE_FCOE extern void ixgbe_configure_fcoe(struct ixgbe_adapter *adapter); -extern int ixgbe_fso(struct ixgbe_ring *tx_ring, struct sk_buff *skb, +extern int ixgbe_fso(struct ixgbe_ring *tx_ring, + struct ixgbe_tx_buffer *first, u32 tx_flags, u8 *hdr_len); extern void ixgbe_cleanup_fcoe(struct ixgbe_adapter *adapter); extern int ixgbe_fcoe_ddp(struct ixgbe_adapter *adapter, |