Skip to content

Commit

Permalink
enic: Bug Fix: Fix timeout for hardware Tx and Rx queue disable opera…
Browse files Browse the repository at this point in the history
…tions

The timeout for hardware Tx and Rx queue disable operations is increased to
work-around an erratum for "unnamed" chipset where a DMA completion may take
upto 10ms. We have to wait atleast this long for hardware to signal that Tx
and Rx queues are quiesced.

Signed-off-by: Scott Feldman <scofeldm@cisco.com>
Signed-off-by: Vasanthy Kolluri <vkolluri@cisco.com>
Signed-off-by: Roopa Prabhu <roprabhu@cisco.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Vasanthy Kolluri authored and David S. Miller committed Mar 19, 2010
1 parent a55a603 commit b6d24eb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions drivers/net/enic/vnic_rq.c
Original file line number Diff line number Diff line change
Expand Up @@ -167,10 +167,10 @@ int vnic_rq_disable(struct vnic_rq *rq)
iowrite32(0, &rq->ctrl->enable);

/* Wait for HW to ACK disable request */
for (wait = 0; wait < 100; wait++) {
for (wait = 0; wait < 1000; wait++) {
if (!(ioread32(&rq->ctrl->running)))
return 0;
udelay(1);
udelay(10);
}

printk(KERN_ERR "Failed to disable RQ[%d]\n", rq->index);
Expand Down
4 changes: 2 additions & 2 deletions drivers/net/enic/vnic_wq.c
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,10 @@ int vnic_wq_disable(struct vnic_wq *wq)
iowrite32(0, &wq->ctrl->enable);

/* Wait for HW to ACK disable request */
for (wait = 0; wait < 100; wait++) {
for (wait = 0; wait < 1000; wait++) {
if (!(ioread32(&wq->ctrl->running)))
return 0;
udelay(1);
udelay(10);
}

printk(KERN_ERR "Failed to disable WQ[%d]\n", wq->index);
Expand Down

0 comments on commit b6d24eb

Please sign in to comment.