diff options
author | Jakub Kicinski <kuba@kernel.org> | 2022-05-06 20:07:48 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-05-08 13:33:57 +0300 |
commit | b707b89f7be36147187ebc52d91c085040c26de9 (patch) | |
tree | 9173d0c07f68348af75029bc5fc3a4ceb2e2151f /drivers/net/ethernet/amd | |
parent | be8af67fabcb94b2f4e0897e5782bccd3104bef3 (diff) | |
download | linux-b707b89f7be36147187ebc52d91c085040c26de9.tar.xz |
eth: switch to netif_napi_add_weight()
Switch all Ethernet drivers which use custom napi weights
to the new API.
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/amd')
-rw-r--r-- | drivers/net/ethernet/amd/amd8111e.c | 2 | ||||
-rw-r--r-- | drivers/net/ethernet/amd/pcnet32.c | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/ethernet/amd/amd8111e.c b/drivers/net/ethernet/amd/amd8111e.c index 9421afb950f7..05ac8d9ccb2f 100644 --- a/drivers/net/ethernet/amd/amd8111e.c +++ b/drivers/net/ethernet/amd/amd8111e.c @@ -1828,7 +1828,7 @@ static int amd8111e_probe_one(struct pci_dev *pdev, dev->watchdog_timeo = AMD8111E_TX_TIMEOUT; dev->min_mtu = AMD8111E_MIN_MTU; dev->max_mtu = AMD8111E_MAX_MTU; - netif_napi_add(dev, &lp->napi, amd8111e_rx_poll, 32); + netif_napi_add_weight(dev, &lp->napi, amd8111e_rx_poll, 32); #if AMD8111E_VLAN_TAG_USED dev->features |= NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_RX; diff --git a/drivers/net/ethernet/amd/pcnet32.c b/drivers/net/ethernet/amd/pcnet32.c index c20c369c7eb8..b5ff47283cfe 100644 --- a/drivers/net/ethernet/amd/pcnet32.c +++ b/drivers/net/ethernet/amd/pcnet32.c @@ -1881,7 +1881,8 @@ pcnet32_probe1(unsigned long ioaddr, int shared, struct pci_dev *pdev) /* napi.weight is used in both the napi and non-napi cases */ lp->napi.weight = lp->rx_ring_size / 2; - netif_napi_add(dev, &lp->napi, pcnet32_poll, lp->rx_ring_size / 2); + netif_napi_add_weight(dev, &lp->napi, pcnet32_poll, + lp->rx_ring_size / 2); if (fdx && !(lp->options & PCNET32_PORT_ASEL) && ((cards_found >= MAX_UNITS) || full_duplex[cards_found])) |