Also look for an "elf64 kernel" (for sparc64) and "elf32 kernel" (for

powerpc) when building metadata.
This commit is contained in:
Peter Wemm 2003-04-30 22:00:16 +00:00
parent daf509c612
commit 145b0eb56d
3 changed files with 9 additions and 3 deletions

View File

@ -294,7 +294,9 @@ md_load(char *args, vm_offset_t *modulep)
addr = roundup(addr, PAGE_SIZE);
kernend = 0;
kfp = file_findfile(NULL, "elf kernel");
kfp = file_findfile(NULL, "elf32 kernel");
if (kfp == NULL)
kfp = file_findfile(NULL, "elf kernel");
if (kfp == NULL)
panic("can't find kernel file");
file_addmetadata(kfp, MODINFOMD_HOWTO, sizeof howto, &howto);

View File

@ -294,7 +294,9 @@ md_load(char *args, vm_offset_t *modulep)
addr = roundup(addr, PAGE_SIZE);
kernend = 0;
kfp = file_findfile(NULL, "elf kernel");
kfp = file_findfile(NULL, "elf32 kernel");
if (kfp == NULL)
kfp = file_findfile(NULL, "elf kernel");
if (kfp == NULL)
panic("can't find kernel file");
file_addmetadata(kfp, MODINFOMD_HOWTO, sizeof howto, &howto);

View File

@ -296,7 +296,9 @@ md_load(char *args, vm_offset_t *modulep)
addr = roundup(addr, PAGE_SIZE);
kernend = 0;
kfp = file_findfile(NULL, "elf kernel");
kfp = file_findfile(NULL, "elf64 kernel");
if (kfp == NULL)
kfp = file_findfile(NULL, "elf kernel");
if (kfp == NULL)
panic("can't find kernel file");
file_addmetadata(kfp, MODINFOMD_HOWTO, sizeof howto, &howto);