Skip to contentSkip to conversation

Remove compile warning from drivers/ide/pci/cs5520.c

PATCH In review Bob Miller 2 participants 2 messages Dec 11, 2002 – Dec 12, 2002

lore
Share & tools
lore

Bob Miller

author
#0 lore raw

PATCH 1/1 Remove compile warning from drivers/ide/pci/cs5520.c

The function, cs5520_tune_chipset() is declared to return an int. Added a return statement instead of just falling of off the bottom.

drivers/ide/pci/cs5520.c +2 -0
diff -Nru a/drivers/ide/pci/cs5520.c b/drivers/ide/pci/cs5520.c
@@ -166,6 +166,8 @@
 	/* ATAPI is harder so leave it for now */
 	if(!error && drive->media == ide_disk)
 		error = hwif->ide_dma_on(drive);
+
+	return error;
 }	
 	
 static void cs5520_tune_drive(ide_drive_t *drive, u8 pio)
Signature · 2 lines
Bob Miller					Email: [email protected]
Open Source Development Lab			Phone: 503.626.2455 Ext. 17
#1 lore raw

drivers/ide/pci/cs5520.c line 170

Quoted 12 lines · Bob Miller

The function, cs5520_tune_chipset() is declared to return an int. Added a return statement instead of just falling of off the bottom.

diff -Nru a/drivers/ide/pci/cs5520.c b/drivers/ide/pci/cs5520.c

drivers/ide/pci/cs5520.c +2 -0
@@ -166,6 +166,8 @@
 	/* ATAPI is harder so leave it for now */
 	if(!error && drive->media == ide_disk)
 		error = hwif->ide_dma_on(drive);
+
+	return error;

Eep thats a nasty little bug, lucky my compiler left the error value in %eax anyway good spotting