diff options
author | Ben Hutchings <bhutchings@solarflare.com> | 2010-08-17 05:31:15 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-08-17 05:31:15 -0400 |
commit | 01414802054c382072b6cb9a1bdc6e243c74b2d5 (patch) | |
tree | f09b05eb9fff16a69d83ec28653992d1bae8d74c /drivers/net/fec_mpc52xx.c | |
parent | bb8a10bbd10a45db0eb45bac520489bdbc0917ef (diff) |
ethtool: Provide a default implementation of ethtool_ops::get_drvinfo
The driver name and bus address for a net_device can normally be found
through the driver model now. Instead of requiring drivers to provide
this information redundantly through the ethtool_ops::get_drvinfo
operation, use the driver model to do so if the driver does not define
the operation. Since ETHTOOL_GDRVINFO no longer requires the driver
to implement any operations, do not require net_device::ethtool_ops to
be set either.
Remove implementations of get_drvinfo and ethtool_ops that provide
only this information.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/fec_mpc52xx.c')
-rw-r--r-- | drivers/net/fec_mpc52xx.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c index e3e10b4add9c..e9f5d030bc26 100644 --- a/drivers/net/fec_mpc52xx.c +++ b/drivers/net/fec_mpc52xx.c | |||
@@ -771,11 +771,6 @@ static void mpc52xx_fec_reset(struct net_device *dev) | |||
771 | 771 | ||
772 | 772 | ||
773 | /* ethtool interface */ | 773 | /* ethtool interface */ |
774 | static void mpc52xx_fec_get_drvinfo(struct net_device *dev, | ||
775 | struct ethtool_drvinfo *info) | ||
776 | { | ||
777 | strcpy(info->driver, DRIVER_NAME); | ||
778 | } | ||
779 | 774 | ||
780 | static int mpc52xx_fec_get_settings(struct net_device *dev, struct ethtool_cmd *cmd) | 775 | static int mpc52xx_fec_get_settings(struct net_device *dev, struct ethtool_cmd *cmd) |
781 | { | 776 | { |
@@ -810,7 +805,6 @@ static void mpc52xx_fec_set_msglevel(struct net_device *dev, u32 level) | |||
810 | } | 805 | } |
811 | 806 | ||
812 | static const struct ethtool_ops mpc52xx_fec_ethtool_ops = { | 807 | static const struct ethtool_ops mpc52xx_fec_ethtool_ops = { |
813 | .get_drvinfo = mpc52xx_fec_get_drvinfo, | ||
814 | .get_settings = mpc52xx_fec_get_settings, | 808 | .get_settings = mpc52xx_fec_get_settings, |
815 | .set_settings = mpc52xx_fec_set_settings, | 809 | .set_settings = mpc52xx_fec_set_settings, |
816 | .get_link = ethtool_op_get_link, | 810 | .get_link = ethtool_op_get_link, |