int res = 0;
int had_dom0_bootargs = 0;
- struct bootmodule *mod = boot_module_find_by_kind(BOOTMOD_KERNEL);
+ const struct bootmodule *mod = kinfo->kernel_bootmodule;
if ( mod && mod->cmdline[0] )
bootargs = &mod->cmdline[0];
if ( dt_node_path_is_equal(node, "/chosen") )
{
- struct bootmodule *mod = boot_module_find_by_kind(BOOTMOD_RAMDISK);
+ const struct bootmodule *mod = kinfo->initrd_bootmodule;
if ( bootargs )
{
static void initrd_load(struct kernel_info *kinfo)
{
- struct bootmodule *mod = boot_module_find_by_kind(BOOTMOD_RAMDISK);
+ const struct bootmodule *mod = kinfo->initrd_bootmodule;
paddr_t load_addr = kinfo->initrd_paddr;
paddr_t paddr, len;
unsigned long offs;
info->dtb_paddr = modbase;
info->initrd_paddr = info->dtb_paddr + dtb_len;
+ info->initrd_bootmodule = mod;
}
static paddr_t kernel_zimage_place(struct kernel_info *info)
return -ENOENT;
}
+ info->kernel_bootmodule = mod;
start = mod->start;
size = mod->size;