Difference between revisions of "ADLO"

From coreboot
Jump to: navigation, search
(Where is ADLO?)
(How do I get LinuxBIOS to boot ADLO?)
Line 39: Line 39:
 
== How do I get LinuxBIOS to boot ADLO? ==
 
== How do I get LinuxBIOS to boot ADLO? ==
  
ADLO compiles as an ELF image so you have to set up LinuxBIOS to elf boot just as if you were using any other ELF payload. In the ADLO directory are some README's.  Make sure you have read them.
+
ADLO compiles as an ELF image so you have to set up LinuxBIOS to elf boot just as if you were using any other ELF payload. In the [http://www.openbios.org/viewcvs/trunk/LinuxBIOSv2/util/ADLO/ ADLO directory] are some READMEs.  Make sure you have read them.
Compiling ADLO is quite simple.  Mostly you just type 'make'  You will need the 16-bit assembler as86 installed to build the Bochs BIOS.  You will aslo need a copy of your video BIOS if you want VGA to work.  Again see the README.
+
  
Out-of-the box ADLO probally won't boot unless you are using the exact mainboard that the ADLO project usesThe reason is that various areas of shadowing must be enabled for ADLO to boot.
+
Compiling ADLO is quite simple.  Mostly you just type ''make''  You will need the 16-bit assembler as86 installed to build the Bochs BIOSYou will also need a copy of your video BIOS if you want VGA to workAgain see the README.
+
If you see elfboot indicate that its 'Jumping to boot code at 0x7c00' and then the board resets or hangs then its very likely that your shadow settings are incorrectApplying the serial debug patch to ADLO can help you further investigate this.  
+
  
/!\ FixMe Where is the defacto location for the serial patch?
+
=== BIOS shadowing ===
+
 
The shadow settings are set in loader.s in the freebios/util/ADLO.  Find section B.  These are writes to PCI space that enable various areas of shadowing.
+
Out-of-the box ADLO probally won't boot unless you are using the exact mainboard that the ADLO project uses (FIXME: which one is this?). The reason is that various areas of shadowing must be enabled for ADLO to boot. (FIXME: please explain)
 +
 
 +
If you see '''elfboot''' indicate that it is 'Jumping to boot code at 0x7c00' and then the board resets or hangs then its very likely that your shadow settings are incorrect. Applying the serial debug patch to ADLO can help you further investigate this.
 +
 +
<div style="margin-top:0.5em; padding:0.5em 0.5em 0.5em 0.5em; background-color:#ffdfdf; align:right; border:1px solid #aabbcc;">
 +
FixMe Where is the defacto location for the serial patch?
 +
</div>
 +
 
 +
The shadow settings are set in '''loader.s''' in the freebios/util/ADLO.  Find section B.  These are writes to PCI space that enable various areas of shadowing.
 
 
 
Technically all you need is the only 64kb at 0xF0000 and 64kb at 0xC0000. Your mileage may vary.  Start by enabling Read/Write for all shadow ranges supported by your chipset and then backing off to 0xF0000 and 0xC0000 after you get it working.
 
Technically all you need is the only 64kb at 0xF0000 and 64kb at 0xC0000. Your mileage may vary.  Start by enabling Read/Write for all shadow ranges supported by your chipset and then backing off to 0xF0000 and 0xC0000 after you get it working.
+
 
The ADLO makefile will copy your video bios from an existing setup.  See the README and makefile for details. If you have one of the BIOS kits provided by the video chipset mfg for your board then you may have a stock image an then a program that allows you to customize the stock image.  If so then you need to set things up so that the video bios is set to be loaded at 0x0C0000 (sometimes called the C000 segment)
+
=== Video BIOS ===
+
 
 +
The ADLO Makefile will copy your video bios from an existing setup.  See the '''README''' and '''Makefile''' for details.
 +
 
 
ADLO expects the video bios to be 64k in size whereas a lot of video BIOS images are only 32k.  You can solve this by just duplicating in the same file and then letting ADLO use that.  Some creative work with 'dd' and padding would achieve the same result.
 
ADLO expects the video bios to be 64k in size whereas a lot of video BIOS images are only 32k.  You can solve this by just duplicating in the same file and then letting ADLO use that.  Some creative work with 'dd' and padding would achieve the same result.
+
 
Lastly if you have applied the serial debug patch to BOCHS then _all_ the output is routed out to the serial port so your video screen will be blank.  
+
=== Serial Output ===
 +
 
 +
Lastly if you have applied the serial debug patch to BOCHS then '''all''' the output is routed out to the serial port so your video screen will be blank.  
 
However VSYNC will still be generated if the video chip is initialized properly.  You can watch for VSYNC with a Oscope or plug a newer type monitor up to the video output.  Most modern monitors will tell you when they can/can't find the VSYNC signal.  Note you may have to power cycle the monitor between attempts as sometimes they can get very confused.
 
However VSYNC will still be generated if the video chip is initialized properly.  You can watch for VSYNC with a Oscope or plug a newer type monitor up to the video output.  Most modern monitors will tell you when they can/can't find the VSYNC signal.  Note you may have to power cycle the monitor between attempts as sometimes they can get very confused.

Revision as of 18:25, 16 October 2006

Contents

What is ADLO?

ADLO is a glue layer which bonds LinuxBIOS to the 16-bit PC BIOS of the Bochs project.

It was originally written by Adam Sulmicki.

See the following url:

http://www.missl.cs.umd.edu/sebos_phase2.html

Since the Bochs BIOS provides many of legacy BIOS services it allows you to boot some OS's that depend on those services.

What bios services does ADLO provide and when would I need them.

The full gory details for XP are at:

http://www.missl.cs.umd.edu/winint/index2.html

The full gory details for W2K are at:

http://www.missl.cs.umd.edu/winint/index1.html

What bootloaders work with ADLO?

Currently known to work are:

  • LILO
  • NTLDR (Windows 2000)

There is no technical reason why it couldn't work with *BSD, (Free)Dos, and other versions of Windows after some tweaking.

Where is ADLO?

ADLO is part of the LinuxBIOS v2 repository under LinuxBIOSv2/util/ADLO.

An older version was already part of LinuxBIOS v1 and is available at the LinuxBIOSv1/util/ADLO directory.

How do I get LinuxBIOS to boot ADLO?

ADLO compiles as an ELF image so you have to set up LinuxBIOS to elf boot just as if you were using any other ELF payload. In the ADLO directory are some READMEs. Make sure you have read them.

Compiling ADLO is quite simple. Mostly you just type make You will need the 16-bit assembler as86 installed to build the Bochs BIOS. You will also need a copy of your video BIOS if you want VGA to work. Again see the README.

BIOS shadowing

Out-of-the box ADLO probally won't boot unless you are using the exact mainboard that the ADLO project uses (FIXME: which one is this?). The reason is that various areas of shadowing must be enabled for ADLO to boot. (FIXME: please explain)

If you see elfboot indicate that it is 'Jumping to boot code at 0x7c00' and then the board resets or hangs then its very likely that your shadow settings are incorrect. Applying the serial debug patch to ADLO can help you further investigate this.

FixMe Where is the defacto location for the serial patch?

The shadow settings are set in loader.s in the freebios/util/ADLO. Find section B. These are writes to PCI space that enable various areas of shadowing.

Technically all you need is the only 64kb at 0xF0000 and 64kb at 0xC0000. Your mileage may vary. Start by enabling Read/Write for all shadow ranges supported by your chipset and then backing off to 0xF0000 and 0xC0000 after you get it working.

Video BIOS

The ADLO Makefile will copy your video bios from an existing setup. See the README and Makefile for details.

ADLO expects the video bios to be 64k in size whereas a lot of video BIOS images are only 32k. You can solve this by just duplicating in the same file and then letting ADLO use that. Some creative work with 'dd' and padding would achieve the same result.

Serial Output

Lastly if you have applied the serial debug patch to BOCHS then all the output is routed out to the serial port so your video screen will be blank. However VSYNC will still be generated if the video chip is initialized properly. You can watch for VSYNC with a Oscope or plug a newer type monitor up to the video output. Most modern monitors will tell you when they can/can't find the VSYNC signal. Note you may have to power cycle the monitor between attempts as sometimes they can get very confused.