Skip to contentSkip to conversation

Remove 3 compiler warnings from rio_linux.c

PATCH New Bob Miller 1 participant 1 message Jun 20, 2003 Char and misc drivers

lore
Share & tools
lore

Bob Miller

author
#0 lore raw

PATCH 1/1 Remove 3 compiler warnings from rio_linux.c

Add a return value to a return statement in the ISR and remove/rename several labels.

--
Bob Miller Email: [email protected]
Open Source Development Lab Phone: 503.626.2455 Ext. 17

drivers/char/rio/rio_linux.c +4 -6
diff -Nru a/drivers/char/rio/rio_linux.c b/drivers/char/rio/rio_linux.c
@@ -465,7 +465,7 @@
     rio_reset_interrupt (HostP);
   }
 
-  if ((HostP->Flags & RUN_STATE) != RC_RUNNING) return;
+  if ((HostP->Flags & RUN_STATE) != RC_RUNNING) return IRQ_NONE;
 
   if (test_and_set_bit (RIO_BOARD_INTR_LOCK, &HostP->locks)) {
     printk (KERN_ERR "Recursive interrupt! (host %d/irq%d)\n", 
@@ -980,7 +980,7 @@
   for (i = 0; i < RIO_PORTS; i++) {
     port = p->RIOPortp[i] = ckmalloc (sizeof (struct Port));
     if (!port) {
-      goto free6;
+      goto free3;
     }
     rio_dprintk (RIO_DEBUG_INIT, "initing port %d (%d)\n", i, port->Mapped);
     port->PortNum = i;
@@ -1009,11 +1009,9 @@
   func_exit();
   return 0;
 
- free6:for (i--;i>=0;i--)
+ free3:for (i--;i>=0;i--)
         kfree (p->RIOPortp[i]);
-/*free5: */
- free4:
- free3:kfree (p->RIOPortp);
+  kfree (p->RIOPortp);
  free2:kfree (p->RIOHosts);
  free1:
   rio_dprintk (RIO_DEBUG_INIT, "Not enough memory! %p %p %p\n",