[PATCH 2/7] staging: comedi: jr3_pci: rename card variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The local variable `card` in `jr3_pci_auto_attach()` is used to point to
the PCI device `struct pci_dev`.  Rename it to `pcidev`.

Signed-off-by: Ian Abbott <abbotti@xxxxxxxxx>
---
 drivers/staging/comedi/drivers/jr3_pci.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/comedi/drivers/jr3_pci.c b/drivers/staging/comedi/drivers/jr3_pci.c
index 235ec8d..fe48d88 100644
--- a/drivers/staging/comedi/drivers/jr3_pci.c
+++ b/drivers/staging/comedi/drivers/jr3_pci.c
@@ -748,7 +748,7 @@ static int __devinit jr3_pci_auto_attach(struct comedi_device *dev,
 					 unsigned long context_unused)
 {
 	int result;
-	struct pci_dev *card = comedi_to_pci_dev(dev);
+	struct pci_dev *pcidev = comedi_to_pci_dev(dev);
 	int i;
 	struct jr3_pci_dev_private *devpriv;
 
@@ -765,7 +765,7 @@ static int __devinit jr3_pci_auto_attach(struct comedi_device *dev,
 	dev->private = devpriv;
 
 	init_timer(&devpriv->timer);
-	switch (card->device) {
+	switch (pcidev->device) {
 	case PCI_DEVICE_ID_JR3_1_CHANNEL:
 	case PCI_DEVICE_ID_JR3_1_CHANNEL_NEW:
 		devpriv->n_channels = 1;
@@ -781,19 +781,19 @@ static int __devinit jr3_pci_auto_attach(struct comedi_device *dev,
 		break;
 	default:
 		dev_err(dev->class_dev, "jr3_pci: pci %s not supported\n",
-			pci_name(card));
+			pci_name(pcidev));
 		return -EINVAL;
 		break;
 	}
-	devpriv->pci_dev = card;
+	devpriv->pci_dev = pcidev;
 	dev->board_name = "jr3_pci";
 
-	result = comedi_pci_enable(card, "jr3_pci");
+	result = comedi_pci_enable(pcidev, "jr3_pci");
 	if (result < 0)
 		return -EIO;
 
 	devpriv->pci_enabled = 1;
-	devpriv->iobase = ioremap(pci_resource_start(card, 0),
+	devpriv->iobase = ioremap(pci_resource_start(pcidev, 0),
 			offsetof(struct jr3_t, channel[devpriv->n_channels]));
 	if (!devpriv->iobase)
 		return -ENOMEM;
-- 
1.7.12.4

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux