]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/log
linux-2.6-omap-h63xx.git
15 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
David S. Miller [Mon, 23 Mar 2009 20:35:04 +0000 (13:35 -0700)]
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6

Conflicts:
drivers/net/ucc_geth.c

15 years agosunqe: Convert to net_device_ops.
David S. Miller [Mon, 23 Mar 2009 20:33:37 +0000 (13:33 -0700)]
sunqe: Convert to net_device_ops.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosunlance: Convert to net_device_ops.
David S. Miller [Mon, 23 Mar 2009 20:33:28 +0000 (13:33 -0700)]
sunlance: Convert to net_device_ops.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosunbmac: Convert to net_device_ops.
David S. Miller [Mon, 23 Mar 2009 20:33:21 +0000 (13:33 -0700)]
sunbmac: Convert to net_device_ops.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agomyri_sbus: Convert to net_device_ops.
David S. Miller [Mon, 23 Mar 2009 20:33:11 +0000 (13:33 -0700)]
myri_sbus: Convert to net_device_ops.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoatl1c: remove duplicated #include
Huang Weiyi [Mon, 23 Mar 2009 08:18:58 +0000 (01:18 -0700)]
atl1c: remove duplicated #include

Remove duplicated #include in drivers/net/atl1c/atl1c.h.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agospider_net: Fix build.
David S. Miller [Mon, 23 Mar 2009 08:03:04 +0000 (01:03 -0700)]
spider_net: Fix build.

Based upon a report by Stephen Rothwell.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agotcp: Discard segments that ack data not yet sent
John Dykstra [Mon, 23 Mar 2009 04:49:57 +0000 (21:49 -0700)]
tcp: Discard segments that ack data not yet sent

Discard incoming packets whose ack field iincludes data not yet sent.
This is consistent with RFC 793 Section 3.9.

Change tcp_ack() to distinguish between too-small and too-large ack
field values.  Keep segments with too-large ack fields out of the fast
path, and change slow path to discard them.

Reported-by: Oliver Zheng <mailinglists+netdev@oliverzheng.com>
Signed-off-by: John Dykstra <john.dykstra1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoucc_geth: Fix oops when using fixed-link support
Anton Vorontsov [Mon, 23 Mar 2009 04:30:52 +0000 (21:30 -0700)]
ucc_geth: Fix oops when using fixed-link support

commit b1c4a9dddf09fe99b8f88252718ac5b357363dc4 ("ucc_geth: Change
uec phy id to the same format as gianfar's") introduced a regression
in the ucc_geth driver that causes this oops when fixed-link is used:

Unable to handle kernel paging request for data at address 0x00000000
Faulting instruction address: 0xc0151270
Oops: Kernel access of bad area, sig: 11 [#1]
TMCUTU
NIP: c0151270 LR: c0151270 CTR: c0017760
REGS: cf81fa60 TRAP: 0300   Not tainted  (2.6.29-rc8)
MSR: 00009032 <EE,ME,IR,DR>  CR: 24024042  XER: 20000000
DAR: 00000000, DSISR: 20000000
TASK = cf81cba0[1] 'swapper' THREAD: cf81e000
GPR00: c0151270 cf81fb10 cf81cba0 00000000 c0272e20 c025f354 00001e80
cf86b08c
GPR08: d1068200 cffffb74 06000000 d106c200 42024042 10085148 0fffd000
0ffc81a0
GPR16: 00000001 00000001 00000000 007ffeb0 00000000 0000c000 cf83f36c
cf83f000
GPR24: 00000030 cf83f360 cf81fb20 00000000 d106c200 20000000 00001e80
cf83f360
NIP [c0151270] ucc_geth_open+0x330/0x1efc
LR [c0151270] ucc_geth_open+0x330/0x1efc
Call Trace:
[cf81fb10] [c0151270] ucc_geth_open+0x330/0x1efc (unreliable)
[cf81fba0] [c0187638] dev_open+0xbc/0x12c
[cf81fbc0] [c0187e38] dev_change_flags+0x8c/0x1b0

This patch fixes the issue by removing offending (and somewhat
duplicate) code from init_phy() routine, and changes _probe()
function to use uec_mdio_bus_name().

Also, since we fully construct phy_bus_id in the _probe() routine,
we no longer need ->phy_address and ->mdio_bus fields in
ucc_geth_info structure.

I wish the patch would be a bit shorter, but it seems like the only
way to fix the issue in a sane way. Luckily, the patch has been
tested with real PHYs and fixed-link, so no further regressions
expected.

Reported-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Tested-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agodm9000: locking bugfix
David Brownell [Mon, 23 Mar 2009 04:28:39 +0000 (21:28 -0700)]
dm9000: locking bugfix

This fixes a locking bug in the dm9000 driver.  It calls
request_irq() without setting IRQF_DISABLED ... which is
correct for handlers that support IRQ sharing, since that
behavior is not guaranteed for shared IRQs.  However, its
IRQ handler then wrongly assumes that IRQs are blocked.
So the fix just uses the right spinlock primitives in the
IRQ handler.

NOTE:  this is a classic example of the type of bug which
lockdep currently masks by forcibly setting IRQF_DISABLED
on IRQ handlers that did not request that flag.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: Adding licensing to bnx2x_init_values.h
Eilon Greenstein [Mon, 23 Mar 2009 04:24:19 +0000 (21:24 -0700)]
bnx2x: Adding licensing to bnx2x_init_values.h

Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agonet: update dnet.c for bus_id removal
Stephen Rothwell [Mon, 23 Mar 2009 04:22:48 +0000 (21:22 -0700)]
net: update dnet.c for bus_id removal

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agonetdev: expose net_device_ops compat as config option
Stephen Hemminger [Fri, 20 Mar 2009 19:36:44 +0000 (19:36 +0000)]
netdev: expose net_device_ops compat as config option

Now that most network device drivers in (all but one in x86_64 allmodconfig)
support net_device_ops. Expose it as a configuration parameter. Still
need to address even older 32 bit drivers, and other arch before
compatiablity can be scheduled for removal in some future release.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agohostap: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:43 +0000 (19:36 +0000)]
hostap: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agohostap: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:42 +0000 (19:36 +0000)]
hostap: convert to internal net_device_stats

Use pre-existing net_device_stats in network_device struct.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipw2200: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:41 +0000 (19:36 +0000)]
ipw2200: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipw2100: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:40 +0000 (19:36 +0000)]
ipw2100: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipw2x00: convert infrastructure for use by net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:39 +0000 (19:36 +0000)]
ipw2x00: convert infrastructure for use by net_device_ops

Expose routines so drivers can hook. Only set ptrs in netdev
if using old compat code.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipw2x00: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:38 +0000 (19:36 +0000)]
ipw2x00: convert to internal net_device_stats

Replace struct in ieee with current net_device_stats, so no longer
need get_stats hook

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agolibertas: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:37 +0000 (19:36 +0000)]
libertas: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agolibertas: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:36 +0000 (19:36 +0000)]
libertas: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoprism54: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:35 +0000 (19:36 +0000)]
prism54: convert to internal net_device_stats

Also, make ethtool_ops const as it should be, and get rid
of useless cast.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoprism54: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:34 +0000 (19:36 +0000)]
prism54: convert to net_device_ops

Also, make ethtool_ops const as it should be, and get rid
of useless cast.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agomac80211_hwsim: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:33 +0000 (19:36 +0000)]
mac80211_hwsim: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agozd1201: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:32 +0000 (19:36 +0000)]
zd1201: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agozd1201: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:31 +0000 (19:36 +0000)]
zd1201: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agowl3501: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:30 +0000 (19:36 +0000)]
wl3501: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agowl3501: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:29 +0000 (19:36 +0000)]
wl3501: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoraylan: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:28 +0000 (19:36 +0000)]
raylan: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoatmel: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:27 +0000 (19:36 +0000)]
atmel: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoairo: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:26 +0000 (19:36 +0000)]
airo: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agowavelan: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:25 +0000 (19:36 +0000)]
wavelan: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agowavelan: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:24 +0000 (19:36 +0000)]
wavelan: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agostrip: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:23 +0000 (19:36 +0000)]
strip: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agonetwave: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:22 +0000 (19:36 +0000)]
netwave: convert to net_device_ops

Also get rid of unneeded cast

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agonetwave: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:21 +0000 (19:36 +0000)]
netwave: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosbni: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:20 +0000 (19:36 +0000)]
sbni: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosbni: use internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:19 +0000 (19:36 +0000)]
sbni: use internal net_device_stats

Convert to use existing net_device_stats.
This driver,
      has bad style,
       of using commas,
   when brackets should be used...

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agolabether: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:18 +0000 (19:36 +0000)]
labether: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agolapbether: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:17 +0000 (19:36 +0000)]
lapbether: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agocycx: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:16 +0000 (19:36 +0000)]
cycx: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agodlci: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:15 +0000 (19:36 +0000)]
dlci: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agodlci: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:14 +0000 (19:36 +0000)]
dlci: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agox25_asy: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:13 +0000 (19:36 +0000)]
x25_asy: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agox25_asy: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:12 +0000 (19:36 +0000)]
x25_asy: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoaxnet: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:11 +0000 (19:36 +0000)]
axnet: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosmc91c92: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:10 +0000 (19:36 +0000)]
smc91c92: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosmc91c92: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:09 +0000 (19:36 +0000)]
smc91c92: convert to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoxirc2ps: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:08 +0000 (19:36 +0000)]
xirc2ps: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoxir2cps: convert to internal net_device stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:07 +0000 (19:36 +0000)]
xir2cps: convert to internal net_device stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopcnet: convert driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:06 +0000 (19:36 +0000)]
pcnet: convert driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopcmcia: convert nmclan driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:05 +0000 (19:36 +0000)]
pcmcia: convert nmclan driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopcmcia: convert fmvj18x driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:04 +0000 (19:36 +0000)]
pcmcia: convert fmvj18x driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopcmcia: convert fmvj18x driver to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:36:03 +0000 (19:36 +0000)]
pcmcia: convert fmvj18x driver to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopcmcia: convert 3c574 to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:02 +0000 (19:36 +0000)]
pcmcia: convert 3c574 to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopcmcia: convert 3c589 to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:01 +0000 (19:36 +0000)]
pcmcia: convert 3c589 to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert rndis driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:36:00 +0000 (19:36 +0000)]
usbnet: convert rndis driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert rndis driver to use dev_get_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:35:59 +0000 (19:35 +0000)]
usbnet: convert rndis driver to use dev_get_stats

dev_get_stats() handles all issues with net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert smsc95xx driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:58 +0000 (19:35 +0000)]
usbnet: convert smsc95xx driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Steve Glendinning <steve.glendinning@smsc.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert msc7830 driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:57 +0000 (19:35 +0000)]
usbnet: convert msc7830 driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert dms9601 driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:56 +0000 (19:35 +0000)]
usbnet: convert dms9601 driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert asix driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:55 +0000 (19:35 +0000)]
usbnet: convert asix driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: support net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:54 +0000 (19:35 +0000)]
usbnet: support net_device_ops

Use net_device_ops for usbnet device, and export for use
by other derived drivers.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:35:53 +0000 (19:35 +0000)]
usbnet: convert to internal net_device_stats

Default handler for net_device_stats already does same thing.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert hso driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:52 +0000 (19:35 +0000)]
usbnet: convert hso driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert rtl driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:51 +0000 (19:35 +0000)]
usbnet: convert rtl driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert to internal net_device stats
Stephen Hemminger [Fri, 20 Mar 2009 19:35:50 +0000 (19:35 +0000)]
usbnet: convert to internal net_device stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert catc device to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:49 +0000 (19:35 +0000)]
usbnet: convert catc device to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agousbnet: convert catc to internal net_device_stats
Stephen Hemminger [Fri, 20 Mar 2009 19:35:48 +0000 (19:35 +0000)]
usbnet: convert catc to internal net_device_stats

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert ks959 driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:47 +0000 (19:35 +0000)]
irda: convert ks959 driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert ksdazzle device to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:46 +0000 (19:35 +0000)]
irda: convert ksdazzle device to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert kingsun device to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:45 +0000 (19:35 +0000)]
irda: convert kingsun device to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert sir device to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:44 +0000 (19:35 +0000)]
irda: convert sir device to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert via-ircc to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:43 +0000 (19:35 +0000)]
irda: convert via-ircc to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert smsc driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:42 +0000 (19:35 +0000)]
irda: convert smsc driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert vlsi driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:41 +0000 (19:35 +0000)]
irda: convert vlsi driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert ali driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:40 +0000 (19:35 +0000)]
irda: convert ali driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert nsc_ircc driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:39 +0000 (19:35 +0000)]
irda: convert nsc_ircc driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert w83977af_ir to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:38 +0000 (19:35 +0000)]
irda: convert w83977af_ir to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agostir4200: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:37 +0000 (19:35 +0000)]
stir4200: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert mcs driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:36 +0000 (19:35 +0000)]
irda: convert mcs driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: convert irda_usb to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:35 +0000 (19:35 +0000)]
irda: convert irda_usb to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirlan: convert to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:34 +0000 (19:35 +0000)]
irlan: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoirda: net_device_ops ioctl fix
Stephen Hemminger [Fri, 20 Mar 2009 19:35:33 +0000 (19:35 +0000)]
irda: net_device_ops ioctl fix

Need to reference net_device_ops not old pointer.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoinfiniband: convert ipoib to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:32 +0000 (19:35 +0000)]
infiniband: convert ipoib to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoinfiniband: convert nes driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:31 +0000 (19:35 +0000)]
infiniband: convert nes driver to net_device_ops

Also, removed unnecessary memset() since alloc_netdev returns
zeroed memory.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoinfiniband: convert c2 to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:30 +0000 (19:35 +0000)]
infiniband: convert c2 to net_device_ops

Convert this driver to new net_device_ops infrastructure.
Also use default net_device get-stats infrastructure

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Reviewed-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoatm: convert clip driver to net_device_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:29 +0000 (19:35 +0000)]
atm: convert clip driver to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoatm: convert mpc device to using netdev_ops
Stephen Hemminger [Fri, 20 Mar 2009 19:35:28 +0000 (19:35 +0000)]
atm: convert mpc device to using netdev_ops

This converts the mpc device to using new netdevice_ops.
Compile tested only, needs more than usual review since
device was swaping pointers around etc.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosfc: Implement adaptive IRQ moderation
Ben Hutchings [Fri, 20 Mar 2009 13:30:37 +0000 (13:30 +0000)]
sfc: Implement adaptive IRQ moderation

Calculate a score for each 1000 IRQs:
- TX completions are worth 1 point
- RX completions are worth 4 if merged using LRO or 2 otherwise

Reduce moderation if the score is less than 10000, down to a minimum
of 5 us.  Increase moderation if the score is more than 20000, up to
the specified maximum.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosfc: Optimise falcon_writel_page_locked() for page > 0
Ben Hutchings [Fri, 20 Mar 2009 13:27:13 +0000 (13:27 +0000)]
sfc: Optimise falcon_writel_page_locked() for page > 0

The bug this function works around only applies to the first set of
page-mapped registers; other pages can be written without locking.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosfc: Remove unused private PCI register definitions
Ben Hutchings [Fri, 20 Mar 2009 13:26:55 +0000 (13:26 +0000)]
sfc: Remove unused private PCI register definitions

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosfc: Work around unreliable legacy interrupt status
Ben Hutchings [Fri, 20 Mar 2009 13:26:41 +0000 (13:26 +0000)]
sfc: Work around unreliable legacy interrupt status

In rare cases, reading the legacy interrupt status register can
acknowledge an event queue whose attention flag has not yet been set
in the register.  Until we service this event queue it will not
generate any more interrupts.  Therefore, as a secondary check, poll
the next slot in each active event queue whose flag is not set.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosfc: Pad packets to 33 bytes to prevent TX packet parser lockup
Ben Hutchings [Fri, 20 Mar 2009 13:25:39 +0000 (13:25 +0000)]
sfc: Pad packets to 33 bytes to prevent TX packet parser lockup

The packet parser used in the TX data path for locating checksum
fields can lose synchronisation with the TX queue manager when
handling packets that look like IPv4 but are too short (17-32 bytes).
Work around this by padding to 33 bytes.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agodsa: add switch chip cascading support
Lennert Buytenhek [Fri, 20 Mar 2009 09:52:09 +0000 (09:52 +0000)]
dsa: add switch chip cascading support

The initial version of the DSA driver only supported a single switch
chip per network interface, while DSA-capable switch chips can be
interconnected to form a tree of switch chips.  This patch adds support
for multiple switch chips on a network interface.

An example topology for a 16-port device with an embedded CPU is as
follows:

+-----+          +--------+       +--------+
|     |eth0    10| switch |9    10| switch |
| CPU +----------+        +-------+        |
|     |          | chip 0 |       | chip 1 |
+-----+          +---++---+       +---++---+
                     ||               ||
                     ||               ||
                     ||1000baseT      ||1000baseT
                     ||ports 1-8      ||ports 9-16

This requires a couple of interdependent changes in the DSA layer:

- The dsa platform driver data needs to be extended: there is still
  only one netdevice per DSA driver instance (eth0 in the example
  above), but each of the switch chips in the tree needs its own
  mii_bus device pointer, MII management bus address, and port name
  array. (include/net/dsa.h)  The existing in-tree dsa users need
  some small changes to deal with this. (arch/arm)

- The DSA and Ethertype DSA tagging modules need to be extended to
  use the DSA device ID field on receive and demultiplex the packet
  accordingly, and fill in the DSA device ID field on transmit
  according to which switch chip the packet is heading to.
  (net/dsa/tag_{dsa,edsa}.c)

- The concept of "CPU port", which is the switch chip port that the
  CPU is connected to (port 10 on switch chip 0 in the example), needs
  to be extended with the concept of "upstream port", which is the
  port on the switch chip that will bring us one hop closer to the CPU
  (port 10 for both switch chips in the example above).

- The dsa platform data needs to specify which ports on which switch
  chips are links to other switch chips, so that we can enable DSA
  tagging mode on them.  (For inter-switch links, we always use
  non-EtherType DSA tagging, since it has lower overhead.  The CPU
  link uses dsa or edsa tagging depending on what the 'root' switch
  chip supports.)  This is done by specifying "dsa" for the given
  port in the port array.

- The dsa platform data needs to be extended with information on via
  which port to reach any given switch chip from any given switch chip.
  This info is specified via the per-switch chip data struct ->rtable[]
  array, which gives the nexthop ports for each of the other switches
  in the tree.

For the example topology above, the dsa platform data would look
something like this:

static struct dsa_chip_data sw[2] = {
{
.mii_bus = &foo,
.sw_addr = 1,
.port_names[0] = "p1",
.port_names[1] = "p2",
.port_names[2] = "p3",
.port_names[3] = "p4",
.port_names[4] = "p5",
.port_names[5] = "p6",
.port_names[6] = "p7",
.port_names[7] = "p8",
.port_names[9] = "dsa",
.port_names[10] = "cpu",
.rtable = (s8 []){ -1, 9, },
}, {
.mii_bus = &foo,
.sw_addr = 2,
.port_names[0] = "p9",
.port_names[1] = "p10",
.port_names[2] = "p11",
.port_names[3] = "p12",
.port_names[4] = "p13",
.port_names[5] = "p14",
.port_names[6] = "p15",
.port_names[7] = "p16",
.port_names[10] = "dsa",
.rtable = (s8 []){ 10, -1, },
},
},

static struct dsa_platform_data pd = {
.netdev = &foo,
.nr_switches = 2,
.sw = sw,
};

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Tested-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agodsa: add support for the Marvell 88E6095/6095F switch chips
Lennert Buytenhek [Fri, 20 Mar 2009 09:50:39 +0000 (09:50 +0000)]
dsa: add support for the Marvell 88E6095/6095F switch chips

Add support for the Marvell 88E6095/6095F switch chips.  These
chips are similar to the 88e6131, so we can add the support to
mv88e6131.c easily.

Thanks to Gary Thomas <gary@mlbassoc.com> and Jesper Dangaard
Brouer <hawk@diku.dk> for testing various patches.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Tested-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agodsa: set ->iflink on slave interfaces to the ifindex of the parent
Lennert Buytenhek [Fri, 20 Mar 2009 09:49:49 +0000 (09:49 +0000)]
dsa: set ->iflink on slave interfaces to the ifindex of the parent

..so that we can parse the DSA topology from 'ip link' output:

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast qlen 1000
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast qlen 1000
4: lan1@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue
5: lan2@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue
6: lan3@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue
7: lan4@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoeql: fix non-constant printk warning
Stephen Hemminger [Fri, 20 Mar 2009 07:14:14 +0000 (07:14 +0000)]
eql: fix non-constant printk warning

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoatm: fix non-const printk argument
Stephen Hemminger [Fri, 20 Mar 2009 06:44:02 +0000 (06:44 +0000)]
atm: fix non-const printk argument

Change printk() argument to fix compiler warning.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipx: use constant for strings and desciptor
Stephen Hemminger [Fri, 20 Mar 2009 05:45:39 +0000 (05:45 +0000)]
ipx: use constant for strings and desciptor

Fix compiler warning about non-const format string.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>