j
: Next unread message k
: Previous unread message j a
: Jump to all threads
j l
: Jump to MailingList overview
The patch belows changes ppc/io.h the same way as sparc32/io.h to correctly define in* and out* functions for the unix build. Without it gcc outputs the following error messages and bails out:
arch/unix/unix.c:156: error: no previous prototype for ‘inb’ arch/unix/unix.c:168: error: no previous prototype for ‘inw’ arch/unix/unix.c:180: error: no previous prototype for ‘inl’ arch/unix/unix.c:192: error: no previous prototype for ‘outb’ arch/unix/unix.c:205: error: no previous prototype for ‘outw’ arch/unix/unix.c:217: error: no previous prototype for ‘outl’
Index: include/ppc/io.h =================================================================== --- include/ppc/io.h (révision 399) +++ include/ppc/io.h (copie de travail) @@ -141,6 +141,23 @@ ns--; } } +#else /* BOOTSTRAP */ +#ifdef FCOMPILER +#define inb(reg) ((u8)0xff) +#define inw(reg) ((u16)0xffff) +#define inl(reg) ((u32)0xffffffff) +#define outb(reg, val) do{} while(0) +#define outw(reg, val) do{} while(0) +#define outl(reg, val) do{} while(0) +#else +extern u8 inb(u32 reg); +extern u16 inw(u32 reg); +extern u32 inl(u32 reg); +extern void insw(u32 reg, void *addr, unsigned long count); +extern void outb(u32 reg, u8 val); +extern void outw(u32 reg, u16 val); +extern void outl(u32 reg, u32 val); +extern void outsw(u32 reg, const void *addr, unsigned long count); #endif - +#endif #endif /* _ASM_IO_H */
On 1/13/09, Aurelien Jarno aurelien@aurel32.net wrote:
The patch belows changes ppc/io.h the same way as sparc32/io.h to correctly define in* and out* functions for the unix build. Without it gcc outputs the following error messages and bails out:
Thanks, applied.