Add netpoll support
PATCH 1/1 Add netpoll support
Add netpoll support to the EMAC driver.
Signed-off-by Matt Porter <[email protected]>
===== drivers/net/ibm_emac/ibm_emac_core.c 1.5 vs edited =====
drivers/net/ibm_emac/ibm_emac_core.c +12 -0
@@ -1700,6 +1700,15 @@ .rxde = &emac_rxde_dev, }; +#ifdef CONFIG_NET_POLL_CONTROLLER +static int emac_netpoll (struct net_device *ndev) +{ +emac_rxeob_dev ((void *)ndev,0 ); +emac_txeob_dev ((void *)ndev,0 ); +return 0 ; +} +#endif +static int emac_init_device (struct ocp_device *ocpdev,struct ibm_ocp_mal *mal) {int deferred_init =0 ;
@@ -1882,6 +1891,9 @@SET_ETHTOOL_OPS (ndev, &emac_ethtool_ops);if (emacdata->tah_idx >=0 ) ndev->features =NETIF_F_IP_CSUM |NETIF_F_SG ; +#ifdef CONFIG_NET_POLL_CONTROLLER + ndev->poll_controller = emac_netpoll; +#endif SET_MODULE_OWNER (ndev);