summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandre Bounine <alexandre.bounine@idt.com>2012-08-21 16:16:12 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-09-14 10:00:20 -0700
commit3ad3bc52af22aa08b703c57f494e6d7f9beabe7b (patch)
treee4c59b4b91f061a289dc08741ba97a2aebb67523
parent8d30b9939e38e55035bad49f964ff6a3f671179e (diff)
downloadlwn-3ad3bc52af22aa08b703c57f494e6d7f9beabe7b.tar.gz
lwn-3ad3bc52af22aa08b703c57f494e6d7f9beabe7b.zip
rapidio/tsi721: fix unused variable compiler warning
commit 9a9a9a7adafe62a34de8b4fb48936c1c5f9bafa5 upstream. Fix unused variable compiler warning when built with CONFIG_RAPIDIO_DEBUG option off. This patch is applicable to kernel versions starting from v3.2 Signed-off-by: Alexandre Bounine <alexandre.bounine@idt.com> Cc: Matt Porter <mporter@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/rapidio/devices/tsi721.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/rapidio/devices/tsi721.c b/drivers/rapidio/devices/tsi721.c
index 91e0f316b611..33471e11a738 100644
--- a/drivers/rapidio/devices/tsi721.c
+++ b/drivers/rapidio/devices/tsi721.c
@@ -2162,7 +2162,7 @@ static int __devinit tsi721_probe(struct pci_dev *pdev,
const struct pci_device_id *id)
{
struct tsi721_device *priv;
- int i, cap;
+ int cap;
int err;
u32 regval;
@@ -2182,12 +2182,15 @@ static int __devinit tsi721_probe(struct pci_dev *pdev,
priv->pdev = pdev;
#ifdef DEBUG
+ {
+ int i;
for (i = 0; i <= PCI_STD_RESOURCE_END; i++) {
dev_dbg(&pdev->dev, "res[%d] @ 0x%llx (0x%lx, 0x%lx)\n",
i, (unsigned long long)pci_resource_start(pdev, i),
(unsigned long)pci_resource_len(pdev, i),
pci_resource_flags(pdev, i));
}
+ }
#endif
/*
* Verify BAR configuration