Tyson D Sawyer <[EMAIL PROTECTED]> writes:
> "Eric W. Biederman" wrote:
> >
> > I was messing around with the boot process, and managed
> > to slightly modify mkrom and start32.inc so I can
> > successfully use rombase 0xfffff000. Basically
> > it simply required using a short jump instead of a long
> > one and using %cs instead of %es in loading the gdt.
> >
> > So now I don't even need to implement the 384KB memory
> > hole at 640KB - 1MB.
> >
> > The only problem I couldn't properly fix was in NLBConfig.
> > It chouldn't properly print an interger like 0xfffff000 in hex.
> > I had to resort to just copying the string from the rombase
> > directive. Can anyone with more python knowledge help here?
>
> Please keep this optional. Because I have a paged flash, I intend to
> "shadow" the bios into SDRAM in its normal location. Once I have done
> this I will be able to freely page the flash at the top of memory.
Not a problem. It is just a small collection of fixes, to the existing
code but no real change. The fun part is that I have come up so
fast this way that I can execute instructions before my system bus
stabalizes. At least that is what it feels like is happening
it is hart to tell about these things.
>
> For the moment I put a copy of the bios at the top of every flash page.
> Its a gross hack, but it works for now. ;-)
>
> Also, once you have shadowed the bios into SDRAM, is there any reason
> (other than ISA devices you might have) for needing the 640K hole? I
> don't know of any.
The legacy video card address is the only one I can think of. The
reason I was really wanting this was to simply memory initialization.
In particular for the case of ECC sdram where it needs to be zero'd.
With memory in just contiguous blob the code can just do a simple
contiguous loop. That I might put into a reusable routine but the
rest should be fine.
One thing I have found is that if you compile a static binary with
-fPIC -static. After that all you have to do to relocate your code is
modify the .got section. Which is just a table of plain pointers. No
fancy relocation needed. There might be an issue with getting a few bugs
out of ld but the idea basically works. I still need to confirm this
works in practics... Especially with my ELF loader there are a number
of places I could really use this.
Eric