Firebird News

Tuesday, July 20, 2010

Error: bad register name %sil

while compiling linux kernel 0.0.1 on lucid lynx or debian sid with gcc 4.4.4 i've got this error message
http://portabilityblog.com/blog/archives/11-Bad-register-name-dil-or-sil.html

how i fixed in asm/segment.h ? i have changed the registers used in function from "r" to "q"
so i limit the register usage only for general ones EAX, EBX, ECX and EDX

extern inline void put_fs_byte(char val,char *addr)
{
__asm__ ("movb %0,%%fs:%1"::"q" (val),"m" (*addr));
}

what is the next error ?


ld -s -x -M -Ttext 0 -e startup_32 boot/head.o init/main.o \
kernel/kernel.o mm/mm.o fs/fs.o \
lib/lib.a \
-o tools/system > System.map
kernel/kernel.o: In function `scrup':
console.c:(.text+0x1ea4): undefined reference to `columns'
console.c:(.text+0x1f6c): undefined reference to `columns'
kernel/kernel.o: In function `scrdown':
console.c:(.text+0x1fc5): undefined reference to `columns'
Post a Comment