I successfully boot Linux kernel 2.6.7 by LinuxBIOS V2 + filo. However, I have to disable AGP support in the kernel because I got some errors when Kernel initialized agpgart.
I checked the source code. It seems that AGP is not supported for via/epia board either in V1 or in V2. Am I right?
How can I obtain AGP support? I need Xwindow.
Thanks.
Simon Cheng www.msica.com
I am trying to use ADLO + video bios to enable VGA support for my EPIA 800 board. Unfortunately, the code hangs after the elfboot "Jumping to boot code at 0x7c00 "
According to ADLO document, I enabled the original bios shadow from C0000 to DFFFF and capture the vedio bios by:
dd if=/proc/kcore of=/usr/src/video.bios.bin bs=1 count=65536 skip=790528
Program headers of the /proc/kcore is: Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align NOTE 0x000094 0x00000000 0x00000000 0x006bc 0x00000 0 LOAD 0x8001000 0xc8000000 0x00000000 0x37fee000 0x37fee000 RWE 0x1000 LOAD 0x001000 0xc0000000 0x00000000 0x77f0000 0x77f0000 RWE 0x1000
Then I make payload and romimage.
Is there anything wrong with my procedure?
By the way, how to debug ADLO?
Simon Cheng www.msica.com
Simon Xin Cheng wrote:
I am trying to use ADLO + video bios to enable VGA support for my EPIA 800 board. Unfortunately, the code hangs after the elfboot "Jumping to boot code at 0x7c00 "
According to ADLO document, I enabled the original bios shadow from C0000 to DFFFF and capture the vedio bios by:
Make sure your shadowing is enable correctly. You want to read from the bios chip and write to RAM. Then enable the full shadow of that location.
dd if=/proc/kcore of=/usr/src/video.bios.bin bs=1 count=65536 skip=790528
Examine this file and see if it has the BIOS extension signature of 0xaa55 (or 0x55aa depending on what endian you view it as) You should also see some text iding the bios.
By the way, how to debug ADLO?
In ./util/ADLO/bochs/bios/rombios.c there should be a #define DEBUG_SERIAL. Set that to 1 and all of the bios messages will go out the serial port. Note you have to disable it to get video since it bypases screenwrites.
DEBUG_SERIAL is from a patch but I don't know if it make it into CVS. If you don't have a DEBUG_SERIAL then search the archives for the patch. If you can't find it then let me know and I'll see about generating one for you.
rombios.c also has lots of debug options as well look at the source.
One thing to note is that if you do any hacking on the assembly in rombios.c you must be very careful about shifting the positions of all the bios entry points. A single instrution in some of those assembly blocks will break all the bios entry points.
Richard,
Thanks for your suggestions. I tried them, however, the system still hangs when jumping to boot code at 0x7c00.
Examine this file and see if it has the BIOS extension signature of 0xaa55 (or 0x55aa depending on what endian you view it as) You should also see some text iding the bios.
I enabled all shadowing and found 0xaa55 and bios copyright information at the beginning of file.
In ./util/ADLO/bochs/bios/rombios.c there should be a #define DEBUG_SERIAL. Set that to 1 and all of the bios messages will go out the serial port.
My source has DEBUG_SERIAL and by default it is enabled. Nothing appears for this default configuration.
I also tried to disabled DEBUG_SERIAL, but no video appears either.
Right now I suspect that something wrong with loder.s. My question is how to debug loader.s? Thanks again.
Simon Cheng www.msica.com
Simon Xin Cheng wrote:
Richard,
Thanks for your suggestions. I tried them, however, the system still hangs when jumping to boot code at 0x7c00.
Right now I suspect that something wrong with loder.s. My question is how to debug loader.s? Thanks again.
The most likely problem is that your shadowing is not working.
Right after loader finishes copying to ram and you have enabled reads to be routed to RAM dump the first few bytes from 0x7c00 and dump them out the seial port and make sure things really got copied to RAM.
Richard Smith wrote:
Simon Xin Cheng wrote:
Richard,
Thanks for your suggestions. I tried them, however, the system still hangs when jumping to boot code at 0x7c00.
Right now I suspect that something wrong with loder.s. My question is how to debug loader.s? Thanks again.
The most likely problem is that your shadowing is not working.
Right after loader finishes copying to ram and you have enabled reads to be routed to RAM dump the first few bytes from 0x7c00 and dump them out the seial port and make sure things really got copied to RAM.
Richard,
Thanks for your help on ADLO. I tried to trace loader.s, and have following problems: 1. Before sti jmp 0xFFFF:0x0000 I can print out something. But right after sti, I can not print out anything. So, I am not sure that the code really jumps to the power on entry point.
2. The first 16 bytes after 0xF0000 after shadowing are the same as rombios.bin. However, when I tried to print out more bytes, I can only get 16 output. What is the problem? My code is right after copy bios to 0xF0000:
mov ax, #0x10 mov ds, ax mov eax, #0xF0000 mov esi, eax
mov ecx, #0x30 ; loop counter mov dx, #0x3f8 ; serial port
cld str_loop: lodsb out dx, al loop str_loop
Thanks,
Simon
Simon Xin Cheng wrote:
rombios.bin. However, when I tried to print out more bytes, I can only get 16 output. What is the problem? My code is right after copy bios to 0xF0000:
mov ax, #0x10 mov ds, ax mov eax, #0xF0000 mov esi, eax
mov ecx, #0x30 ; loop counter mov dx, #0x3f8 ; serial port
cld str_loop: lodsb out dx, al loop str_loop
Thats because you have forgotten that the CPU runs several orders of magnitude faster than the serial port. You only get 16 bytes because the 16550 UART FIFO is only 16 bytes deep. After that your bytes are going to the bit bucket.
You have to wait until the busy flag of the 16550 is clear after you write each byte. See the a data sheet on the UART.
Hi,
I am working on booting Linux from hard disk with VGA support on an EPIA board. I am using ADLO to load video bios and bochs bios.
I found an interesting thing. The last two instructions in the loader.s of ADLO is :
sti jmp 0xFFFF:0x0000
I turned DEBUG_SERIAL on in rombios.c. But I can not see any debugging information through serial port after the jumping.
However, if I commented out the sti, I can see all debugging information. So what is the problem with the sti? Are there any LinuxBIOS interrupt service routines that never return back?
Simon