[coreboot] [PATCH] Free VGA BIOS for K8M890

Luc Verhaegen libv at skynet.be
Sat Apr 25 18:23:17 CEST 2009


On Sat, Apr 25, 2009 at 04:01:09PM +0200, Rudolf Marek wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Hello,
> 
> I managed to catch all I/O for init of K8M890 IGP. Attached patch is for
> http://www.nongnu.org/vgabios/. With a patch one can have a console and some VGA
> resolutions also might work.
> 
> It is just a interesting result.
> 
> I used libx86 library to catch all IO. It was quite painful until I realize that
> the emulator cannot handle properly opcodes like
> 
> 0x66 0xe8 .. .. 0xff 0xff and also mov al,cs:[ebx] which  I get caught in Sebios
> int 15 routine.
> 
> I somehow  managed to fix the emulator (only hacks) and patched the IO backend
> of emulator and obtained following tracedump:
> 
> OUTB to 3c3 is 1
> OUTW to 3c4 is 32
> OUTB to 3c4 is 10
> INB from 3c5 is 0
> OUTB to 3c5 is 1
> OUTL to cf8 is 80010000
> INL from cfc is 32301106
> OUTB to 3c4 is 2d
> INB from 3c5 is aa
> OUTB to 3c5 is bf
> OUTW to 3c4 is 816
> ...
> and other ~250 lines
> 
> Those were just directly transformed with bash script to IO calls in patch. The
> BIOS works, it even sets the memory speed grade, but not the mem size to scratch
> registers (it uses SeaBIOS VIA vga hooks for this)

A proper driver doesn't care about the scratch. But sadly such proper 
driver doesn't support vt3230 fully yet (although it does support the 
host for finding out those values directly). With this working, i am 
actually tempted to do the little work needed to get a VGA out working 
on my driver right away.
 
> I can boot X without any problems, Windows 7 boots with VGAfailsafe driver and
> 16 colors ;)
> 
> If someone ever want to write somethink like SeaBIOS but for VGA here is the
> chance (I dont have time :/)

I had a first pass at this code last january (2008) for CLE266. Should 
get the dust off of it.

> What is important, some bits in this init fixes also the problem with PowerNow
> which I had until VGA option rom was run. There must be smth set which enables
> the HT deliver stop grants or smth like this again.
> 
> Rudolf.

Come monday i will look through it and filter out what i think is not 
relevant as a start for finding out what needs to set up for HT to 
work properly. It could be multiple registers, but i'm sure that i can 
reduce this set to 1/10 or even less on the first pass just on sight. 
After a few iterations, we will have what we need.

Nice work!

Luc Verhaegen.




More information about the coreboot mailing list