[coreboot] Problems with VIA EPIA-ME6000

Uwe Hermann uwe at hermann-uwe.de
Wed Mar 5 15:13:56 CET 2008


[Forwarding to list]

On Tue, Mar 04, 2008 at 09:04:58PM -0500, mercury at wirebros.com wrote:
> As we talk about images, do we need both of them (normal and fallback)?

No, fallback-only will also work. Normal-only does _not_ work.


> I managed to build working coreboot using fallback image only, no VGA bios.

Yep.


> The problem is that from power-up to first console log it takes roughly
> 10seconds. I never managed to build coreboot with both images (normal,
> fallback). Platform: EPIA MII-1.2GHz, 512MB ram.

Hm, should work, at least it does for many other boards. What was the
problem?


> Please also see my comment in patch below;
> 
> 
> 
> > On Tue, Mar 04, 2008 at 05:10:40PM +0100, Klaus Stammermann wrote:
> >> Here the diff:
> >> -----------------------------------------------------------------------------------------------------------------------------------
> >> Index: src/mainboard/via/epia-m/Options.lb
> >> ===================================================================
> >> --- src/mainboard/via/epia-m/Options.lb	(Revision 3086)
> >> +++ src/mainboard/via/epia-m/Options.lb	(Arbeitskopie)
> >> @@ -51,8 +51,8 @@
> >>  ###
> >>  ### Build options
> >>  ###
> >> -default CONFIG_PCI_ROM_RUN=0
> >> -default CONFIG_CONSOLE_VGA=0
> >> +default CONFIG_PCI_ROM_RUN=1
> >> +default CONFIG_CONSOLE_VGA=1
> >
> > Looks ok.
> >
> >
> >>  ##
> >>  ## Build code for the fallback boot
> >> Index: targets/via/epia-m/Config.lb
> >> ===================================================================
> >> --- targets/via/epia-m/Config.lb	(Revision 3086)
> >> +++ targets/via/epia-m/Config.lb	(Arbeitskopie)
> >> @@ -7,21 +7,21 @@
> >>  option  DEFAULT_CONSOLE_LOGLEVEL=8
> >>  option  CONFIG_CONSOLE_SERIAL8250=1
> >>
> >> -option ROM_SIZE=256*1024
> >> +option ROM_SIZE=(256*1024)-(64*1024)
> >
> > OK, assuming you have a 256KB ROM chip and your VGA BIOS is 64KB.
> 
> if it's less than 64k, do we pad it or adjust ROM_SIZE to be exactly
> 256k-vgabios?

You set ROM_SIZE to '(256*1024)-12345' if the VGA blob is exactly 12345
bytes, for example. No extra manual padding or such. But you prepend
the 12345 bytes big VGA blob to coreboot.rom later (to make it exactly
256KB big).


> >>  option HAVE_OPTION_TABLE=1
> >>  option CONFIG_ROM_PAYLOAD=1
> >>  option HAVE_FALLBACK_BOOT=1
> >>  #option CONFIG_COMPRESSED_PAYLOAD_NRV2B=1
> >> -option CONFIG_COMPRESSED_PAYLOAD_NRV2B=0
> >> +#option CONFIG_COMPRESSED_PAYLOAD_NRV2B=0
> >
> > Why?
> >
> >
> >>  ### Compute the location and size of where this firmware image
> >>  ### (coreboot plus bootloader) will live in the boot rom chip.
> >>  ###
> >> -option FALLBACK_SIZE=131072
> >> +option FALLBACK_SIZE=(96*1024)
> >
> what this parameter is for?
> where is it used?

Size of the fallback image.


> > Not sure about this. I'd rather not change it unless really necessary
> > (it isn't in this case, I think).
> >
> >
> >>  ## Coreboot C code runs at this location in RAM
> >>  option _RAMBASE=0x00004000
> >> @@ -31,18 +31,22 @@
> >>  #
> >>  romimage "normal"
> >>  	option USE_FALLBACK_IMAGE=0
> >> -#option ROM_IMAGE_SIZE=128*1024
> >> -	option ROM_IMAGE_SIZE=64*1024
> >> +#	option ROM_IMAGE_SIZE=(128*1024)-27312
> >> +	option ROM_IMAGE_SIZE=(96*1024)-27312
> >
> > This is wrong.
> >
> > ROM_IMAGE_SIZE is the maximum size the coreboot code can use (without
> > payload, without VGA ROM, etc).
> >
> > Something like 64*1024 is usually ok.
> We can use ROM_SECTION_SIZE to specify size of "normal" image, but we need
> to offset it using ROM_SECTION_OFFSET=vgabiossize so I believe you need to
> use these 2 variables.

Hm, I wouldn't do that. I don't think ROM_SECTION_SIZE is meant to be
modified, it's for internal use only.

For prepending VGA images, using a correct ROM_SIZE should be enough,
e.g. 'option ROM_SIZE=(256*1024)-(64*1024)' for a 64KB VGA image. If
that's not enough it's probably a bug in the build system/configuration.


> >
> >
> >> +#	option ROM_IMAGE_SIZE=0xc000
> >> +#	option ROM_SECTION_OFFSET=0x10000
> >> +#	option ROM_SECTION_SIZE=0x18000
> >>  	option COREBOOT_EXTRA_VERSION=".0-Normal"
> >> -	payload $(HOME)/svn/payload.elf
> >> +	payload $(HOME)/Entwicklung/LinuxBIOS/VIA-BIOS/filo.small.elf
> >
> > Never used $(HOME) here, but I assume it works? If not, try
> > /tmp/filo.elf and copy your payload there.
> >
> >
> >>  end
> >>
> >>  romimage "fallback"
> >>  	option USE_FALLBACK_IMAGE=1
> >> -	#option ROM_IMAGE_SIZE=128*1024
> >> -	option ROM_IMAGE_SIZE=60*1024
> >> +#	option ROM_IMAGE_SIZE=(128*1024)-27312
> >> +	option ROM_IMAGE_SIZE=(96*1024)-27312
> >
> > Also wrong, see above.
> Should this section be offset by 128k?

No, don't think so, will be done internally, you don't have to
manually fix it.


> or buildrom will take care of it?

Yes, but I think you mean 'targets/buildtarget'?


> 
> >
> >
> >> +#	option ROM_IMAGE_SIZE=0xc000
> >>  	option COREBOOT_EXTRA_VERSION=".0-Fallback"
> >> -	payload $(HOME)/svn/payload.elf
> >> +	payload $(HOME)/Entwicklung/LinuxBIOS/VIA-BIOS/filo.small.elf
> >>  end
> >>
> >>  buildrom ./coreboot.rom ROM_SIZE "normal" "fallback"
> >> -----------------------------------------------------------------------------------------------------------------------------------
> >
> >
> >> In an earlier version I changed Config.lb in src dir to get VGA BIOS.
> >> But now
> >> it isn't included. If it is important, I could post it later.
> >
> > Plese post it.
> >
> > But the above patch comes from an 'svn diff' at the top-level directory,
> > correct? I.e. all your current changes are in there?
> >
> >
> >> > Also, where did you get your VGA ROM from? Using which tools
> >> (awardeco,
> >> > amideco, phnxdeco, other)? How big is it exactly?
> >> >
> >> On http://www.coreboot.org/VGA_support at bottom there is a perl script.
> >> Using
> >> this I got my VGABIOS. This is 60416 bytes big
> >
> > OK. Which vendor BIOS does the board have? Can you use
> > awardeco/amideco/phnxdeco to get the VGA BIOS and compare it with the
> > one from the script? Just to be sure that worked fine...
> >
> >
> >> (optionsrom is 57344 bytes which I used at last).
> >
> > Huh, what's that? Where from?
> >
> >
> >> filo.small.elf is 27312 bytes big. So don't wonder what number this is.
> >
> > Are you sure this is ok? The smallest usable FILO I've used so far is
> > ca. 57 KB. Your 27 KB FILO looks _very_ small.
> >
> > Also, please use the latest version from
> >
> >  % svn co svn://coreboot.org/filo/trunk/filo-0.5
> >
> > Type 'make' (that will generate a Config file), then edit Config, then
> > type make again.


Uwe.
-- 
http://www.hermann-uwe.de  | http://www.holsham-traders.de
http://www.crazy-hacks.org | http://www.unmaintained-free-software.org




More information about the coreboot mailing list