diff options
author | Ben Dooks <ben-linux@fluff.org> | 2008-02-04 19:02:12 -0500 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2008-02-11 11:06:30 -0500 |
commit | e662ee02cc9f1a61f309eaa44ce3c33dc6ed7b8a (patch) | |
tree | 0598f522745c285d7869d21c84edc8cd7fdb21a1 /drivers | |
parent | 29d52e545f6f077d8c29fa35d1c52d95e4a2185a (diff) |
DM9000: Add ethtool control of msg_enable value
Allow the msg_enable value to be read and written by
the ethtool interface.
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/dm9000.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c index 082372515432..2acab02a6428 100644 --- a/drivers/net/dm9000.c +++ b/drivers/net/dm9000.c | |||
@@ -383,6 +383,20 @@ static void dm9000_get_drvinfo(struct net_device *dev, | |||
383 | strcpy(info->bus_info, to_platform_device(dm->dev)->name); | 383 | strcpy(info->bus_info, to_platform_device(dm->dev)->name); |
384 | } | 384 | } |
385 | 385 | ||
386 | static u32 dm9000_get_msglevel(struct net_device *dev) | ||
387 | { | ||
388 | board_info_t *dm = to_dm9000_board(dev); | ||
389 | |||
390 | return dm->msg_enable; | ||
391 | } | ||
392 | |||
393 | static void dm9000_set_msglevel(struct net_device *dev, u32 value) | ||
394 | { | ||
395 | board_info_t *dm = to_dm9000_board(dev); | ||
396 | |||
397 | dm->msg_enable = value; | ||
398 | } | ||
399 | |||
386 | static int dm9000_get_settings(struct net_device *dev, struct ethtool_cmd *cmd) | 400 | static int dm9000_get_settings(struct net_device *dev, struct ethtool_cmd *cmd) |
387 | { | 401 | { |
388 | board_info_t *dm = to_dm9000_board(dev); | 402 | board_info_t *dm = to_dm9000_board(dev); |
@@ -464,6 +478,8 @@ static const struct ethtool_ops dm9000_ethtool_ops = { | |||
464 | .get_drvinfo = dm9000_get_drvinfo, | 478 | .get_drvinfo = dm9000_get_drvinfo, |
465 | .get_settings = dm9000_get_settings, | 479 | .get_settings = dm9000_get_settings, |
466 | .set_settings = dm9000_set_settings, | 480 | .set_settings = dm9000_set_settings, |
481 | .get_msglevel = dm9000_get_msglevel, | ||
482 | .set_msglevel = dm9000_set_msglevel, | ||
467 | .nway_reset = dm9000_nway_reset, | 483 | .nway_reset = dm9000_nway_reset, |
468 | .get_link = dm9000_get_link, | 484 | .get_link = dm9000_get_link, |
469 | .get_eeprom_len = dm9000_get_eeprom_len, | 485 | .get_eeprom_len = dm9000_get_eeprom_len, |