Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 183717
b: refs/heads/master
c: 4276e47
h: refs/heads/master
i:
  183715: 7c81e5b
v: v3
  • Loading branch information
Sarveshwar Bandi authored and David S. Miller committed Jan 22, 2010
1 parent a9be760 commit 351e987
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8f47afe080df450eedda7b29873512c2a9a9adcb
refs/heads/master: 4276e47e2d1c85a2477caf0d22b91c4f2377fba8
11 changes: 11 additions & 0 deletions trunk/drivers/net/benet/be_ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ static const char et_self_tests[][ETH_GSTRING_LEN] = {
"PHY Loopback test",
"External Loopback test",
"DDR DMA test"
"Link test"
};

#define ETHTOOL_TESTS_NUM ARRAY_SIZE(et_self_tests)
Expand Down Expand Up @@ -529,6 +530,9 @@ static void
be_self_test(struct net_device *netdev, struct ethtool_test *test, u64 *data)
{
struct be_adapter *adapter = netdev_priv(netdev);
bool link_up;
u8 mac_speed = 0;
u16 qos_link_speed = 0;

memset(data, 0, sizeof(u64) * ETHTOOL_TESTS_NUM);

Expand All @@ -552,6 +556,13 @@ be_self_test(struct net_device *netdev, struct ethtool_test *test, u64 *data)
test->flags |= ETH_TEST_FL_FAILED;
}

if (be_cmd_link_status_query(adapter, &link_up, &mac_speed,
&qos_link_speed) != 0) {
test->flags |= ETH_TEST_FL_FAILED;
data[4] = -1;
} else if (mac_speed) {
data[4] = 1;
}
}

static int
Expand Down

0 comments on commit 351e987

Please sign in to comment.