diff options
Diffstat (limited to 'drivers/net/cxgb4vf/cxgb4vf_main.c')
-rw-r--r-- | drivers/net/cxgb4vf/cxgb4vf_main.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/drivers/net/cxgb4vf/cxgb4vf_main.c b/drivers/net/cxgb4vf/cxgb4vf_main.c index 4661cbbd9bd..c662679de4f 100644 --- a/drivers/net/cxgb4vf/cxgb4vf_main.c +++ b/drivers/net/cxgb4vf/cxgb4vf_main.c | |||
@@ -1352,11 +1352,20 @@ static int cxgb4vf_set_rx_csum(struct net_device *dev, u32 csum) | |||
1352 | /* | 1352 | /* |
1353 | * Identify the port by blinking the port's LED. | 1353 | * Identify the port by blinking the port's LED. |
1354 | */ | 1354 | */ |
1355 | static int cxgb4vf_phys_id(struct net_device *dev, u32 id) | 1355 | static int cxgb4vf_phys_id(struct net_device *dev, |
1356 | enum ethtool_phys_id_state state) | ||
1356 | { | 1357 | { |
1358 | unsigned int val; | ||
1357 | struct port_info *pi = netdev_priv(dev); | 1359 | struct port_info *pi = netdev_priv(dev); |
1358 | 1360 | ||
1359 | return t4vf_identify_port(pi->adapter, pi->viid, 5); | 1361 | if (state == ETHTOOL_ID_ACTIVE) |
1362 | val = 0xffff; | ||
1363 | else if (state == ETHTOOL_ID_INACTIVE) | ||
1364 | val = 0; | ||
1365 | else | ||
1366 | return -EINVAL; | ||
1367 | |||
1368 | return t4vf_identify_port(pi->adapter, pi->viid, val); | ||
1360 | } | 1369 | } |
1361 | 1370 | ||
1362 | /* | 1371 | /* |
@@ -1588,7 +1597,7 @@ static struct ethtool_ops cxgb4vf_ethtool_ops = { | |||
1588 | .set_sg = ethtool_op_set_sg, | 1597 | .set_sg = ethtool_op_set_sg, |
1589 | .get_link = ethtool_op_get_link, | 1598 | .get_link = ethtool_op_get_link, |
1590 | .get_strings = cxgb4vf_get_strings, | 1599 | .get_strings = cxgb4vf_get_strings, |
1591 | .phys_id = cxgb4vf_phys_id, | 1600 | .set_phys_id = cxgb4vf_phys_id, |
1592 | .get_sset_count = cxgb4vf_get_sset_count, | 1601 | .get_sset_count = cxgb4vf_get_sset_count, |
1593 | .get_ethtool_stats = cxgb4vf_get_ethtool_stats, | 1602 | .get_ethtool_stats = cxgb4vf_get_ethtool_stats, |
1594 | .get_regs_len = cxgb4vf_get_regs_len, | 1603 | .get_regs_len = cxgb4vf_get_regs_len, |