Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(install): add default value for --firmwaredirs #1516

Merged
merged 1 commit into from
May 25, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions src/install/dracut-install.c
Original file line number Diff line number Diff line change
Expand Up @@ -1004,7 +1004,9 @@ static void usage(int status)
"\n"
" --module,-m Install kernel modules, instead of files\n"
" --kerneldir Specify the kernel module directory\n"
" (default: /lib/modules/`uname -r`)\n"
" --firmwaredirs Specify the firmware directory search path with : separation\n"
" (default: DRACUT_FIRMWARE_PATH env var, /lib/firmware if not set)\n"
" --silent Don't display error messages for kernel module install\n"
" --modalias Only generate module list from /sys/devices modalias list\n"
" -o --optional If kernel module does not exist, do not fail\n"
Expand Down Expand Up @@ -1183,14 +1185,12 @@ static int parse_argv(int argc, char *argv[])

path = getenv("DRACUT_FIRMWARE_PATH");

if (path == NULL) {
log_error("Environment variable DRACUT_FIRMWARE_PATH is not set");
exit(EXIT_FAILURE);
if (path) {
log_debug("DRACUT_FIRMWARE_PATH=%s", path);
firmwaredirs = strv_split(path, ":");
} else {
firmwaredirs = strv_new("/lib/firmware", NULL);
}

log_debug("DRACUT_FIRMWARE_PATH=%s", path);

firmwaredirs = strv_split(path, ":");
}
}

Expand Down