* MILO and PCI and BIOS ... gory details >LONG<
@ 1998-04-30 4:23 Andrew P. Lentvorski
1998-04-30 8:27 ` jestabro
0 siblings, 1 reply; 2+ messages in thread
From: Andrew P. Lentvorski @ 1998-04-30 4:23 UTC (permalink / raw)
To: axp-list; +Cc: andrewl, colmconn, Jay.Estabrook
First, we could use some help here with creating a 2.1.X version of MILO.
It would probably make Jay Estabrook's job a lot easier support wise.
Also, I was a bit disappointed that I got only 1 response to my last query
about MILO. Come on, gang, we can do better than that.
Okay, given that I have been digging through the milo code in an attempt
to get two Millenium II cards working on an Alpha, here is what I have
learned (or think I have learned). Jay, please correct me if I am wrong.
1) PCI Cards and BIOS -- Some cards need to have their BIOS ROM's run in
order to set their default state correctly. This is done quite well
by AlphaBIOS upon startup. I >STRONGLY< recommend that all systems use this
method from now on. Why? Since AlphaBIOS is the main way to boot NT on
new Digital machines, it gets the shiny, brand-new, sparkly x86 BIOS
emulation code as new hardware gets supported on NT. Thus, the emulation
code tends to be much more solid in AlphaBIOS than in any other program
you're going to have access to as a Linux person. :(
The upshot of this is that AlphaBIOS does a clean init of all the board
BIOS ROM's and should work with all boards currently cupported under NT Alpha.
This gets you to a nice default state.
The reason BIOS emulation was needed in earlier MILO's is that you could
blow it into the flash ROM and completely replace any other bootloader. This
requires an x86 BIOS emulator to init the installed cards. Given that
the newest/best/most-bug-fixed version of this is AlphaBIOS, you really
want to go that route. Flashing milo is no longer a terribly good option.
It may work fine, but it will probably be more work than it is worth as
newer hardware comes online.
2) After AlphaBIOS kicks up, you can activate linload.exe to boot the milo
image. I don't (yet) know what linload.exe is specifically doing as I
haven't looked at (and may not be able to get) code for it. However, it
just seems to set up some basic processor/chipset interaction state, nothing
having to do with the BIOS.
3) PALCode--Again, I haven't looked at it too closely, but it looks like it
just sets up some very basic system functionality and then throws execution
over to MILO. There doesn't seem to be any PCI board initialization here.
Just some initialization related to the specifics of the processor/chipset
(ie. EV56/Pyxis for my LX164 board) like memory mappings, etc. so that you
can activate the linux kernel. There doesn't appear to be anything related
to BIOS in here.
4) MILO -- The PALCode seems to leave most of the hard work up to MILO
with respect to PCI cards, ISA stuff, etc. MILO uses some "old" versions
of drivers to create effectively a mini Linux kernel. (Any volunteers
to bring these drivers up to 2.1.9X+?) The only use that MILO makes of
BIOS emulation routines is to "reinitialize" the vga graphics controller.
The "current" version of the Digital emulation library appears not to be
"new" enough to run the BIOS in the Millenium II cards. How do I know this?
I can compile a complete milo image and attempt to boot from it, but the system
hangs at attempting to start the vga mode. (Read your serial port for more
info) However, if I rip all of the VGA code out of the milo source, I can
then boot the system from the serial console without problem. My graphics
mode is still hosed, but I can then execute X which will override the current
hosed-up state and work just dandy. Surprisingly, the downloadable milo
binaries DO initialize a Millenium II card. I have asked Jay about the
discrepancy, but am still waiting for an answer (you'd better watch it, Jay,
or I'm gonna show up on your doorstep ;) ). However, the downloadable binary
is NOT strong enough to handle two Millenium II cards. The AlphaBIOS init
code, however, does appear to be strong enough to emulate the Mil II BIOS
and shut down the VGA mode on one of the cards. Thus, you can boot with two
Millenium II cards, but your graphics mode will still be hosed up. We won't
talk about what happens if you then try to run X, however. Thus, if I can
tear the vga bios emulation out and replace it with straight-up vga reset
commands, I can leverage the nice, strong AlphaBIOS emulator and not use
any BIOS emulation at all in MILO. Hopefully, I can shamelessly copy some
code from svgalib to just change the mode to 80x25 basic text and
then get on with working on debugging X.
So, to answer the question (in a long-winded way), your best bet for getting
new hardware to work is as follows:
1) Blow the latest version of AlphaBIOS for your board into flash
2) Set your system up to boot via the AlphaBIOS operating system choice menu
3) Install linload.exe and the milo image onto storage (hard drive or floppy)
4) Boot from the milo command line with your favorite kernel and parameters
If you do this, the only time that your favorite add-on's PCI BIOS is run
is by AlphaBIOS on startup (unless we're talking about a graphics card, and
then it's only run to reset the VGA state). Hopefully, I can patch the
milo code to dump the x86 emulation code completely. This will, however,
completely demolish using methods other than AlphaBIOS to boot Linux. This
should probably be part of a milo-2.1.X rewrite.
If this doesn't initialize your card such that the Linux main kernel can
recognize it, you're hosed. Either the AlphaBIOS doesn't support it (
check the NT Alpha hardware compatibility list) or you haven't set your
Linux kernel up properly.
I hate to volunteer myself into a FAQ, but someone might want to add a bit
of this updated info to the MILO FAQ as it seems to be a bit out-of-date.
I >WILL NOT< volunteer to maintain the MILO FAQ, however.
BTW, if you ask me about dual-head X on Alpha, I will immediately forward
your name to the xfree86 developers program and "volunteer" you for work.
I'm still a bit annoyed that my previous request for MILO assistance netted
exactly *1* reply about MILO and about 3 dozen about dual-head on X. ;)
Hope this helps,
Andy L.
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: MILO and PCI and BIOS ... gory details >LONG<
1998-04-30 4:23 MILO and PCI and BIOS ... gory details >LONG< Andrew P. Lentvorski
@ 1998-04-30 8:27 ` jestabro
0 siblings, 0 replies; 2+ messages in thread
From: jestabro @ 1998-04-30 8:27 UTC (permalink / raw)
To: andrewl; +Cc: axp-list
>>> "Andrew P. Lentvorski" said:
> First, we could use some help here with creating a 2.1.X version of MILO.
> It would probably make Jay Estabrook's job a lot easier support wise.
Hallelujah! ;-}
> The upshot of this is that AlphaBIOS does a clean init of all the board
> BIOS ROM's and should work with all boards currently cupported under NT Alpha.
> This gets you to a nice default state.
Yes, mostly; AlphaBIOS may enable the BIOS ROM for the emulation, but then
disable it when the emulation is done. This can cause problems with Xservers,
as many seem to require access to the BIOS ROM for mode tables and info.
I don't know how this should be attacked for multi-head situations; I guess
you could place the ROMS at different addresses via the PCI Config space
address register for this use...
> The reason BIOS emulation was needed in earlier MILO's is that you could
> blow it into the flash ROM and completely replace any other bootloader.
Correct.
> Flashing milo is no longer a terribly good option.
> It may work fine, but it will probably be more work than it is worth as
> newer hardware comes online.
Correct also.
> 2) After AlphaBIOS kicks up, you can activate linload.exe to boot the milo
> image. I don't (yet) know what linload.exe is specifically doing as I
> haven't looked at (and may not be able to get) code for it. However, it
> just seems to set up some basic processor/chipset interaction state, nothing
> having to do with the BIOS.
You can't get code for linload.exe, as it is encumbered in some way that makes
this illegal.
Indeed, it's not rocket science, but does have it's complexities:
1. interact with ARC/AlphaBIOS to get the Boot Selection details, and
original boot device, along with some HW details such as memory size,
and utilize the console routines to read the indicated MILO file.
2. do the necessary "swap-to-PAL" to go from NT-PALcode to the EBSDK
PALcode contained within MILO, which is required for correct MILO
and LINUX kernel operation.
> 3) PALCode--Again, I haven't looked at it too closely, but it looks like it
> just sets up some very basic system functionality and then throws execution
> over to MILO. There doesn't seem to be any PCI board initialization here.
> Just some initialization related to the specifics of the processor/chipset
> (ie. EV56/Pyxis for my LX164 board) like memory mappings, etc. so that you
> can activate the linux kernel. There doesn't appear to be anything related
> to BIOS in here.
All correct.
> MILO uses some "old" versions
> of drivers to create effectively a mini Linux kernel. (Any volunteers
> to bring these drivers up to 2.1.9X+?)
MILO uses the drivers from the kernel build you point it at; it's one of the
better reasons for porting MILO to later kernel revs, rather than the other
way around.
> The only use that MILO makes of
> BIOS emulation routines is to "reinitialize" the vga graphics controller.
Correct.
> The "current" version of the Digital emulation library appears not to be
> "new" enough to run the BIOS in the Millenium II cards.
AFAIK, this is not true; I've used a Mill II on an LX successfully, and others
have used them in other platforms as well (MIATA for one, prolly SX too).
> Surprisingly, the downloadable milo
> binaries DO initialize a Millenium II card. I have asked Jay about the
> discrepancy, but am still waiting for an answer
If you're building MILO under RH 5.0, you can't be including the DEC BIOS
emulator, as there are problems with that combination. The free X86 emulator
is indeed not up to the task, AFAIK, and that's what you're seeing, I think.
> However, the downloadable binary
> is NOT strong enough to handle two Millenium II cards.
This is prolly true of two *anything* cards... :-\
> Thus, if I can
> tear the vga bios emulation out and replace it with straight-up vga reset
> commands, I can leverage the nice, strong AlphaBIOS emulator and not use
> any BIOS emulation at all in MILO.
Absolutely; I'd give this a try under RH 5.0 with those latest MILO sources
against 2.0.30 that I put in the Kernels/ directory on gatekeeper. You'll
need to change only a couple of things to get rid of the emulator, but you
will need to rebuild a few of the ancillary binaries that come in 4.2 format
that won't execute under 5.0. I don't think there's a true need to go so far
as porting to 2.1.xx, at least for now, as that's still a moving target, to
some extent.
> Hopefully, I can shamelessly copy some
> code from svgalib to just change the mode to 80x25 basic text and
> then get on with working on debugging X.
Perhaps not necessary, but keep it in mind, as the methods for managing the
screen memory and scrolling may differ between AlphaBIOS and MILO/kernel,
which may indeed require a bit of "reset" type fiddling...
> Hopefully, I can patch the
> milo code to dump the x86 emulation code completely. This will, however,
> completely demolish using methods other than AlphaBIOS to boot Linux. This
> should probably be part of a milo-2.1.X rewrite.
I'd happily accept patches against 2.0.xx sources for such an option... :-)
--Jay++
-------------------------------------------------------------------------------
American Non Sequitur Society: we don't make sense, but we do like pizza...
Jay A Estabrook Alpha Migration Tools - LINUX Project
Digital Equipment Corp. (978) 506-4202 or (DTN) 226-4202
151 Taylor Street - TAY1-2 enet: Jay.Estabrook@digital.com
Littleton, MA 01460-1407
-------------------------------------------------------------------------------
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1998-04-30 17:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-04-30 4:23 MILO and PCI and BIOS ... gory details >LONG< Andrew P. Lentvorski
1998-04-30 8:27 ` jestabro
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox