Skip to contentSkip to conversation

remove unused variable in mxser.c

PATCH New Adrian Bunk 1 participant 1 message Jul 1, 2004

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 remove unused variable in mxser.c

I got the following warning in 2.6.7-mm5:

<-- snip -->

...
CC [M] drivers/char/mxser.o
drivers/char/mxser.c: In function `mxser_module_init':
drivers/char/mxser.c:617: warning: unused variable `index'
...

<-- snip -->

Since the variable is in fact unused, the following patch simply removes it:

drivers/char/mxser.c renamed from drivers/char/mxser.c.old +0 -1
@@ -614,7 +614,6 @@
 	{
 		struct pci_dev *pdev = NULL;
 		int n = (sizeof(mxser_pcibrds) / sizeof(mxser_pcibrds[0])) - 1;
-		int index = 0;
 		for (b = 0; b < n; b++) {
 			while ((pdev = pci_find_device(mxser_pcibrds[b].vendor, mxser_pcibrds[b].device, pdev)))
 			{

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed