Commit 9f88af22 authored by David S. Miller's avatar David S. Miller
Browse files

Merge branch 'switch-drivers-to-netif_napi_add_weight'



Jakub Kicinski says:

====================
net: switch drivers to netif_napi_add_weight()

The minority of drivers pass a custom weight to netif_napi_add().
Switch those away to the new netif_napi_add_weight(). All drivers
(which can go thru net-next) calling netif_napi_add() will now
be calling it with NAPI_POLL_WEIGHT or 64.
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 8fc0b699 6f83cb8c
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1255,7 +1255,8 @@ static int vector_net_open(struct net_device *dev)
			goto out_close;
	}

	netif_napi_add(vp->dev, &vp->napi, vector_poll, get_depth(vp->parsed));
	netif_napi_add_weight(vp->dev, &vp->napi, vector_poll,
			      get_depth(vp->parsed));
	napi_enable(&vp->napi);

	/* READ IRQ */
+2 −1
Original line number Diff line number Diff line
@@ -714,7 +714,8 @@ static int cfv_probe(struct virtio_device *vdev)
	/* Initialize NAPI poll context data */
	vringh_kiov_init(&cfv->ctx.riov, NULL, 0);
	cfv->ctx.head = USHRT_MAX;
	netif_napi_add(netdev, &cfv->napi, cfv_rx_poll, CFV_DEFAULT_QUOTA);
	netif_napi_add_weight(netdev, &cfv->napi, cfv_rx_poll,
			      CFV_DEFAULT_QUOTA);

	tasklet_setup(&cfv->tx_release_tasklet, cfv_tx_release_tasklet);

+1 −1
Original line number Diff line number Diff line
@@ -2464,7 +2464,7 @@ typhoon_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)

	/* The chip-specific entries in the device structure. */
	dev->netdev_ops		= &typhoon_netdev_ops;
	netif_napi_add(dev, &tp->napi, typhoon_poll, 16);
	netif_napi_add_weight(dev, &tp->napi, typhoon_poll, 16);
	dev->watchdog_timeo	= TX_TIMEOUT;

	dev->ethtool_ops = &typhoon_ethtool_ops;
+1 −1
Original line number Diff line number Diff line
@@ -772,7 +772,7 @@ static int starfire_init_one(struct pci_dev *pdev,
	dev->watchdog_timeo = TX_TIMEOUT;
	dev->ethtool_ops = &ethtool_ops;

	netif_napi_add(dev, &np->napi, netdev_poll, max_interrupt_work);
	netif_napi_add_weight(dev, &np->napi, netdev_poll, max_interrupt_work);

	if (mtu)
		dev->mtu = mtu;
+1 −1
Original line number Diff line number Diff line
@@ -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;
Loading