Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 133844
b: refs/heads/master
c: 288379f
h: refs/heads/master
v: v3
  • Loading branch information
Ben Hutchings authored and David S. Miller committed Jan 21, 2009
1 parent 3763f57 commit 9faa0f0
Show file tree
Hide file tree
Showing 67 changed files with 228 additions and 278 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 627af770c63acddc2402dd19fec70df5c3ad8ab7
refs/heads/master: 288379f050284087578b77e04f040b57db3db3f8
2 changes: 1 addition & 1 deletion trunk/drivers/infiniband/hw/nes/nes_hw.c
Original file line number Diff line number Diff line change
Expand Up @@ -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);

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


Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/infiniband/hw/nes/nes_nic.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ static int nes_netdev_poll(struct napi_struct *napi, int budget)
nes_nic_ce_handler(nesdev, nescq);

if (nescq->cqes_pending == 0) {
netif_rx_complete(napi);
napi_complete(napi);
/* clear out completed cqes and arm */
nes_write32(nesdev->regs+NES_CQE_ALLOC, NES_CQE_ALLOC_NOTIFY_NEXT |
nescq->cq_number | (nescq->cqe_allocs_pending << 16));
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/infiniband/ulp/ipoib/ipoib_ib.c
Original file line number Diff line number Diff line change
Expand Up @@ -446,11 +446,11 @@ int ipoib_poll(struct napi_struct *napi, int budget)
if (dev->features & NETIF_F_LRO)
lro_flush_all(&priv->lro.lro_mgr);

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

Expand All @@ -462,7 +462,7 @@ void ipoib_ib_completion(struct ib_cq *cq, void *dev_ptr)
struct net_device *dev = dev_ptr;
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)
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/net/8139cp.c
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,7 @@ static int cp_rx_poll(struct napi_struct *napi, int budget)

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

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

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);
__netif_rx_schedule(&cp->napi);
__napi_schedule(&cp->napi);
}

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

Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/net/amd8111e.c
Original file line number Diff line number Diff line change
Expand Up @@ -831,7 +831,7 @@ static int amd8111e_rx_poll(struct napi_struct *napi, int budget)
if (rx_pkt_limit > 0) {
/* Receive descriptor is empty now */
spin_lock_irqsave(&lp->lock, flags);
__netif_rx_complete(napi);
__napi_complete(napi);
writel(VAL0|RINTEN0, mmio + INTEN0);
writel(VAL2 | RDMD0, mmio + CMD0);
spin_unlock_irqrestore(&lp->lock, flags);
Expand Down Expand Up @@ -1170,11 +1170,11 @@ static irqreturn_t amd8111e_interrupt(int irq, void *dev_id)

/* Check if Receive Interrupt has occurred. */
if (intr0 & RINT0) {
if (netif_rx_schedule_prep(&lp->napi)) {
if (napi_schedule_prep(&lp->napi)) {
/* Disable receive interupts */
writel(RINTEN0, mmio + INTEN0);
/* Schedule a polling routine */
__netif_rx_schedule(&lp->napi);
__napi_schedule(&lp->napi);
} else if (intren0 & RINTEN0) {
printk("************Driver bug! \
interrupt while in poll\n");
Expand Down
8 changes: 4 additions & 4 deletions trunk/drivers/net/arm/ep93xx_eth.c
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ static int ep93xx_poll(struct napi_struct *napi, int budget)
int more = 0;

spin_lock_irq(&ep->rx_lock);
__netif_rx_complete(napi);
__napi_complete(napi);
wrl(ep, REG_INTEN, REG_INTEN_TX | REG_INTEN_RX);
if (ep93xx_have_more_rx(ep)) {
wrl(ep, REG_INTEN, REG_INTEN_TX);
Expand All @@ -307,7 +307,7 @@ static int ep93xx_poll(struct napi_struct *napi, int budget)
}
spin_unlock_irq(&ep->rx_lock);

if (more && netif_rx_reschedule(napi))
if (more && napi_reschedule(napi))
goto poll_some_more;
}

Expand Down Expand Up @@ -415,9 +415,9 @@ static irqreturn_t ep93xx_irq(int irq, void *dev_id)

if (status & REG_INTSTS_RX) {
spin_lock(&ep->rx_lock);
if (likely(netif_rx_schedule_prep(&ep->napi))) {
if (likely(napi_schedule_prep(&ep->napi))) {
wrl(ep, REG_INTEN, REG_INTEN_TX);
__netif_rx_schedule(&ep->napi);
__napi_schedule(&ep->napi);
}
spin_unlock(&ep->rx_lock);
}
Expand Down
12 changes: 6 additions & 6 deletions trunk/drivers/net/arm/ixp4xx_eth.c
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ static void eth_rx_irq(void *pdev)
printk(KERN_DEBUG "%s: eth_rx_irq\n", dev->name);
#endif
qmgr_disable_irq(port->plat->rxq);
netif_rx_schedule(&port->napi);
napi_schedule(&port->napi);
}

static int eth_poll(struct napi_struct *napi, int budget)
Expand All @@ -498,16 +498,16 @@ static int eth_poll(struct napi_struct *napi, int budget)

if ((n = queue_get_desc(rxq, port, 0)) < 0) {
#if DEBUG_RX
printk(KERN_DEBUG "%s: eth_poll netif_rx_complete\n",
printk(KERN_DEBUG "%s: eth_poll napi_complete\n",
dev->name);
#endif
netif_rx_complete(napi);
napi_complete(napi);
qmgr_enable_irq(rxq);
if (!qmgr_stat_empty(rxq) &&
netif_rx_reschedule(napi)) {
napi_reschedule(napi)) {
#if DEBUG_RX
printk(KERN_DEBUG "%s: eth_poll"
" netif_rx_reschedule successed\n",
" napi_reschedule successed\n",
dev->name);
#endif
qmgr_disable_irq(rxq);
Expand Down Expand Up @@ -1036,7 +1036,7 @@ static int eth_open(struct net_device *dev)
}
ports_open++;
/* we may already have RX data, enables IRQ */
netif_rx_schedule(&port->napi);
napi_schedule(&port->napi);
return 0;
}

Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/net/atl1e/atl1e_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1326,9 +1326,9 @@ static irqreturn_t atl1e_intr(int irq, void *data)
AT_WRITE_REG(hw, REG_IMR,
IMR_NORMAL_MASK & ~ISR_RX_EVENT);
AT_WRITE_FLUSH(hw);
if (likely(netif_rx_schedule_prep(
if (likely(napi_schedule_prep(
&adapter->napi)))
__netif_rx_schedule(&adapter->napi);
__napi_schedule(&adapter->napi);
}
} while (--max_ints > 0);
/* re-enable Interrupt*/
Expand Down Expand Up @@ -1514,7 +1514,7 @@ static int atl1e_clean(struct napi_struct *napi, int budget)
/* If no Tx and not enough Rx work done, exit the polling mode */
if (work_done < budget) {
quit_polling:
netif_rx_complete(napi);
napi_complete(napi);
imr_data = AT_READ_REG(&adapter->hw, REG_IMR);
AT_WRITE_REG(&adapter->hw, REG_IMR, imr_data | ISR_RX_EVENT);
/* test debug */
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/net/b44.c
Original file line number Diff line number Diff line change
Expand Up @@ -874,7 +874,7 @@ static int b44_poll(struct napi_struct *napi, int budget)
}

if (work_done < budget) {
netif_rx_complete(napi);
napi_complete(napi);
b44_enable_ints(bp);
}

Expand Down Expand Up @@ -906,13 +906,13 @@ static irqreturn_t b44_interrupt(int irq, void *dev_id)
goto irq_ack;
}

if (netif_rx_schedule_prep(&bp->napi)) {
if (napi_schedule_prep(&bp->napi)) {
/* NOTE: These writes are posted by the readback of
* the ISTAT register below.
*/
bp->istat = istat;
__b44_disable_ints(bp);
__netif_rx_schedule(&bp->napi);
__napi_schedule(&bp->napi);
} else {
printk(KERN_ERR PFX "%s: Error, poll already scheduled\n",
dev->name);
Expand Down
12 changes: 6 additions & 6 deletions trunk/drivers/net/bnx2.c
Original file line number Diff line number Diff line change
Expand Up @@ -3053,7 +3053,7 @@ bnx2_msi(int irq, void *dev_instance)
if (unlikely(atomic_read(&bp->intr_sem) != 0))
return IRQ_HANDLED;

netif_rx_schedule(&bnapi->napi);
napi_schedule(&bnapi->napi);

return IRQ_HANDLED;
}
Expand All @@ -3070,7 +3070,7 @@ bnx2_msi_1shot(int irq, void *dev_instance)
if (unlikely(atomic_read(&bp->intr_sem) != 0))
return IRQ_HANDLED;

netif_rx_schedule(&bnapi->napi);
napi_schedule(&bnapi->napi);

return IRQ_HANDLED;
}
Expand Down Expand Up @@ -3106,9 +3106,9 @@ bnx2_interrupt(int irq, void *dev_instance)
if (unlikely(atomic_read(&bp->intr_sem) != 0))
return IRQ_HANDLED;

if (netif_rx_schedule_prep(&bnapi->napi)) {
if (napi_schedule_prep(&bnapi->napi)) {
bnapi->last_status_idx = sblk->status_idx;
__netif_rx_schedule(&bnapi->napi);
__napi_schedule(&bnapi->napi);
}

return IRQ_HANDLED;
Expand Down Expand Up @@ -3218,7 +3218,7 @@ static int bnx2_poll_msix(struct napi_struct *napi, int budget)
rmb();
if (likely(!bnx2_has_fast_work(bnapi))) {

netif_rx_complete(napi);
napi_complete(napi);
REG_WR(bp, BNX2_PCICFG_INT_ACK_CMD, bnapi->int_num |
BNX2_PCICFG_INT_ACK_CMD_INDEX_VALID |
bnapi->last_status_idx);
Expand Down Expand Up @@ -3251,7 +3251,7 @@ static int bnx2_poll(struct napi_struct *napi, int budget)

rmb();
if (likely(!bnx2_has_work(bnapi))) {
netif_rx_complete(napi);
napi_complete(napi);
if (likely(bp->flags & BNX2_FLAG_USING_MSI_OR_MSIX)) {
REG_WR(bp, BNX2_PCICFG_INT_ACK_CMD,
BNX2_PCICFG_INT_ACK_CMD_INDEX_VALID |
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/net/bnx2x_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1647,7 +1647,7 @@ static irqreturn_t bnx2x_msix_fp_int(int irq, void *fp_cookie)
prefetch(&fp->status_blk->c_status_block.status_block_index);
prefetch(&fp->status_blk->u_status_block.status_block_index);

netif_rx_schedule(&bnx2x_fp(bp, index, napi));
napi_schedule(&bnx2x_fp(bp, index, napi));

return IRQ_HANDLED;
}
Expand Down Expand Up @@ -1686,7 +1686,7 @@ static irqreturn_t bnx2x_interrupt(int irq, void *dev_instance)
prefetch(&fp->status_blk->c_status_block.status_block_index);
prefetch(&fp->status_blk->u_status_block.status_block_index);

netif_rx_schedule(&bnx2x_fp(bp, 0, napi));
napi_schedule(&bnx2x_fp(bp, 0, napi));

status &= ~mask;
}
Expand Down Expand Up @@ -9339,7 +9339,7 @@ static int bnx2x_poll(struct napi_struct *napi, int budget)
#ifdef BNX2X_STOP_ON_ERROR
poll_panic:
#endif
netif_rx_complete(napi);
napi_complete(napi);

bnx2x_ack_sb(bp, FP_SB_ID(fp), USTORM_ID,
le16_to_cpu(fp->fp_u_idx), IGU_INT_NOP, 1);
Expand Down
8 changes: 4 additions & 4 deletions trunk/drivers/net/cassini.c
Original file line number Diff line number Diff line change
Expand Up @@ -2506,7 +2506,7 @@ static irqreturn_t cas_interruptN(int irq, void *dev_id)
if (status & INTR_RX_DONE_ALT) { /* handle rx separately */
#ifdef USE_NAPI
cas_mask_intr(cp);
netif_rx_schedule(&cp->napi);
napi_schedule(&cp->napi);
#else
cas_rx_ringN(cp, ring, 0);
#endif
Expand Down Expand Up @@ -2557,7 +2557,7 @@ static irqreturn_t cas_interrupt1(int irq, void *dev_id)
if (status & INTR_RX_DONE_ALT) { /* handle rx separately */
#ifdef USE_NAPI
cas_mask_intr(cp);
netif_rx_schedule(&cp->napi);
napi_schedule(&cp->napi);
#else
cas_rx_ringN(cp, 1, 0);
#endif
Expand Down Expand Up @@ -2613,7 +2613,7 @@ static irqreturn_t cas_interrupt(int irq, void *dev_id)
if (status & INTR_RX_DONE) {
#ifdef USE_NAPI
cas_mask_intr(cp);
netif_rx_schedule(&cp->napi);
napi_schedule(&cp->napi);
#else
cas_rx_ringN(cp, 0, 0);
#endif
Expand Down Expand Up @@ -2691,7 +2691,7 @@ static int cas_poll(struct napi_struct *napi, int budget)
#endif
spin_unlock_irqrestore(&cp->lock, flags);
if (enable_intr) {
netif_rx_complete(napi);
napi_complete(napi);
cas_unmask_intr(cp);
}
return credits;
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/net/chelsio/sge.c
Original file line number Diff line number Diff line change
Expand Up @@ -1612,7 +1612,7 @@ int t1_poll(struct napi_struct *napi, int budget)
int work_done = process_responses(adapter, budget);

if (likely(work_done < budget)) {
netif_rx_complete(napi);
napi_complete(napi);
writel(adapter->sge->respQ.cidx,
adapter->regs + A_SG_SLEEPING);
}
Expand All @@ -1630,7 +1630,7 @@ irqreturn_t t1_interrupt(int irq, void *data)

if (napi_schedule_prep(&adapter->napi)) {
if (process_pure_responses(adapter))
__netif_rx_schedule(&adapter->napi);
__napi_schedule(&adapter->napi);
else {
/* no data, no NAPI needed */
writel(sge->respQ.cidx, adapter->regs + A_SG_SLEEPING);
Expand Down
10 changes: 5 additions & 5 deletions trunk/drivers/net/cpmac.c
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@ static int cpmac_poll(struct napi_struct *napi, int budget)
printk(KERN_WARNING "%s: rx: polling, but no queue\n",
priv->dev->name);
spin_unlock(&priv->rx_lock);
netif_rx_complete(napi);
napi_complete(napi);
return 0;
}

Expand Down Expand Up @@ -514,7 +514,7 @@ static int cpmac_poll(struct napi_struct *napi, int budget)
if (processed == 0) {
/* we ran out of packets to read,
* revert to interrupt-driven mode */
netif_rx_complete(napi);
napi_complete(napi);
cpmac_write(priv->regs, CPMAC_RX_INT_ENABLE, 1);
return 0;
}
Expand All @@ -536,7 +536,7 @@ static int cpmac_poll(struct napi_struct *napi, int budget)
}

spin_unlock(&priv->rx_lock);
netif_rx_complete(napi);
napi_complete(napi);
netif_tx_stop_all_queues(priv->dev);
napi_disable(&priv->napi);

Expand Down Expand Up @@ -802,9 +802,9 @@ static irqreturn_t cpmac_irq(int irq, void *dev_id)

if (status & MAC_INT_RX) {
queue = (status >> 8) & 7;
if (netif_rx_schedule_prep(&priv->napi)) {
if (napi_schedule_prep(&priv->napi)) {
cpmac_write(priv->regs, CPMAC_RX_INT_CLEAR, 1 << queue);
__netif_rx_schedule(&priv->napi);
__napi_schedule(&priv->napi);
}
}

Expand Down
Loading

0 comments on commit 9faa0f0

Please sign in to comment.