summaryrefslogtreecommitdiff
path: root/drivers/net/qlcnic/qlcnic_hw.c
diff options
context:
space:
mode:
authorAmit Kumar Salecha <amit.salecha@qlogic.com>2010-04-01 23:01:33 +0400
committerDavid S. Miller <davem@davemloft.net>2010-04-04 01:19:15 +0400
commit65b5b420b5974d86ee030b0a15cd9e6f228071f4 (patch)
tree5ddf10e7f5a3ed54dd6fc75f90c41c4694ff6061 /drivers/net/qlcnic/qlcnic_hw.c
parentaa5e18c04af8706251768e6aba83465e31de7810 (diff)
downloadlinux-65b5b420b5974d86ee030b0a15cd9e6f228071f4.tar.xz
qlcnic: add driver debug support
Add debug print in driver, can be tuned by ethtool msg level callback. Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/qlcnic/qlcnic_hw.c')
-rw-r--r--drivers/net/qlcnic/qlcnic_hw.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/net/qlcnic/qlcnic_hw.c b/drivers/net/qlcnic/qlcnic_hw.c
index 0933c2da39eb..14c999ab4222 100644
--- a/drivers/net/qlcnic/qlcnic_hw.c
+++ b/drivers/net/qlcnic/qlcnic_hw.c
@@ -294,8 +294,12 @@ qlcnic_pcie_sem_lock(struct qlcnic_adapter *adapter, int sem, u32 id_reg)
done = QLCRD32(adapter, QLCNIC_PCIE_REG(PCIE_SEM_LOCK(sem)));
if (done == 1)
break;
- if (++timeout >= QLCNIC_PCIE_SEM_TIMEOUT)
+ if (++timeout >= QLCNIC_PCIE_SEM_TIMEOUT) {
+ dev_err(&adapter->pdev->dev,
+ "Failed to acquire sem=%d lock;reg_id=%d\n",
+ sem, id_reg);
return -EIO;
+ }
msleep(1);
}