362b0053e8
cases. OBS-URL: https://build.opensuse.org/package/show/Base:System/plymouth?expand=0&rev=144
88 lines
3.6 KiB
Diff
88 lines
3.6 KiB
Diff
Index: plymouth-0.8.8_git20140327/src/libply-splash-core/ply-device-manager.c
|
|
===================================================================
|
|
--- plymouth-0.8.8_git20140327.orig/src/libply-splash-core/ply-device-manager.c
|
|
+++ plymouth-0.8.8_git20140327/src/libply-splash-core/ply-device-manager.c
|
|
@@ -58,6 +58,8 @@ struct _ply_device_manager
|
|
int udev_queue_fd;
|
|
ply_fd_watch_t *udev_queue_fd_watch;
|
|
struct udev_monitor *udev_monitor;
|
|
+ bool has_serial_consoles;
|
|
+
|
|
|
|
ply_seat_added_handler_t seat_added_handler;
|
|
ply_seat_removed_handler_t seat_removed_handler;
|
|
@@ -501,6 +503,7 @@ ply_device_manager_new (const char
|
|
manager->loop = NULL;
|
|
manager->terminals = ply_hashtable_new (ply_hashtable_string_hash, ply_hashtable_string_compare);
|
|
manager->local_console_terminal = ply_terminal_new (default_tty);
|
|
+ manager->has_serial_consoles = false;
|
|
ply_hashtable_insert (manager->terminals,
|
|
(void *) ply_terminal_get_name (manager->local_console_terminal),
|
|
manager->local_console_terminal);
|
|
@@ -670,21 +673,19 @@ create_seat_for_terminal (const char
|
|
static bool
|
|
create_seats_from_terminals (ply_device_manager_t *manager)
|
|
{
|
|
- bool has_serial_consoles;
|
|
-
|
|
ply_trace ("checking for consoles");
|
|
|
|
if (manager->flags & PLY_DEVICE_MANAGER_FLAGS_IGNORE_SERIAL_CONSOLES)
|
|
{
|
|
- has_serial_consoles = false;
|
|
+ manager->has_serial_consoles = false;
|
|
ply_trace ("ignoring all consoles but default console because explicitly told to.");
|
|
}
|
|
else
|
|
{
|
|
- has_serial_consoles = add_consoles_from_file (manager, "/sys/class/tty/console/active");
|
|
+ manager->has_serial_consoles = add_consoles_from_file (manager, "/sys/class/tty/console/active");
|
|
}
|
|
|
|
- if (has_serial_consoles)
|
|
+ if (manager->has_serial_consoles)
|
|
{
|
|
ply_trace ("serial consoles detected, managing them with details forced");
|
|
ply_hashtable_foreach (manager->terminals,
|
|
@@ -838,6 +839,15 @@ ply_device_manager_has_open_seats (ply_d
|
|
return false;
|
|
}
|
|
|
|
+bool
|
|
+ply_device_manager_has_serial_consoles (ply_device_manager_t *manager)
|
|
+{
|
|
+ if (manager)
|
|
+ return manager->has_serial_consoles;
|
|
+ else
|
|
+ return false;
|
|
+}
|
|
+
|
|
ply_list_t *
|
|
ply_device_manager_get_seats (ply_device_manager_t *manager)
|
|
{
|
|
Index: plymouth-0.8.8_git20140327/src/main.c
|
|
===================================================================
|
|
--- plymouth-0.8.8_git20140327.orig/src/main.c
|
|
+++ plymouth-0.8.8_git20140327/src/main.c
|
|
@@ -848,7 +848,7 @@ plymouth_should_show_default_splash (sta
|
|
};
|
|
int i;
|
|
|
|
- if (state->should_force_details)
|
|
+ if (ply_device_manager_has_serial_consoles(state->device_manager) || state->should_force_details)
|
|
return false;
|
|
|
|
for (i = 0; strings[i] != NULL; i++)
|
|
Index: plymouth-0.8.8_git20140327/src/libply-splash-core/ply-device-manager.h
|
|
===================================================================
|
|
--- plymouth-0.8.8_git20140327.orig/src/libply-splash-core/ply-device-manager.h
|
|
+++ plymouth-0.8.8_git20140327/src/libply-splash-core/ply-device-manager.h
|
|
@@ -42,6 +42,7 @@ void ply_device_manager_watch_seats (ply
|
|
ply_seat_removed_handler_t seat_removed_handler,
|
|
void *data);
|
|
bool ply_device_manager_has_open_seats (ply_device_manager_t *manager);
|
|
+bool ply_device_manager_has_serial_consoles (ply_device_manager_t *manager);
|
|
ply_list_t *ply_device_manager_get_seats (ply_device_manager_t *manager);
|
|
void ply_device_manager_free (ply_device_manager_t *manager);
|
|
void ply_device_manager_activate_keyboards (ply_device_manager_t *manager);
|