Re: [PATCH] Add polling support to Sungem

From: Jeff Garzik
Date: Wed Sep 29 2004 - 11:03:38 EST


Colin Leroy wrote:
[sending again, forgot Cc:, sorry]

Hi Benjamin!

This patch adds polling support to Sungem ethernet card. It makes
netconsole usable on iBook G4, for example.
I hope it's fine.

Signed-off-by: Colin Leroy <colin@xxxxxxxxxx>

--- a/drivers/net/sungem.c 2004-09-29 12:22:41.802346664 +0200
+++ b/drivers/net/sungem.c 2004-09-29 12:15:56.000000000 +0200
@@ -2687,6 +2687,23 @@
}
#endif /* not Sparc and not PPC */
+#ifdef CONFIG_NET_POLL_CONTROLLER
+/*
+ * Polling 'interrupt' - used by things like netconsole to send skbs
+ * without having to re-enable interrupts. It's not called while
+ * the interrupt routine is executing.
+ */
+static void gem_netpoll(struct net_device *netdev)
+{
+ struct gem *gp = netdev->priv;
+ if (!gp->pdev)
+ return;
+ disable_irq(gp->pdev->irq);
+ gem_interrupt(gp->pdev->irq, netdev, NULL);
+ enable_irq(gp->pdev->irq);
+}
+#endif

Check BK snapshots, this support is already in sungem.

Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/