diff options
author | Igor Russkikh <igor.russkikh@aquantia.com> | 2017-12-14 12:34:40 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-12-15 12:46:41 -0500 |
commit | e4d02ca04c6d48ab2226342a1c4ed54f1dbb72bd (patch) | |
tree | e1826f783bd1acb066d566c3e8d091d071ddab90 /drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c | |
parent | sock: free skb in skb_complete_tx_timestamp on error (diff) | |
download | linux-dev-e4d02ca04c6d48ab2226342a1c4ed54f1dbb72bd.tar.xz linux-dev-e4d02ca04c6d48ab2226342a1c4ed54f1dbb72bd.zip |
net: aquantia: Fix actual speed capabilities reporting
Different hardware device Ids correspond to different maximum speed
available. Extra checks were added for devices D108 and D109 to
remove unsupported speeds from these device capabilities list.
Signed-off-by: Igor Russkikh <igor.russkikh@aquantia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c')
-rw-r--r-- | drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c b/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c index cadaa646c89f..58c29d04b186 100644 --- a/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c +++ b/drivers/net/ethernet/aquantia/atlantic/aq_pci_func.c @@ -51,7 +51,8 @@ struct aq_pci_func_s *aq_pci_func_alloc(struct aq_hw_ops *aq_hw_ops, pci_set_drvdata(pdev, self); self->pdev = pdev; - err = aq_hw_ops->get_hw_caps(NULL, &self->aq_hw_caps); + err = aq_hw_ops->get_hw_caps(NULL, &self->aq_hw_caps, pdev->device, + pdev->subsystem_device); if (err < 0) goto err_exit; @@ -59,7 +60,7 @@ struct aq_pci_func_s *aq_pci_func_alloc(struct aq_hw_ops *aq_hw_ops, for (port = 0; port < self->ports; ++port) { struct aq_nic_s *aq_nic = aq_nic_alloc_cold(ndev_ops, eth_ops, - &pdev->dev, self, + pdev, self, port, aq_hw_ops); if (!aq_nic) { |