vboot module: fix compilation issues

There were 3 things stopping the vboot module from being
compiled:

1. The vboot_reference code removed in the firmware/arch/$(ARCH)/include
   directory. This caused romcc to fail because romcc fails if -I<dir>
   points to non-existent directory.
2. The rmodule API does not have the no-clearing-of-bss variant of the
   load function.
3. cbfs API changes.

Change-Id: I1e1296c71c5831d56fc9acfaa578c84a948b4ced
Signed-off-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-on: http://review.coreboot.org/2881
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
This commit is contained in:
Aaron Durbin 2013-03-22 19:48:39 -05:00 committed by Stefan Reinauer
parent 1989b4bd56
commit c875e2aaab
2 changed files with 4 additions and 5 deletions

View File

@ -41,7 +41,6 @@ VB_SOURCE := vboot_reference
# Add the vboot include paths.
VB_INCLUDES += -I$(VB_SOURCE)/firmware/include
VB_INCLUDES += -I$(VB_SOURCE)/firmware/arch/$(VB_FIRMWARE_ARCH)/include
INCLUDES += $(VB_INCLUDES)
VBOOT_STUB_ELF = $(obj)/vendorcode/google/chromeos/vbootstub.elf
@ -57,7 +56,6 @@ VBOOT_STUB_DEPS += $(VB_LIB)
# vboot_reference can get to coreboot's include files.
VBOOT_CFLAGS += $(patsubst -I%,-I../%,$(filter-out -include $(src)/include/kconfig.h, $(CFLAGS)))
VBOOT_CFLAGS += -DVBOOT_DEBUG
$(warning $(VBOOT_CFLAGS))
$(VBOOT_STUB_DOTO): $(VBOOT_STUB_DEPS)
$(CC) $(LDFLAGS) -nostdlib -r -o $@ $^

View File

@ -46,7 +46,9 @@ static void vboot_run_stub(struct vboot_context *context)
char *vboot_region;
void (*entry)(struct vboot_context *context);
stage = cbfs_find_file(CONFIG_CBFS_PREFIX "/vboot", CBFS_TYPE_STAGE);
stage = cbfs_get_file_content(CBFS_DEFAULT_MEDIA,
CONFIG_CBFS_PREFIX "/vboot",
CBFS_TYPE_STAGE);
if (stage == NULL)
return;
@ -226,8 +228,7 @@ static void vboot_load_ramstage(struct vboot_handoff *vboot_handoff,
if (rmodule_parse(&ramstage_region[rmodule_offset], &ramstage))
return;
/* The ramstage is responsible for clearing its own bss. */
if (rmodule_load_no_clear_bss(&ramstage_region[load_offset], &ramstage))
if (rmodule_load(&ramstage_region[load_offset], &ramstage))
return;
entry_point = rmodule_entry(&ramstage);