main: provide way to toggle udev device enumeration off

We don't want to use udev for device enumeration if:

1) DISPLAY is set (since we're going to use the X11 renderer)
2) if it's disabled explicitly on the kernel command line

This commit adds support for those two things.
This commit is contained in:
Ray Strode 2013-12-09 21:07:16 -05:00
parent c66c207d2e
commit 487092edd4

View file

@ -2200,6 +2200,10 @@ main (int argc,
if (command_line_has_argument (state.kernel_command_line, "plymouth.ignore-serial-consoles"))
device_manager_flags |= PLY_DEVICE_MANAGER_FLAGS_IGNORE_SERIAL_CONSOLES;
if (command_line_has_argument (state.kernel_command_line, "plymouth.ignore-udev") ||
(getenv ("DISPLAY") != NULL))
device_manager_flags |= PLY_DEVICE_MANAGER_FLAGS_IGNORE_UDEV;
load_devices (&state, device_manager_flags);
ply_trace ("entering event loop");