Bug reported by Paul Mackerras: if a module parameter fails, we didn't
call module_arch_cleanup().
On x86 this was harmless (module_arch_cleanup() is a no-op), but on
other architectures like PPC this causes inconsistent data structures
and subsequent oopses.
NULL);
}
if (err < 0)
- goto cleanup;
+ goto arch_cleanup;
/* Get rid of temporary copy */
vfree(hdr);
/* Done! */
return mod;
+ arch_cleanup:
+ module_arch_cleanup(mod);
cleanup:
module_unload_free(mod);
module_free(mod, mod->module_init);