Skip to contentSkip to conversation

PATCH: Fix careless warning in io_apic for x86-64

PATCH Alan Cox 1 participant 1 message May 10, 2004

lore
Share & tools
lore

Alan Cox

author
#0 lore raw

Fixes the warning

arch/x86_64/kernel/io_apic.c +3 -1
diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.6/arch/x86_64/kernel/io_apic.c linux-2.6.6/arch/x86_64/kernel/io_apic.c
@@ -228,6 +228,8 @@
 void __init check_ioapic(void) 
 { 
 	int num,slot,func; 
+	u8 type;
+
 	if (ioapic_force) 
 		return; 
 
@@ -270,7 +272,7 @@
 				} 
 
 				/* No multi-function device? */
-				u8 type = read_pci_config_byte(num,slot,func,
+				type = read_pci_config_byte(num,slot,func,
 							       PCI_HEADER_TYPE);
 				if (!(type & 0x80))
 					break;