Messages in this thread Patch in this message | | | Date | Sun, 3 Aug 2003 12:57:07 +0200 | From | Adrian Bunk <> | Subject | [patch] 2.4.22-pre10-ac1: fix tp600.c compile warning |
| |
I got the following compile warning in 2.4.22-pre10-ac1:
<-- snip -->
... gcc -D__KERNEL__ -I/home/bunk/linux/kernel-2.4/linux-2.4.22-pre10-ac1-full/inclu de -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=k6 -nostdinc -iwithprefix include -DKBUILD_BASENAME=tp600 -c -o tp600.o tp600.c tp600.c: In function `h2999_cleanup': tp600.c:417: warning: control reaches end of non-void function ...
<-- snip -->
Since the only caller of this function doesn't check the return value, I assume the following patch might be correct?
--- linux-2.4.22-pre10-ac1-full/drivers/hotplug/tp600.c~ 2003-08-02 01:44:02.000000000 +0200 +++ linux-2.4.22-pre10-ac1-full/drivers/hotplug/tp600.c 2003-08-02 23:13:34.000000000 +0200 @@ -402,7 +402,7 @@ * Unregister and free up all of our slots */ -static int __devinit h2999_cleanup(struct h2999_dev *dev) +static void __devinit h2999_cleanup(struct h2999_dev *dev) { struct h2999_slot *s; int slot;
I've tested the compilation with 2.4.22-pre10-ac1.
cu Adrian
--
"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
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |