diff options
author | Kevin Hao <kexin.hao@windriver.com> | 2008-09-19 17:56:44 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-10-08 18:29:35 -0400 |
commit | 8d1b1fc9b97ad4de40c063ce3d213895c06fa116 (patch) | |
tree | 80af7c1eac50f00797da91fd82663574b219fd4a | |
parent | 6fbc779c03591ee536fef9efb7d7e20f281d0b5c (diff) |
net: add net poll support for atl2 driver
Add netconsole support for Atheros L2 10/100 network device.
Signed-off-by: Kevin Hao <kexin.hao@windriver.com>
Acked-by: Jay Cliburn <jacliburn@bellsouth.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/atlx/atl2.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c index 5ab9c7631002..4f82f6661535 100644 --- a/drivers/net/atlx/atl2.c +++ b/drivers/net/atlx/atl2.c | |||
@@ -1329,6 +1329,15 @@ static void atl2_setup_pcicmd(struct pci_dev *pdev) | |||
1329 | pci_write_config_dword(pdev, REG_PM_CTRLSTAT, 0); | 1329 | pci_write_config_dword(pdev, REG_PM_CTRLSTAT, 0); |
1330 | } | 1330 | } |
1331 | 1331 | ||
1332 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
1333 | static void atl2_poll_controller(struct net_device *netdev) | ||
1334 | { | ||
1335 | disable_irq(netdev->irq); | ||
1336 | atl2_intr(netdev->irq, netdev); | ||
1337 | enable_irq(netdev->irq); | ||
1338 | } | ||
1339 | #endif | ||
1340 | |||
1332 | /* | 1341 | /* |
1333 | * atl2_probe - Device Initialization Routine | 1342 | * atl2_probe - Device Initialization Routine |
1334 | * @pdev: PCI device information struct | 1343 | * @pdev: PCI device information struct |
@@ -1412,6 +1421,9 @@ static int __devinit atl2_probe(struct pci_dev *pdev, | |||
1412 | netdev->do_ioctl = &atl2_ioctl; | 1421 | netdev->do_ioctl = &atl2_ioctl; |
1413 | atl2_set_ethtool_ops(netdev); | 1422 | atl2_set_ethtool_ops(netdev); |
1414 | 1423 | ||
1424 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
1425 | netdev->poll_controller = atl2_poll_controller; | ||
1426 | #endif | ||
1415 | #ifdef HAVE_TX_TIMEOUT | 1427 | #ifdef HAVE_TX_TIMEOUT |
1416 | netdev->tx_timeout = &atl2_tx_timeout; | 1428 | netdev->tx_timeout = &atl2_tx_timeout; |
1417 | netdev->watchdog_timeo = 5 * HZ; | 1429 | netdev->watchdog_timeo = 5 * HZ; |