87b2ef0edf
Remove the function EnableBlocklist() and add a constructor argument to enable/disable the use of modules.blocklist. In all cases, the enabling/disabling of the blocklist happens immediately after creating the Modprobe object. So this simplies libmodprobe. Additionally, the use of the blocklist by libmodprobe should be enabled by default unless explicitly disabled during creation of the Modprobe object. Currently, only modprobe(8) defaults to not using the blocklist and includes the argument -b BLOCKLIST for enabling it. That functionality remains. This refactor allows us to use the blocklist during first stage init. However, additional logic is needed to not return an error for the blocked non-aliased modules during first stage init; otherwise, the error would result in an init crash leading to a device reboot. So fixup LoadListedModules() to allow blocking modules without returning an error. Bug: 182582036 Test: boot test on pixel 5 with a module in modules.blocklist Change-Id: I394b5aa98fa98821011982cfe693749010c381f7 |
||
---|---|---|
.. | ||
Android.bp | ||
generate-input.h-labels.py | ||
getevent.c | ||
getprop.cpp | ||
modprobe.cpp | ||
MODULE_LICENSE_APACHE2 | ||
NOTICE | ||
OWNERS | ||
setprop.cpp | ||
start.cpp | ||
toolbox.c | ||
tools.h |