linux_old1/arch
Rusty Russell c45d286e72 [NET]: Inline net_device_stats
Network drivers which keep stats allocate their own stats structure
then write a get_stats() function to return them.  It would be nice if
this were done by default.

1) Add a new "stats" field to "struct net_device".
2) Add a new feature field to say "this driver uses the internal one"
3) Have a default "get_stats" which returns NULL if that feature not set.
4) Change callers to check result of get_stats call for NULL, not if
   ->get_stats is set.

This should not break backwards compatibility with older drivers, yet
allow modern drivers to shed some boilerplate code.

Lightly tested: works for a modified lguest network driver.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-25 22:28:26 -07:00
..
alpha alpha: build fixes - force architecture 2007-04-17 16:36:27 -07:00
arm [ARM] 4313/1: S3C24XX: Update s3c2410 defconfig to 2.6.21-rc6 2007-04-16 21:03:00 +01:00
arm26 [PATCH] arch/arm26/kernel/entry.S: remove dead code 2007-03-01 14:53:35 -08:00
avr32 [PATCH] gpio_direction_output() needs an initial value 2007-03-16 19:25:04 -07:00
cris [PATCH] MSI-X: fix resume crash 2007-03-28 13:59:37 -07:00
frv [PATCH] MSI-X: fix resume crash 2007-03-28 13:59:37 -07:00
h8300 [PATCH] Declare init_irq_proc before we use it. 2007-02-19 14:21:50 -08:00
i386 [PATCH] i386: Fix some warnings added by earlier patch 2007-04-24 13:05:37 +02:00
ia64 [SK_BUFF]: Introduce skb_copy_from_linear_data{_offset} 2007-04-25 22:28:23 -07:00
m32r Various typo fixes. 2007-02-17 19:07:33 +01:00
m68k [PATCH] Declare init_irq_proc before we use it. 2007-02-19 14:21:50 -08:00
m68knommu [PATCH] m68knommu: remove local_bh_count 2007-03-06 18:08:38 -08:00
mips [MIPS] Fix oprofile logic to physical counter remapping 2007-04-24 22:10:18 +01:00
parisc [PARISC] clocksource: Move update_cr16_clocksource later in boot 2007-02-26 22:21:22 -05:00
powerpc [POWERPC] mpc52xx_pic: fix main interrupt masking 2007-04-12 02:39:58 +10:00
ppc [ETH]: Make eth_type_trans set skb->dev like the other *_type_trans 2007-04-25 22:24:30 -07:00
s390 [NET]: Inline net_device_stats 2007-04-25 22:28:26 -07:00
sh sh: Kill bogus GCC4 symbol exports. 2007-03-28 17:24:47 +09:00
sh64 [PATCH] sysctl: remove insert_at_head from register_sysctl 2007-02-14 08:09:59 -08:00
sparc [SPARC]: Fix section mismatch warnings in pci.c and pcic.c 2007-04-12 13:47:37 -07:00
sparc64 [SPARC64]: Fix inline directive in pci_iommu.c 2007-04-13 13:35:35 -07:00
um [SK_BUFF]: Introduce skb_mac_header() 2007-04-25 22:24:41 -07:00
v850 kbuild: Replace remaining "depends" with "depends on" 2007-02-17 19:05:24 +01:00
x86_64 [PATCH] x86-64: Always flush all pages in change_page_attr 2007-04-24 13:05:37 +02:00
xtensa [SK_BUFF]: Introduce skb_reset_mac_header(skb) 2007-04-25 22:24:32 -07:00