diff options
author | Sony Chacko <sony.chacko@qlogic.com> | 2012-12-04 03:33:52 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-12-04 13:00:11 -0500 |
commit | 97ee45eb099a9a0f1dc992f98e9476cc159ee5e0 (patch) | |
tree | 3200eaef5b96e027f18610f487904ed475956e14 /drivers/net/ethernet/qlogic/qlcnic/qlcnic.h | |
parent | fb4ce8ad8036e6b3d5ab021fd10934b80270cc11 (diff) | |
download | lwn-97ee45eb099a9a0f1dc992f98e9476cc159ee5e0.tar.gz lwn-97ee45eb099a9a0f1dc992f98e9476cc159ee5e0.zip |
qlcnic: add 82xx adapter specific checks
Add 82xx adapter ID check before 82xx specific operations as part of
refactoring the driver to enable support for new adapter.
Signed-off-by: Sony Chacko <sony.chacko@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qlogic/qlcnic/qlcnic.h')
-rw-r--r-- | drivers/net/ethernet/qlogic/qlcnic/qlcnic.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic.h b/drivers/net/ethernet/qlogic/qlcnic/qlcnic.h index 082eecbf4148..ebc5b069dddd 100644 --- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic.h +++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic.h @@ -1515,4 +1515,11 @@ struct qlcnic_nic_template { __func__, ##_args); \ } while (0) +#define PCI_DEVICE_ID_QLOGIC_QLE824X 0x8020 +static inline bool qlcnic_82xx_check(struct qlcnic_adapter *adapter) +{ + unsigned short device = adapter->pdev->device; + return (device == PCI_DEVICE_ID_QLOGIC_QLE824X) ? true : false; +} + #endif /* __QLCNIC_H_ */ |