netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Alexander Duyck <alexander.h.duyck@intel.com>,
	netdev@vger.kernel.org, gospo@redhat.com, sassmann@redhat.com,
	Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Subject: [net-next 7/7] skbuff: Move rxhash and vlan_tci to consolidate holes in sk_buff
Date: Fri, 10 Feb 2012 16:08:24 -0800	[thread overview]
Message-ID: <1328918904-11511-8-git-send-email-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <1328918904-11511-1-git-send-email-jeffrey.t.kirsher@intel.com>

From: Alexander Duyck <alexander.h.duyck@intel.com>

This change helps to reduce the overall size of the sk_buff by moving
rxhash and vlan_tci so that the u16 values and u8 bitfields can be better
combined to create only one hole instead of multiple.

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>
---
 include/linux/skbuff.h |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index 50db9b0..2b7317f 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
@@ -438,6 +438,11 @@ struct sk_buff {
 #endif
 
 	int			skb_iif;
+
+	__u32			rxhash;
+
+	__u16			vlan_tci;
+
 #ifdef CONFIG_NET_SCHED
 	__u16			tc_index;	/* traffic control index */
 #ifdef CONFIG_NET_CLS_ACT
@@ -445,8 +450,6 @@ struct sk_buff {
 #endif
 #endif
 
-	__u32			rxhash;
-
 	__u16			queue_mapping;
 	kmemcheck_bitfield_begin(flags2);
 #ifdef CONFIG_IPV6_NDISC_NODETYPE
@@ -470,8 +473,6 @@ struct sk_buff {
 		__u32		dropcount;
 	};
 
-	__u16			vlan_tci;
-
 	sk_buff_data_t		transport_header;
 	sk_buff_data_t		network_header;
 	sk_buff_data_t		mac_header;
-- 
1.7.7.6

  parent reply	other threads:[~2012-02-11  0:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-11  0:08 [net-next 0/7][pull request] Intel Wired LAN Driver Updates Jeff Kirsher
2012-02-11  0:08 ` [net-next 1/7] ixgbe: Minor refactor of RSC Jeff Kirsher
2012-02-11  0:08 ` [net-next 2/7] ixgbe: Address fact that RSC was not setting GSO size for incoming frames Jeff Kirsher
2012-02-11  0:08 ` [net-next 3/7] ixgbe: Let the Rx buffer allocation clear status bits instead of cleanup Jeff Kirsher
2012-02-11  0:08 ` [net-next 4/7] ixgbe: Add function for testing status bits in Rx descriptor Jeff Kirsher
2012-02-11 19:06   ` Ben Hutchings
2012-02-13 17:21     ` Alexander Duyck
2012-02-13 17:37       ` Ben Hutchings
2012-02-11  0:08 ` [net-next 5/7] ixgbe: Drop the _ADV of descriptor macros since all ixgbe descriptors are ADV Jeff Kirsher
2012-02-11  0:08 ` [net-next 6/7] ixgbe: Combine post-DMA processing of sk_buff fields into single function Jeff Kirsher
2012-02-11  0:08 ` Jeff Kirsher [this message]
2012-02-12 22:05 ` [net-next 0/7][pull request] Intel Wired LAN Driver Updates David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1328918904-11511-8-git-send-email-jeffrey.t.kirsher@intel.com \
    --to=jeffrey.t.kirsher@intel.com \
    --cc=alexander.h.duyck@intel.com \
    --cc=davem@davemloft.net \
    --cc=gospo@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=sassmann@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).