fix a warning, clean up code and makefiles

Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Acked-by: Ronald G. Minnich <rminnich@gmail.com>



git-svn-id: svn://coreboot.org/repository/LinuxBIOSv3@94 f3766cd6-281f-0410-b1cd-43a5c92072e9
This commit is contained in:
Stefan Reinauer 2007-02-23 11:51:32 +00:00
parent 464f4cb19d
commit 0c11caa5e0
4 changed files with 32 additions and 35 deletions

View file

@ -71,7 +71,7 @@ else
include $(src)/.config
all: prepare prepare2 $(obj)/linuxbios.rom
$(Q)echo "build process finished."
$(Q)echo "Build process finished."
MAINBOARDDIR=$(shell echo $(CONFIG_MAINBOARD_NAME))

View file

@ -18,6 +18,8 @@
## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
##
SILENT := &> /dev/null
$(obj)/linuxbios.rom: $(obj)/linuxbios.lar $(obj)/stage0.init $(obj)/linuxbios.vpd
$(Q)cat $(obj)/linuxbios.lar \
$(obj)/linuxbios.vpd \
@ -30,16 +32,7 @@ $(obj)/linuxbios.rom: $(obj)/linuxbios.lar $(obj)/stage0.init $(obj)/linuxbios.v
#
lzma:
$(Q)echo "building lzma"
#
# initram is always uncompressed. It belongs into the mainboard directory
# and is build from what was auto.c in v2
#
initram:
$(Q)echo "building initram"
$(Q)echo "Building lzma... skipped"
#
# this is the rest of linuxbios (v2: linuxbios_ram.rom)
@ -80,7 +73,7 @@ $(obj)/linuxbios.stage2: $(obj)/stage0.init $(obj)/statictree.o
#
payload:
$(Q)echo "building payload"
$(Q)echo "Building payload... skipped"
#
@ -96,7 +89,8 @@ $(obj)/linuxbios.lar: $(obj)/util/lar/lar lzma $(obj)/linuxbios.initram $(obj)/l
$(Q)cp $(obj)/linuxbios.stage2 $(obj)/lar.tmp/normal/stage2
$(Q)cd $(obj)/lar.tmp && ../util/lar/lar c ../linuxbios.lar.pre normal/initram normal/stage2
# TODO: dynamically pad the lar archive. bs is image size - bootblock size (8k)
$(Q)dd if=$(obj)/linuxbios.lar.pre of=$(obj)/linuxbios.lar bs=253952 count=1 conv=sync
$(Q)dd if=$(obj)/linuxbios.lar.pre of=$(obj)/linuxbios.lar \
bs=253952 count=1 conv=sync $(SILENT)
#

View file

@ -57,52 +57,52 @@ it with the version available from LANL.
* LinuxBIOS is divided into Pre-DRAM part and DRAM part.
* The phases before this part are phase 0 and phase 1.
* This part contains phases x through y.
*
*
* Device Enumeration:
* In the dev_enumerate() phase,
*/
int stage2(void)
{
struct lb_memory *lb_mem;
post_code(0x20);
dev_init();
dev_phase1(); /* console init, also ANYTHING that has to be done before printk can be used */
/* console init, also ANYTHING that has to be done
* before printk can be used
*/
post_code(0x30);
dev_phase1();
// printk_notice("LinuxBIOS-%s%s %s booting...\n",
// linuxbios_version, linuxbios_extra_version, linuxbios_build);
// printk_notice("LinuxBIOS-%s%s %s booting...\n", linuxbios_version, linuxbios_extra_version, linuxbios_build);
/* here is where weird stuff like init_timer handling should be
* done. This is for ANYTHING that might have to happen before
* device enumeration but that needs a printk
*/
post_code(0x40);
/* here is where weird stuff like init_timer handling should be done. This is for ANYTHING
* that might have to happen before device enumeration but that needs a printk
*/
dev_phase2();
/* walk physical devices and add any dynamic devices to the device tree */
/* walk physical devices and add any dynamic devices to the
* device tree
*/
post_code(0x30);
dev_root_phase3();
post_code(0x40);
/* Compute and assign the bus resources. */
post_code(0x40);
dev_phase4();
post_code(0x50);
/* Now actually enable devices on the bus */
post_code(0x50);
dev_root_phase5();
post_code(0x60);
/*initialize devices on the bus */
post_code(0x60);
dev_phase6();
post_code(0x70);
#ifdef NOT
/* Now that we have collected all of our information
* write our configuration tables.
*/
phase8(); /* all devices up, prepare for elfboot */
elfboot(lb_mem);
#endif
return 0;
}

View file

@ -26,13 +26,16 @@
$(obj)/linuxbios.vpd:
$(Q)printf "Building dummy VPD ..."
$(Q)dd if=/dev/zero of=$(obj)/linuxbios.vpd bs=256 count=1
$(Q)dd if=/dev/zero of=$(obj)/linuxbios.vpd bs=256 count=1 $(SILENT)
$(Q)printf "ok.\n"
#
# this is going to be the init ram code:
#
# initram is always uncompressed. It belongs into the mainboard directory
# and is build from what was auto.c in v2
#
$(obj)/linuxbios.initram: $(obj)/stage0.init $(obj)/stage0.o
$(Q)echo Building linuxbios.initram