diff --git a/0001-let-it-become-a-real-daemon.patch b/0001-let-it-become-a-real-daemon.patch index d08e4b9..0301e5c 100644 --- a/0001-let-it-become-a-real-daemon.patch +++ b/0001-let-it-become-a-real-daemon.patch @@ -13,9 +13,11 @@ well restore the system console. plymouth-0.9.0/src/main.c | 42 +++++++------ 5 files changed, 43 insertions(+), 18 deletions(-) ---- plymouth-0.9.0/src/libply-splash-core/ply-device-manager.c -+++ plymouth-0.9.0/src/libply-splash-core/ply-device-manager.c 2014-09-10 12:16:10.694235361 +0000 -@@ -947,3 +947,12 @@ ply_device_manager_deactivate_keyboards +Index: plymouth-0.9.0/src/libply-splash-core/ply-device-manager.c +=================================================================== +--- plymouth-0.9.0.orig/src/libply-splash-core/ply-device-manager.c ++++ plymouth-0.9.0/src/libply-splash-core/ply-device-manager.c +@@ -933,3 +933,12 @@ ply_device_manager_deactivate_keyboards node = next_node; } } @@ -28,9 +30,11 @@ well restore the system console. + ply_terminal_close, + manager); +} ---- plymouth-0.9.0/src/libply-splash-core/ply-device-manager.h -+++ plymouth-0.9.0/src/libply-splash-core/ply-device-manager.h 2014-09-10 12:16:24.826735672 +0000 -@@ -50,6 +50,7 @@ void ply_device_manager_deactivate_keybo +Index: plymouth-0.9.0/src/libply-splash-core/ply-device-manager.h +=================================================================== +--- plymouth-0.9.0.orig/src/libply-splash-core/ply-device-manager.h ++++ plymouth-0.9.0/src/libply-splash-core/ply-device-manager.h +@@ -49,6 +49,7 @@ void ply_device_manager_deactivate_keybo void ply_device_manager_activate_renderers (ply_device_manager_t *manager); void ply_device_manager_deactivate_renderers (ply_device_manager_t *manager); ply_terminal_t *ply_device_manager_get_default_terminal (ply_device_manager_t *manager); @@ -38,19 +42,40 @@ well restore the system console. #endif ---- plymouth-0.9.0/src/libply/ply-utils.c -+++ plymouth-0.9.0/src/libply/ply-utils.c 2014-09-10 08:53:01.886236228 +0000 -@@ -843,6 +843,8 @@ ply_detach_daemon (ply_daemon_handle_t * +Index: plymouth-0.9.0/src/libply/ply-utils.c +=================================================================== +--- plymouth-0.9.0.orig/src/libply/ply-utils.c ++++ plymouth-0.9.0/src/libply/ply-utils.c +@@ -77,6 +77,7 @@ + + static int errno_stack[PLY_ERRNO_STACK_SIZE]; + static int errno_stack_position = 0; ++static bool inChild = false; + + bool + ply_open_unidirectional_pipe (int *sender_fd, +@@ -797,6 +798,7 @@ ply_create_daemon (void) + { + int read_error = errno; + int status; ++ inChild = true; + + if (waitpid (pid, &status, WNOHANG) <= 0) + { +@@ -843,6 +845,9 @@ ply_detach_daemon (ply_daemon_handle_t * close (sender_fd); free (handle); -+ setsid(); ++ if (inChild) ++ setsid(); + return true; } ---- plymouth-0.9.0/src/libply/ply-terminal-session.c -+++ plymouth-0.9.0/src/libply/ply-terminal-session.c 2014-09-10 11:18:04.118735227 +0000 +Index: plymouth-0.9.0/src/libply/ply-terminal-session.c +=================================================================== +--- plymouth-0.9.0.orig/src/libply/ply-terminal-session.c ++++ plymouth-0.9.0/src/libply/ply-terminal-session.c @@ -187,6 +187,13 @@ ply_terminal_session_redirect_console (p assert (terminal_name != NULL); @@ -65,8 +90,10 @@ well restore the system console. fd = open (terminal_name, O_RDWR | O_NOCTTY); if (fd < 0) ---- plymouth-0.9.0/src/main.c -+++ plymouth-0.9.0/src/main.c 2014-09-10 13:02:23.242235200 +0000 +Index: plymouth-0.9.0/src/main.c +=================================================================== +--- plymouth-0.9.0.orig/src/main.c ++++ plymouth-0.9.0/src/main.c @@ -1042,6 +1042,7 @@ on_seat_added (state_t *state, } diff --git a/plymouth-ignore-cirrusdrm.patch b/plymouth-ignore-cirrusdrm.patch index 0f4282e..55c6e49 100644 --- a/plymouth-ignore-cirrusdrm.patch +++ b/plymouth-ignore-cirrusdrm.patch @@ -1,32 +1,15 @@ -Index: plymouth-0.9.0/src/libply-splash-core/ply-device-manager.c -=================================================================== ---- plymouth-0.9.0.orig/src/libply-splash-core/ply-device-manager.c -+++ plymouth-0.9.0/src/libply-splash-core/ply-device-manager.c -@@ -123,6 +123,9 @@ fb_device_has_drm_device (ply_device_man - const char *id_path; - bool has_drm_device = false; - -+ const char *card_name = udev_device_get_sysattr_value (fb_device, "name"); -+ ply_trace("First method gives us: %s", card_name); -+ - /* We want to see if the framebuffer is associated with a DRM-capable - * graphics card, if it is, we'll use the DRM device */ - card_matches = udev_enumerate_new (manager->udev_context); -@@ -149,8 +152,15 @@ fb_device_has_drm_device (ply_device_man - card_path = udev_list_entry_get_name (card_entry); - card_device = udev_device_new_from_syspath (manager->udev_context, card_path); - card_node = udev_device_get_devnode (card_device); -- if (card_node != NULL) -- has_drm_device = true; -+ if (card_node != NULL) { -+ /* don't consider drm driver for cirrus usable */ -+ const char *card_name = udev_device_get_sysattr_value (card_device, "name"); -+ ply_trace("Second method gives us: %s", card_name); -+ if (card_name && strcmp ("cirrusdrmfb", card_name) == 0) -+ has_drm_device = false; -+ else -+ has_drm_device = true; -+ } - else - ply_trace ("no card node!"); - +diff --git a/src/libply-splash-core/ply-device-manager.c b/src/libply-splash-core/ply-device-manager.c +index a5aa59d..0be2117 100644 +--- a/src/libply-splash-core/ply-device-manager.c ++++ b/src/libply-splash-core/ply-device-manager.c +@@ -125,6 +125,10 @@ fb_device_has_drm_device (ply_device_manager_t *manager, + const char *id_path; + bool has_drm_device = false; + ++ const char *card_name = udev_device_get_sysattr_value (fb_device, "name"); ++ if (card_name && strcmp ("cirrusdrmfb", card_name) == 0) ++ return false; ++ + /* We want to see if the framebuffer is associated with a DRM-capable + * graphics card, if it is, we'll use the DRM device */ + card_matches = udev_enumerate_new (manager->udev_context); diff --git a/plymouth.changes b/plymouth.changes index 1ac495f..5e7d05b 100644 --- a/plymouth.changes +++ b/plymouth.changes @@ -1,9 +1,14 @@ +------------------------------------------------------------------- +Thu Sep 25 13:19:01 UTC 2014 - idonmez@suse.com + +- Update 0001-device-manager-only-call-ply_terminal_free.patch to + call setsid only from the child process. + ------------------------------------------------------------------- Fri Sep 12 12:50:06 UTC 2014 - idonmez@suse.com - Add 0001-let-it-become-a-real-daemon.patch to make plymouth - a real daemon, fixes bnc#889757 and probably others. - Patch by Werner. + a real daemon, fixes part of bnc#889757. Patch by Werner. ------------------------------------------------------------------- Thu Sep 4 10:34:25 UTC 2014 - idonmez@suse.com