]> err.no Git - linux-2.6/commitdiff
skge: rearrange fields
authorStephen Hemminger <shemminger@linux-foundation.org>
Fri, 16 Mar 2007 21:01:31 +0000 (14:01 -0700)
committerJeff Garzik <jeff@garzik.org>
Sat, 28 Apr 2007 15:01:00 +0000 (11:01 -0400)
Do some minor rearrangement of data structures to try and optimize
cache usage.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/net/skge.h

index 3b16597c5d4220250c35c19fb9460dcd5f1c4bbe..edd71468220ca0e5a19377db04ed312f773181fd 100644 (file)
@@ -2446,15 +2446,15 @@ enum pause_status {
 
 
 struct skge_port {
-       u32                  msg_enable;
        struct skge_hw       *hw;
        struct net_device    *netdev;
        int                  port;
+       u32                  msg_enable;
 
        struct skge_ring     tx_ring;
-       struct skge_ring     rx_ring;
 
-       struct net_device_stats net_stats;
+       struct skge_ring     rx_ring ____cacheline_aligned_in_smp;
+       unsigned int         rx_buf_size;
 
        struct timer_list    link_timer;
        enum pause_control   flow_control;
@@ -2470,7 +2470,8 @@ struct skge_port {
        void                 *mem;      /* PCI memory for rings */
        dma_addr_t           dma;
        unsigned long        mem_size;
-       unsigned int         rx_buf_size;
+
+       struct net_device_stats net_stats;
 };