Re: 2.3.99-pre7-8 -- Compile errors in ide-pmac.c

From: Adam C Powell IV (hazelsct@mit.edu)
Date: Tue May 09 2000 - 13:46:54 EST


Miles Lane wrote:

> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -DEXPORT_SYMTAB -c ide.c
> ide.c: In function `ide_replace_subdriver':
> ide.c:1894: warning: implicit declaration of function `strncpy'
> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -DEXPORT_SYMTAB -c ide-features.c
> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -c -o ide-geometry.o ide-geometry.c
> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -c -o ide-probe.o ide-probe.c
> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -c -o ide-dma.o ide-dma.c
> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -c -o ide-pci.o ide-pci.c
> gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2
> -fomit-frame-pointer -fno-strict-aliasing -D__powerpc__ -fsigned-char
> -msoft-float -pipe -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
> -c -o ide-pmac.o ide-pmac.c
> ide-pmac.c: In function `pmac_ide_probe':
> ide-pmac.c:405: `FEATURE_Mediabay_IDE_reset' undeclared (first use in
> this function)
> ide-pmac.c:405: (Each undeclared identifier is reported only once
> ide-pmac.c:405: for each function it appears in.)
> ide-pmac.c:407: `FEATURE_Mediabay_IDE_enable' undeclared (first use in
> this function)
> ide-pmac.c: At top level:
> ide-pmac.c:90: warning: `udma_timings' defined but not used
> make[3]: *** [ide-pmac.o] Error 1
> make[3]: Leaving directory `/usr/src/linux-2.3.99-pre6/drivers/ide'
> make[2]: *** [first_rule] Error 2
> make[2]: Leaving directory `/usr/src/linux-2.3.99-pre6/drivers/ide'
> make[1]: *** [_subdir_ide] Error 2
> make[1]: Leaving directory `/usr/src/linux-2.3.99-pre6/drivers'
> make: *** [_dir_drivers] Error 2
>
> ** Sent via the linuxppc-user mail list. See http://lists.linuxppc.org/

The attached patch fixes this, and one other thing you're likely to run
into.

include/asm-ppc/string.h is funny, all the other arches which define
__HAVE_ARCH_* give the routine just below the declaration. Maybe it's
unfinished... In any case, I get things like "memmove undeclared" and
"implicit declaration" warnings without this patch.

Zeen,

-Adam P.


--- drivers/ide/ide-pmac.c.bak Tue May 9 12:11:32 2000
+++ drivers/ide/ide-pmac.c Tue May 9 12:12:57 2000
@@ -402,11 +402,11 @@
                                 feature_clear(np, FEATURE_IDE0_reset);
                                 break;
                             case 1:
- feature_set(np, FEATURE_Mediabay_IDE_reset);
+ feature_set(np, FEATURE_IDE1_reset);
                                 mdelay(10);
- feature_set(np, FEATURE_Mediabay_IDE_enable);
+ feature_set(np, FEATURE_IDE1_enable);
                                 mdelay(10);
- feature_clear(np, FEATURE_Mediabay_IDE_reset);
+ feature_clear(np, FEATURE_IDE1_reset);
                                 break;
                             case 2:
                                     /* This one exists only for KL, I don't know about any
--- include/asm-ppc/string.h.bak Tue May 9 13:51:38 2000
+++ include/asm-ppc/string.h Tue May 9 13:52:07 2000
@@ -1,15 +1,9 @@
 #ifndef _PPC_STRING_H_
 #define _PPC_STRING_H_
 
-#define __HAVE_ARCH_STRCPY
-#define __HAVE_ARCH_STRNCPY
-#define __HAVE_ARCH_STRLEN
-#define __HAVE_ARCH_STRCMP
-#define __HAVE_ARCH_STRCAT
 #define __HAVE_ARCH_MEMSET
 #define __HAVE_ARCH_BCOPY
 #define __HAVE_ARCH_MEMCPY
-#define __HAVE_ARCH_MEMMOVE
 #define __HAVE_ARCH_MEMCMP
-#define __HAVE_ARCH_MEMCHR
 

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon May 15 2000 - 21:00:14 EST