Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 288379f0 authored by Ben Hutchings's avatar Ben Hutchings Committed by David S. Miller
Browse files

net: Remove redundant NAPI functions



Following the removal of the unused struct net_device * parameter from
the NAPI functions named *netif_rx_* in commit 908a7a16, they are
exactly equivalent to the corresponding *napi_* functions and are
therefore redundant.

Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
Acked-by: default avatarNeil Horman <nhorman@tuxdriver.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 627af770
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -2541,7 +2541,7 @@ static void nes_nic_napi_ce_handler(struct nes_device *nesdev, struct nes_hw_nic
{
{
	struct nes_vnic *nesvnic = container_of(cq, struct nes_vnic, nic_cq);
	struct nes_vnic *nesvnic = container_of(cq, struct nes_vnic, nic_cq);


	netif_rx_schedule(&nesvnic->napi);
	napi_schedule(&nesvnic->napi);
}
}




+1 −1
Original line number Original line Diff line number Diff line
@@ -111,7 +111,7 @@ static int nes_netdev_poll(struct napi_struct *napi, int budget)
	nes_nic_ce_handler(nesdev, nescq);
	nes_nic_ce_handler(nesdev, nescq);


	if (nescq->cqes_pending == 0) {
	if (nescq->cqes_pending == 0) {
		netif_rx_complete(napi);
		napi_complete(napi);
		/* clear out completed cqes and arm */
		/* clear out completed cqes and arm */
		nes_write32(nesdev->regs+NES_CQE_ALLOC, NES_CQE_ALLOC_NOTIFY_NEXT |
		nes_write32(nesdev->regs+NES_CQE_ALLOC, NES_CQE_ALLOC_NOTIFY_NEXT |
				nescq->cq_number | (nescq->cqe_allocs_pending << 16));
				nescq->cq_number | (nescq->cqe_allocs_pending << 16));
+3 −3
Original line number Original line Diff line number Diff line
@@ -446,11 +446,11 @@ int ipoib_poll(struct napi_struct *napi, int budget)
		if (dev->features & NETIF_F_LRO)
		if (dev->features & NETIF_F_LRO)
			lro_flush_all(&priv->lro.lro_mgr);
			lro_flush_all(&priv->lro.lro_mgr);


		netif_rx_complete(napi);
		napi_complete(napi);
		if (unlikely(ib_req_notify_cq(priv->recv_cq,
		if (unlikely(ib_req_notify_cq(priv->recv_cq,
					      IB_CQ_NEXT_COMP |
					      IB_CQ_NEXT_COMP |
					      IB_CQ_REPORT_MISSED_EVENTS)) &&
					      IB_CQ_REPORT_MISSED_EVENTS)) &&
		    netif_rx_reschedule(napi))
		    napi_reschedule(napi))
			goto poll_more;
			goto poll_more;
	}
	}


@@ -462,7 +462,7 @@ void ipoib_ib_completion(struct ib_cq *cq, void *dev_ptr)
	struct net_device *dev = dev_ptr;
	struct net_device *dev = dev_ptr;
	struct ipoib_dev_priv *priv = netdev_priv(dev);
	struct ipoib_dev_priv *priv = netdev_priv(dev);


	netif_rx_schedule(&priv->napi);
	napi_schedule(&priv->napi);
}
}


static void drain_tx_cq(struct net_device *dev)
static void drain_tx_cq(struct net_device *dev)
+3 −3
Original line number Original line Diff line number Diff line
@@ -604,7 +604,7 @@ static int cp_rx_poll(struct napi_struct *napi, int budget)


		spin_lock_irqsave(&cp->lock, flags);
		spin_lock_irqsave(&cp->lock, flags);
		cpw16_f(IntrMask, cp_intr_mask);
		cpw16_f(IntrMask, cp_intr_mask);
		__netif_rx_complete(napi);
		__napi_complete(napi);
		spin_unlock_irqrestore(&cp->lock, flags);
		spin_unlock_irqrestore(&cp->lock, flags);
	}
	}


@@ -641,9 +641,9 @@ static irqreturn_t cp_interrupt (int irq, void *dev_instance)
	}
	}


	if (status & (RxOK | RxErr | RxEmpty | RxFIFOOvr))
	if (status & (RxOK | RxErr | RxEmpty | RxFIFOOvr))
		if (netif_rx_schedule_prep(&cp->napi)) {
		if (napi_schedule_prep(&cp->napi)) {
			cpw16_f(IntrMask, cp_norx_intr_mask);
			cpw16_f(IntrMask, cp_norx_intr_mask);
			__netif_rx_schedule(&cp->napi);
			__napi_schedule(&cp->napi);
		}
		}


	if (status & (TxOK | TxErr | TxEmpty | SWInt))
	if (status & (TxOK | TxErr | TxEmpty | SWInt))
+3 −3
Original line number Original line Diff line number Diff line
@@ -2128,7 +2128,7 @@ static int rtl8139_poll(struct napi_struct *napi, int budget)
		 */
		 */
		spin_lock_irqsave(&tp->lock, flags);
		spin_lock_irqsave(&tp->lock, flags);
		RTL_W16_F(IntrMask, rtl8139_intr_mask);
		RTL_W16_F(IntrMask, rtl8139_intr_mask);
		__netif_rx_complete(napi);
		__napi_complete(napi);
		spin_unlock_irqrestore(&tp->lock, flags);
		spin_unlock_irqrestore(&tp->lock, flags);
	}
	}
	spin_unlock(&tp->rx_lock);
	spin_unlock(&tp->rx_lock);
@@ -2178,9 +2178,9 @@ static irqreturn_t rtl8139_interrupt (int irq, void *dev_instance)
	/* Receive packets are processed by poll routine.
	/* Receive packets are processed by poll routine.
	   If not running start it now. */
	   If not running start it now. */
	if (status & RxAckBits){
	if (status & RxAckBits){
		if (netif_rx_schedule_prep(&tp->napi)) {
		if (napi_schedule_prep(&tp->napi)) {
			RTL_W16_F (IntrMask, rtl8139_norx_intr_mask);
			RTL_W16_F (IntrMask, rtl8139_norx_intr_mask);
			__netif_rx_schedule(&tp->napi);
			__napi_schedule(&tp->napi);
		}
		}
	}
	}


Loading