Add ethtool -i interface to Prism54
Subsystems (3)
PATCH 1/1 Add ethtool -i interface to Prism54
Attached is a small patch that will add support for
ethtool -i
to the prism54 driver.
ethtool -i queries the specified ethernet device for associated driver information.
This helps tools like Fedora's system-config-network to provide GUI management of network devices. I learned how to write this patch by reading the ipw2100 driver code.
Thanks for considering to take it.
Kai
drivers/net/wireless/prism54/islpci_dev.h renamed from drivers/net/wireless/prism54/islpci_dev.h.preke +4 -0
@@ -210,4 +210,8 @@int islpci_free_memory (islpci_private *);struct net_device *islpci_setup (struct pci_dev *); + +#define DRV_NAME "prism54" +#define DRV_VERSION "1.2" +#endif /* _ISLPCI_DEV_H */
drivers/net/wireless/prism54/islpci_dev.c renamed from drivers/net/wireless/prism54/islpci_dev.c.preke +13 -0
@@ -22,6 +22,7 @@#include <linux/module.h> #include <linux/netdevice.h> +#include <linux/ethtool.h> #include <linux/pci.h> #include <linux/etherdevice.h> #include <linux/delay.h>
@@ -788,6 +789,17 @@ }#endif +static void islpci_ethtool_get_drvinfo (struct net_device *dev, +struct ethtool_drvinfo *info) +{ +strcpy (info->driver,DRV_NAME ); +strcpy (info->version,DRV_VERSION ); +} + +static struct ethtool_ops islpci_ethtool_ops = { + .get_drvinfo = islpci_ethtool_get_drvinfo, +}; +struct net_device *islpci_setup (struct pci_dev *pdev) {
@@ -814,6 +826,7 @@ ndev->do_ioctl = &prism54_ioctl; ndev->wireless_handlers = (struct iw_handler_def *) &prism54_handler_def; + ndev->ethtool_ops = &islpci_ethtool_ops; ndev->hard_start_xmit = &islpci_eth_transmit;/* ndev->set_multicast_list = &islpci_set_multicast_list; */
drivers/net/wireless/prism54/islpci_hotplug.c renamed from drivers/net/wireless/prism54/islpci_hotplug.c.preke +0 -3
@@ -28,9 +28,6 @@#include "islpci_mgt.h" /* for pc_debug */ #include "isl_oid.h" -#define DRV_NAME "prism54" -#define DRV_VERSION "1.2" -MODULE_AUTHOR ("[Intersil] R.Bastings and W.Termorshuizen, The prism54.org Development Team <[email protected]>" );MODULE_DESCRIPTION ("The Prism54 802.11 Wireless LAN adapter" );MODULE_LICENSE ("GPL" );
Quoted 10 lines · Kai Engert
Attached is a small patch that will add support for
ethtool -i
to the prism54 driver.ethtool -i queries the specified ethernet device for associated driver information.
This helps tools like Fedora's system-config-network to provide GUI management of network devices. I learned how to write this patch by reading the ipw2100 driver code.
Thanks for considering to take it.
Please include a Signed-off-by line at a minimum, to provide a legal release for your patch. Other details, like including the patch inline rather than as an attachment can found in
http://linux.yyz.us/patch-format.html and Documentation/SubmittingPatches in the kernel tree.
Jeff