/boot/boot problem
Sergey Lyubka
valenok at gmail.com
Thu Dec 2 03:00:16 PST 2004
Hi John,
thanks for commiting my previous boot2.c patch.
I would appreciate any hint about the following problem.
I am using 5.3, sources from 1 Dec 2004.
The environment I am using is this: ATA disk has one partition
with one file, /kernel. /kernel has MFS root filesystem.
there is no /boot/loader, /kernel is boot by the first stage
loader (/boot/boot).
So, the problem is:
1. when /kernel is kgzipped, It says 'Invalid format'.
that means, inflate() could not correctly unzip the kernel.
2. when /kernel is not kgzipped, boot crashes:
int=06 err=0 efl=10002 eip=c0432540
eax=c0432540 ebx=c2152600 ecx=18 edx=a050001e
esi=947a4 edi=c0432540 ebp=7 esp=9e6f0
cs:eip= ff ff ff ff ff .... (all ff)
ss:eip=69 95 00 00 00 00 00 80 1c 00 50 00 00 00 00 00
objdump -d kernel shows, that eip c0432540 is exactly where
kernel's .text segment starts:
c0432540 <.text>:
c0432540: 66 c7 05 72 04 00 00 movw $0x1234,0x472
c0432547: 34 12
c0432549: 55 push %ebp
So it looks like that kernel was mapped wrong ?
3. The craziest thing is that *sometimes* it works!
I do build kernels again and again, without cvsup-ing the sources,
and sometimes it works, sometimes not.
Any comment, hint etc would be very appreciated.
sergey
More information about the freebsd-hackers
mailing list