diff options
author | Amit Kumar Salecha <amit.salecha@qlogic.com> | 2010-02-01 00:25:00 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-02 18:55:46 -0500 |
commit | cdaff1854f32ac9ddb4733530f617d32188665ed (patch) | |
tree | 5d1e7b5bcf656d0071840431f1f3cbc94b828e21 /drivers/net/qlcnic/qlcnic.h | |
parent | 7eb9855d68faabe0004ed18c2af1f0974d3c2c63 (diff) |
qlcnic: add loopback diagnostic test
Loopback test (offline) added in ethtool self test.
o Set device in loopback mode
o Send packets
o Process receive packets in qlcnic_process_rcv_ring_diag()
o Compare packets
o Reset device in normal mode.
Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/qlcnic/qlcnic.h')
-rw-r--r-- | drivers/net/qlcnic/qlcnic.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/qlcnic/qlcnic.h b/drivers/net/qlcnic/qlcnic.h index a5a67e9b5e10..b40a851ec7d1 100644 --- a/drivers/net/qlcnic/qlcnic.h +++ b/drivers/net/qlcnic/qlcnic.h | |||
@@ -897,6 +897,7 @@ struct qlcnic_mac_req { | |||
897 | #define __QLCNIC_START_FW 4 | 897 | #define __QLCNIC_START_FW 4 |
898 | 898 | ||
899 | #define QLCNIC_INTERRUPT_TEST 1 | 899 | #define QLCNIC_INTERRUPT_TEST 1 |
900 | #define QLCNIC_LOOPBACK_TEST 2 | ||
900 | 901 | ||
901 | struct qlcnic_adapter { | 902 | struct qlcnic_adapter { |
902 | struct qlcnic_hardware_context ahw; | 903 | struct qlcnic_hardware_context ahw; |
@@ -1066,6 +1067,8 @@ int qlcnic_send_lro_cleanup(struct qlcnic_adapter *adapter); | |||
1066 | void qlcnic_update_cmd_producer(struct qlcnic_adapter *adapter, | 1067 | void qlcnic_update_cmd_producer(struct qlcnic_adapter *adapter, |
1067 | struct qlcnic_host_tx_ring *tx_ring); | 1068 | struct qlcnic_host_tx_ring *tx_ring); |
1068 | int qlcnic_get_mac_addr(struct qlcnic_adapter *adapter, u64 *mac); | 1069 | int qlcnic_get_mac_addr(struct qlcnic_adapter *adapter, u64 *mac); |
1070 | void qlcnic_clear_ilb_mode(struct qlcnic_adapter *adapter); | ||
1071 | int qlcnic_set_ilb_mode(struct qlcnic_adapter *adapter); | ||
1069 | 1072 | ||
1070 | /* Functions from qlcnic_main.c */ | 1073 | /* Functions from qlcnic_main.c */ |
1071 | int qlcnic_reset_context(struct qlcnic_adapter *); | 1074 | int qlcnic_reset_context(struct qlcnic_adapter *); |
@@ -1073,6 +1076,9 @@ u32 qlcnic_issue_cmd(struct qlcnic_adapter *adapter, | |||
1073 | u32 pci_fn, u32 version, u32 arg1, u32 arg2, u32 arg3, u32 cmd); | 1076 | u32 pci_fn, u32 version, u32 arg1, u32 arg2, u32 arg3, u32 cmd); |
1074 | void qlcnic_diag_free_res(struct net_device *netdev, int max_sds_rings); | 1077 | void qlcnic_diag_free_res(struct net_device *netdev, int max_sds_rings); |
1075 | int qlcnic_diag_alloc_res(struct net_device *netdev, int test); | 1078 | int qlcnic_diag_alloc_res(struct net_device *netdev, int test); |
1079 | int qlcnic_check_loopback_buff(unsigned char *data); | ||
1080 | netdev_tx_t qlcnic_xmit_frame(struct sk_buff *skb, struct net_device *netdev); | ||
1081 | void qlcnic_process_rcv_ring_diag(struct qlcnic_host_sds_ring *sds_ring); | ||
1076 | 1082 | ||
1077 | /* | 1083 | /* |
1078 | * QLOGIC Board information | 1084 | * QLOGIC Board information |