Back out OF module installation in the event of failure. PS3 firmware gives
some ancient FDT version (2) that fails the init check in OFW_FDT. It is still possible to make progress, but not while the OF layer is going crazy.
This commit is contained in:
parent
dd1aa0e47b
commit
52d939886a
@ -201,6 +201,12 @@ OF_install(char *name, int prio)
|
||||
ofw_def_t *ofwp, **ofwpp;
|
||||
static int curr_prio = 0;
|
||||
|
||||
/* Allow OF layer to be uninstalled */
|
||||
if (name == NULL) {
|
||||
ofw_def_impl = NULL;
|
||||
return (FALSE);
|
||||
}
|
||||
|
||||
/*
|
||||
* Try and locate the OFW kobj corresponding to the name.
|
||||
*/
|
||||
|
@ -393,6 +393,7 @@ boolean_t
|
||||
OF_bootstrap()
|
||||
{
|
||||
boolean_t status = FALSE;
|
||||
int err = 0;
|
||||
|
||||
#ifdef AIM
|
||||
if (openfirmware_entry != NULL) {
|
||||
@ -409,7 +410,7 @@ OF_bootstrap()
|
||||
if (status != TRUE)
|
||||
return status;
|
||||
|
||||
OF_init(openfirmware);
|
||||
err = OF_init(openfirmware);
|
||||
} else
|
||||
#endif
|
||||
if (fdt != NULL) {
|
||||
@ -418,10 +419,16 @@ OF_bootstrap()
|
||||
if (status != TRUE)
|
||||
return status;
|
||||
|
||||
OF_init(fdt);
|
||||
OF_interpret("perform-fixup", 0);
|
||||
err = OF_init(fdt);
|
||||
if (err == 0)
|
||||
OF_interpret("perform-fixup", 0);
|
||||
}
|
||||
|
||||
if (err != 0) {
|
||||
OF_install(NULL, 0);
|
||||
status = FALSE;
|
||||
}
|
||||
|
||||
return (status);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user