Look for an elf32 kernel (powerpc) and elf64 kernel (sparc64) as well

as a plain "elf kernel".
This commit is contained in:
Peter Wemm 2003-04-30 22:05:48 +00:00
parent d6d3ae55c3
commit dae0bca875
3 changed files with 9 additions and 3 deletions

View File

@ -267,7 +267,9 @@ powerpc_init(u_int startkernel, u_int endkernel, u_int basekernel, void *mdp)
*/
if (mdp != NULL) {
preload_metadata = mdp;
kmdp = preload_search_by_type("elf kernel");
kmdp = preload_search_by_type("elf32 kernel");
if (kmdp != NULL)
kmdp = preload_search_by_type("elf kernel");
if (kmdp != NULL) {
boothowto = MD_FETCH(kmdp, MODINFOMD_HOWTO, int);
kern_envp = MD_FETCH(kmdp, MODINFOMD_ENVP, char *);

View File

@ -267,7 +267,9 @@ powerpc_init(u_int startkernel, u_int endkernel, u_int basekernel, void *mdp)
*/
if (mdp != NULL) {
preload_metadata = mdp;
kmdp = preload_search_by_type("elf kernel");
kmdp = preload_search_by_type("elf32 kernel");
if (kmdp != NULL)
kmdp = preload_search_by_type("elf kernel");
if (kmdp != NULL) {
boothowto = MD_FETCH(kmdp, MODINFOMD_HOWTO, int);
kern_envp = MD_FETCH(kmdp, MODINFOMD_ENVP, char *);

View File

@ -242,7 +242,9 @@ sparc64_init(caddr_t mdp, u_long o1, u_long o2, u_long o3, ofw_vec_t *vec)
*/
if (mdp != NULL) {
preload_metadata = mdp;
kmdp = preload_search_by_type("elf kernel");
kmdp = preload_search_by_type("elf64 kernel");
if (kmdp != NULL)
kmdp = preload_search_by_type("elf kernel");
if (kmdp != NULL) {
boothowto = MD_FETCH(kmdp, MODINFOMD_HOWTO, int);
kern_envp = MD_FETCH(kmdp, MODINFOMD_ENVP, char *);