From e220878aa96471a6d9d56c093d5674fa27d7fe16 Mon Sep 17 00:00:00 2001 From: CentOS Buildsys Date: Mar 07 2014 16:01:24 +0000 Subject: import plymouth-0.8.9-0.10.20140113.el7.src.rpm --- diff --git a/.plymouth.metadata b/.plymouth.metadata index 5da5d27..cac76f3 100644 --- a/.plymouth.metadata +++ b/.plymouth.metadata @@ -1 +1 @@ -578f649b03d900abf582a9b4d32cde9bc3c688e7 SOURCES/plymouth-0.8.9.tar.bz2 +69382b5353ea26410dfc546898e59f48350b8023 SOURCES/plymouth-0.8.9.tar.bz2 diff --git a/SOURCES/add-two-step-features.patch b/SOURCES/add-two-step-features.patch deleted file mode 100644 index 548a5aa..0000000 --- a/SOURCES/add-two-step-features.patch +++ /dev/null @@ -1,1632 +0,0 @@ -From 8fa6fec9d86dbe34be626652cda0fba4f4803223 Mon Sep 17 00:00:00 2001 -From: Ray Strode -Date: Tue, 22 Oct 2013 18:34:46 -0400 -Subject: [PATCH 1/5] pixel-buffer: add tiling function - -It can be useful to tile a group of pixels across the screen -(for e.g. backgrounds). - -This commit adds API to pixel buffer to do that tiling. - -A follow up commit will add support into ply-image so images can -be loaded from disk and then tiled on screen. ---- - src/libply-splash-core/ply-pixel-buffer.c | 30 ++++++++++++++++++++++++++++++ - src/libply-splash-core/ply-pixel-buffer.h | 4 ++++ - 2 files changed, 34 insertions(+) - -diff --git a/src/libply-splash-core/ply-pixel-buffer.c b/src/libply-splash-core/ply-pixel-buffer.c -index a612990..a860b7f 100644 ---- a/src/libply-splash-core/ply-pixel-buffer.c -+++ b/src/libply-splash-core/ply-pixel-buffer.c -@@ -821,32 +821,62 @@ ply_pixel_buffer_rotate (ply_pixel_buffer_t *old_buffer, - bytes = ply_pixel_buffer_get_argb32_data (buffer); - - double d = sqrt ((center_x * center_x + - center_y * center_y)); - double theta = atan2 (-center_y, -center_x) - theta_offset; - double start_x = center_x + d * cos (theta); - double start_y = center_y + d * sin (theta); - double step_x = cos (-theta_offset); - double step_y = sin (-theta_offset); - - for (y = 0; y < height; y++) - { - old_y = start_y; - old_x = start_x; - start_y += step_x; - start_x -= step_y; - for (x = 0; x < width; x++) - { - if (old_x < 0 || old_x > width || old_y < 0 || old_y > height) - bytes[x + y * width] = 0; - else - bytes[x + y * width] = - ply_pixel_buffer_interpolate (old_buffer, old_x, old_y); - old_x += step_x; - old_y += step_y; - } - } - return buffer; - } - -+ply_pixel_buffer_t * -+ply_pixel_buffer_tile (ply_pixel_buffer_t *old_buffer, -+ long width, -+ long height) -+{ -+ long x, y; -+ long old_x, old_y; -+ long old_width, old_height; -+ uint32_t *bytes, *old_bytes; -+ ply_pixel_buffer_t *buffer; -+ -+ buffer = ply_pixel_buffer_new (width, height); -+ -+ old_bytes = ply_pixel_buffer_get_argb32_data (old_buffer); -+ bytes = ply_pixel_buffer_get_argb32_data (buffer); -+ -+ old_width = old_buffer->area.width; -+ old_height = old_buffer->area.height; -+ -+ for (y = 0; y < height; y++) -+ { -+ old_y = y % old_height; -+ for (x = 0; x < width; x++) -+ { -+ old_x = x % old_width; -+ bytes[x + y * width] = old_bytes[old_x + old_y * old_width]; -+ } -+ } -+ return buffer; -+} - - /* vim: set ts=4 sw=4 et ai ci cino={.5s,^-2,+.5s,t0,g0,e-2,n-2,p2s,(0,=.5s,:.5s */ -diff --git a/src/libply-splash-core/ply-pixel-buffer.h b/src/libply-splash-core/ply-pixel-buffer.h -index 47cdd52..e0dffda 100644 ---- a/src/libply-splash-core/ply-pixel-buffer.h -+++ b/src/libply-splash-core/ply-pixel-buffer.h -@@ -97,34 +97,38 @@ void ply_pixel_buffer_fill_with_buffer_at_opacity (ply_pixel_buffer_t *canvas, - ply_pixel_buffer_t *source, - int x_offset, - int y_offset, - float opacity); - void ply_pixel_buffer_fill_with_buffer_with_clip (ply_pixel_buffer_t *canvas, - ply_pixel_buffer_t *source, - int x_offset, - int y_offset, - ply_rectangle_t *clip_area); - void ply_pixel_buffer_fill_with_buffer (ply_pixel_buffer_t *canvas, - ply_pixel_buffer_t *source, - int x_offset, - int y_offset); - - - void ply_pixel_buffer_push_clip_area (ply_pixel_buffer_t *buffer, - ply_rectangle_t *clip_area); - void ply_pixel_buffer_pop_clip_area (ply_pixel_buffer_t *buffer); - - uint32_t *ply_pixel_buffer_get_argb32_data (ply_pixel_buffer_t *buffer); - - ply_pixel_buffer_t *ply_pixel_buffer_resize (ply_pixel_buffer_t *old_buffer, - long width, - long height); - - ply_pixel_buffer_t *ply_pixel_buffer_rotate (ply_pixel_buffer_t *old_buffer, - long center_x, - long center_y, - double theta_offset); - -+ply_pixel_buffer_t *ply_pixel_buffer_tile (ply_pixel_buffer_t *old_buffer, -+ long width, -+ long height); -+ - #endif - - #endif /* PLY_PIXEL_BUFFER_H */ - /* vim: set ts=4 sw=4 expandtab autoindent cindent cino={.5s,(0: */ --- -1.8.3.1 - - -From fc440513d337ca15067039383502f73a0fe2796f Mon Sep 17 00:00:00 2001 -From: Ray Strode -Date: Tue, 22 Oct 2013 18:36:15 -0400 -Subject: [PATCH 2/5] ply-image: add tiling support - -This follow up commit adds tiling support to images, so -that splash screens can have been background patterns instead -of just background colors. ---- - src/libply-splash-graphics/ply-image.c | 15 +++++++++++++++ - src/libply-splash-graphics/ply-image.h | 1 + - 2 files changed, 16 insertions(+) - -diff --git a/src/libply-splash-graphics/ply-image.c b/src/libply-splash-graphics/ply-image.c -index be85809..7d21946 100644 ---- a/src/libply-splash-graphics/ply-image.c -+++ b/src/libply-splash-graphics/ply-image.c -@@ -227,53 +227,68 @@ ply_image_resize (ply_image_t *image, - long width, - long height) - { - ply_image_t *new_image; - - new_image = ply_image_new (image->filename); - - new_image->buffer = ply_pixel_buffer_resize (image->buffer, - width, - height); - return new_image; - } - - ply_image_t * - ply_image_rotate (ply_image_t *image, - long center_x, - long center_y, - double theta_offset) - { - ply_image_t *new_image; - - new_image = ply_image_new (image->filename); - - new_image->buffer = ply_pixel_buffer_rotate (image->buffer, - center_x, - center_y, - theta_offset); - return new_image; - } - -+ply_image_t * -+ply_image_tile (ply_image_t *image, -+ long width, -+ long height) -+{ -+ ply_image_t *new_image; -+ -+ new_image = ply_image_new (image->filename); -+ -+ new_image->buffer = ply_pixel_buffer_tile (image->buffer, -+ width, -+ height); -+ return new_image; -+} -+ - ply_pixel_buffer_t * - ply_image_get_buffer (ply_image_t *image) - { - assert (image != NULL); - - return image->buffer; - } - - ply_pixel_buffer_t * - ply_image_convert_to_pixel_buffer (ply_image_t *image) - { - ply_pixel_buffer_t *buffer; - - assert (image != NULL); - - buffer = image->buffer; - image->buffer = NULL; - ply_image_free (image); - - return buffer; - } - - /* vim: set ts=4 sw=4 expandtab autoindent cindent cino={.5s,(0: */ -diff --git a/src/libply-splash-graphics/ply-image.h b/src/libply-splash-graphics/ply-image.h -index 66fa520..5bda567 100644 ---- a/src/libply-splash-graphics/ply-image.h -+++ b/src/libply-splash-graphics/ply-image.h -@@ -12,37 +12,38 @@ - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA - * 02111-1307, USA. - * - * Written By: Ray Strode - */ - #ifndef PLY_IMAGE_H - #define PLY_IMAGE_H - - #include "ply-pixel-buffer.h" - - #include - #include - #include - - typedef struct _ply_image ply_image_t; - - #ifndef PLY_HIDE_FUNCTION_DECLARATIONS - ply_image_t *ply_image_new (const char *filename); - void ply_image_free (ply_image_t *image); - bool ply_image_load (ply_image_t *image); - uint32_t *ply_image_get_data (ply_image_t *image); - long ply_image_get_width (ply_image_t *image); - long ply_image_get_height (ply_image_t *image); - ply_image_t *ply_image_resize (ply_image_t *image, long width, long height); - ply_image_t *ply_image_rotate (ply_image_t *oldimage, long center_x, long center_y, double theta_offset); -+ply_image_t *ply_image_tile (ply_image_t *image, long width, long height); - ply_pixel_buffer_t *ply_image_get_buffer (ply_image_t *image); - ply_pixel_buffer_t *ply_image_convert_to_pixel_buffer (ply_image_t *image); - - #endif - - #endif /* PLY_IMAGE_H */ - /* vim: set ts=4 sw=4 expandtab autoindent cindent cino={.5s,(0: */ --- -1.8.3.1 - - -From 257408d44d1b5d0dc202f60f79d3d8f5c3427413 Mon Sep 17 00:00:00 2001 -From: Ray Strode -Date: Tue, 22 Oct 2013 19:24:14 -0400 -Subject: [PATCH 3/5] two-step: add support for tiled background image - -If there's a file named background-tile.png in the theme -then it will get used as the background behind the other -content in place of the background gradient. ---- - src/plugins/splash/two-step/plugin.c | 45 ++++++++++++++++++++++++++++++++++++ - 1 file changed, 45 insertions(+) - -diff --git a/src/plugins/splash/two-step/plugin.c b/src/plugins/splash/two-step/plugin.c -index 541a108..2c6d97a 100644 ---- a/src/plugins/splash/two-step/plugin.c -+++ b/src/plugins/splash/two-step/plugin.c -@@ -64,70 +64,72 @@ - #define FRAMES_PER_SECOND 30 - #endif - - #ifndef SHOW_ANIMATION_PERCENT - #define SHOW_ANIMATION_PERCENT 0.9 - #endif - - typedef enum { - PLY_BOOT_SPLASH_DISPLAY_NORMAL, - PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY, - PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY - } ply_boot_splash_display_type_t; - - typedef enum { - PROGRESS_FUNCTION_TYPE_WWOODS, - PROGRESS_FUNCTION_TYPE_LINEAR, - } progress_function_t; - - typedef struct - { - ply_boot_splash_plugin_t *plugin; - ply_pixel_display_t *display; - ply_entry_t *entry; - ply_animation_t *end_animation; - ply_progress_animation_t *progress_animation; - ply_throbber_t *throbber; - ply_label_t *label; - ply_label_t *message_label; - ply_rectangle_t box_area, lock_area; - ply_trigger_t *end_trigger; -+ ply_image_t *background_image; - } view_t; - - struct _ply_boot_splash_plugin - { - ply_event_loop_t *loop; - ply_boot_splash_mode_t mode; - ply_image_t *lock_image; - ply_image_t *box_image; - ply_image_t *corner_image; - ply_image_t *header_image; -+ ply_image_t *background_tile_image; - ply_list_t *views; - - ply_boot_splash_display_type_t state; - - double animation_horizontal_alignment; - double animation_vertical_alignment; - char *animation_dir; - - ply_progress_animation_transition_t transition; - double transition_duration; - - uint32_t background_start_color; - uint32_t background_end_color; - - progress_function_t progress_function; - - ply_trigger_t *idle_trigger; - ply_trigger_t *stop_trigger; - - uint32_t root_is_mounted : 1; - uint32_t is_visible : 1; - uint32_t is_animating : 1; - uint32_t is_idle : 1; - }; - - ply_boot_splash_plugin_interface_t * ply_boot_splash_plugin_get_interface (void); - - static void stop_animation (ply_boot_splash_plugin_t *plugin, - ply_trigger_t *idle_trigger); - -@@ -149,66 +151,83 @@ view_new (ply_boot_splash_plugin_t *plugin, - - view->entry = ply_entry_new (plugin->animation_dir); - view->end_animation = ply_animation_new (plugin->animation_dir, - "animation-"); - view->progress_animation = ply_progress_animation_new (plugin->animation_dir, - "progress-"); - - view->throbber = ply_throbber_new (plugin->animation_dir, - "throbber-"); - ply_progress_animation_set_transition (view->progress_animation, - plugin->transition, - plugin->transition_duration); - - view->label = ply_label_new (); - view->message_label = ply_label_new (); - - return view; - } - - static void - view_free (view_t *view) - { - - ply_entry_free (view->entry); - ply_animation_free (view->end_animation); - ply_progress_animation_free (view->progress_animation); - ply_throbber_free (view->throbber); - ply_label_free (view->label); - ply_label_free (view->message_label); - -+ if (view->background_image != NULL) -+ ply_image_free (view->background_image); -+ - free (view); - } - - static bool - view_load (view_t *view) - { -+ unsigned long screen_width, screen_height; -+ ply_boot_splash_plugin_t *plugin; -+ -+ plugin = view->plugin; -+ -+ screen_width = ply_pixel_display_get_width (view->display); -+ screen_height = ply_pixel_display_get_height (view->display); -+ -+ if (plugin->background_tile_image != NULL) -+ { -+ ply_trace ("tiling background to %lux%lu", screen_width, screen_height); -+ view->background_image = ply_image_tile (plugin->background_tile_image, screen_width, screen_height); -+ } -+ - ply_trace ("loading entry"); - if (!ply_entry_load (view->entry)) - return false; - - ply_trace ("loading animation"); - if (!ply_animation_load (view->end_animation)) - { - ply_trace ("Default animation wouldn't load, " - "falling back to old naming scheme"); - - /* fallback to throbber- for compatibility - */ - ply_animation_free (view->end_animation); - view->end_animation = ply_animation_new (view->plugin->animation_dir, - "throbber-"); - if (!ply_animation_load (view->end_animation)) - { - ply_trace ("old naming scheme didn't work either"); - return false; - } - - ply_throbber_free (view->throbber); - view->throbber = NULL; - } - - ply_trace ("loading progress animation"); - if (!ply_progress_animation_load (view->progress_animation)) - { - ply_trace ("optional progress animation wouldn't load"); - ply_progress_animation_free (view->progress_animation); -@@ -492,60 +511,66 @@ create_plugin (ply_key_file_t *key_file) - char *image_dir, *image_path; - char *alignment; - char *transition; - char *transition_duration; - char *color; - char *progress_function; - - srand ((int) ply_get_timestamp ()); - plugin = calloc (1, sizeof (ply_boot_splash_plugin_t)); - - image_dir = ply_key_file_get_value (key_file, "two-step", "ImageDir"); - - ply_trace ("Using '%s' as working directory", image_dir); - - asprintf (&image_path, "%s/lock.png", image_dir); - plugin->lock_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/box.png", image_dir); - plugin->box_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/corner-image.png", image_dir); - plugin->corner_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/header-image.png", image_dir); - plugin->header_image = ply_image_new (image_path); - free (image_path); - -+ asprintf (&image_path, "%s/background-tile.png", image_dir); -+ plugin->background_tile_image = ply_image_new (image_path); -+ -+ ply_trace ("loading background tile %s", image_path); -+ free (image_path); -+ - plugin->animation_dir = image_dir; - - alignment = ply_key_file_get_value (key_file, "two-step", "HorizontalAlignment"); - if (alignment != NULL) - plugin->animation_horizontal_alignment = strtod (alignment, NULL); - else - plugin->animation_horizontal_alignment = .5; - free (alignment); - - alignment = ply_key_file_get_value (key_file, "two-step", "VerticalAlignment"); - if (alignment != NULL) - plugin->animation_vertical_alignment = strtod (alignment, NULL); - else - plugin->animation_vertical_alignment = .5; - free (alignment); - - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_NONE; - transition = ply_key_file_get_value (key_file, "two-step", "Transition"); - if (transition != NULL) - { - if (strcmp (transition, "fade-over") == 0) - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_FADE_OVER; - else if (strcmp (transition, "cross-fade") == 0) - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_CROSS_FADE; - else if (strcmp (transition, "merge-fade") == 0) - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_MERGE_FADE; - } - free (transition); - - transition_duration = ply_key_file_get_value (key_file, "two-step", "TransitionDuration"); -@@ -626,60 +651,63 @@ free_views (ply_boot_splash_plugin_t *plugin) - plugin->views = NULL; - } - - static void - destroy_plugin (ply_boot_splash_plugin_t *plugin) - { - if (plugin == NULL) - return; - - ply_trace ("destroying plugin"); - - if (plugin->loop != NULL) - { - stop_animation (plugin, NULL); - - ply_event_loop_stop_watching_for_exit (plugin->loop, (ply_event_loop_exit_handler_t) - detach_from_event_loop, - plugin); - detach_from_event_loop (plugin); - } - - ply_image_free (plugin->box_image); - ply_image_free (plugin->lock_image); - - if (plugin->corner_image != NULL) - ply_image_free (plugin->corner_image); - - if (plugin->header_image != NULL) - ply_image_free (plugin->header_image); - -+ if (plugin->background_tile_image != NULL) -+ ply_image_free (plugin->background_tile_image); -+ - free (plugin->animation_dir); - free_views (plugin); - free (plugin); - } - - static void - start_end_animation (ply_boot_splash_plugin_t *plugin, - ply_trigger_t *trigger) - { - ply_trace ("starting end animation"); - - ply_list_node_t *node; - - node = ply_list_get_first_node (plugin->views); - while (node != NULL) - { - ply_list_node_t *next_node; - view_t *view; - ply_trigger_t *throbber_trigger; - - view = ply_list_node_get_data (node); - next_node = ply_list_get_next_node (plugin->views, node); - - ply_trigger_ignore_next_pull (trigger); - - if (view->throbber != NULL) - { - ply_trace ("stopping throbber"); - view->end_trigger = trigger; - throbber_trigger = ply_trigger_new (NULL); -@@ -786,60 +814,67 @@ static void - detach_from_event_loop (ply_boot_splash_plugin_t *plugin) - { - plugin->loop = NULL; - } - - static void - draw_background (view_t *view, - ply_pixel_buffer_t *pixel_buffer, - int x, - int y, - int width, - int height) - { - ply_boot_splash_plugin_t *plugin; - ply_rectangle_t area; - - plugin = view->plugin; - - area.x = x; - area.y = y; - area.width = width; - area.height = height; - - if (plugin->background_start_color != plugin->background_end_color) - ply_pixel_buffer_fill_with_gradient (pixel_buffer, &area, - plugin->background_start_color, - plugin->background_end_color); - else - ply_pixel_buffer_fill_with_hex_color (pixel_buffer, &area, - plugin->background_start_color); -+ -+ if (view->background_image != NULL) -+ { -+ uint32_t *data; -+ data = ply_image_get_data (view->background_image); -+ ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, &area, data); -+ } - } - - static void - on_draw (view_t *view, - ply_pixel_buffer_t *pixel_buffer, - int x, - int y, - int width, - int height) - { - ply_boot_splash_plugin_t *plugin; - ply_rectangle_t screen_area; - ply_rectangle_t image_area; - - plugin = view->plugin; - - draw_background (view, pixel_buffer, x, y, width, height); - - ply_pixel_buffer_get_size (pixel_buffer, &screen_area); - - if (plugin->state == PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY || - plugin->state == PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY ) - { - uint32_t *box_data, *lock_data; - - box_data = ply_image_get_data (plugin->box_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, - &view->box_area, - box_data); - -@@ -970,60 +1005,70 @@ show_splash_screen (ply_boot_splash_plugin_t *plugin, - ply_trace ("loading lock image"); - if (!ply_image_load (plugin->lock_image)) - return false; - - ply_trace ("loading box image"); - if (!ply_image_load (plugin->box_image)) - return false; - - if (plugin->corner_image != NULL) - { - ply_trace ("loading corner image"); - - if (!ply_image_load (plugin->corner_image)) - { - ply_image_free (plugin->corner_image); - plugin->corner_image = NULL; - } - } - - if (plugin->header_image != NULL) - { - ply_trace ("loading header image"); - - if (!ply_image_load (plugin->header_image)) - { - ply_image_free (plugin->header_image); - plugin->header_image = NULL; - } - } - -+ if (plugin->background_tile_image != NULL) -+ { -+ ply_trace ("loading background tile image"); -+ if (!ply_image_load (plugin->background_tile_image)) -+ { -+ ply_image_free (plugin->background_tile_image); -+ plugin->background_tile_image = NULL; -+ } -+ } -+ - if (!load_views (plugin)) - { - ply_trace ("couldn't load views"); - return false; - } - - ply_event_loop_watch_for_exit (loop, (ply_event_loop_exit_handler_t) - detach_from_event_loop, - plugin); - - ply_trace ("starting boot animations"); - start_progress_animation (plugin); - - plugin->is_visible = true; - - return true; - } - - static void - update_status (ply_boot_splash_plugin_t *plugin, - const char *status) - { - assert (plugin != NULL); - } - - static void - on_animation_stopped (ply_boot_splash_plugin_t *plugin) - { - if (plugin->idle_trigger != NULL) - { --- -1.8.3.1 - - -From 454fee71c109bfef897d9e8655d594838cd8a99b Mon Sep 17 00:00:00 2001 -From: Ray Strode -Date: Thu, 24 Oct 2013 09:33:17 -0400 -Subject: [PATCH 4/5] two-step: add support for watermark - -The watermark is overlaid on top of the background but below all the -other content. ---- - src/plugins/splash/two-step/plugin.c | 53 +++++++++++++++++++++++++++++++++++- - 1 file changed, 52 insertions(+), 1 deletion(-) - -diff --git a/src/plugins/splash/two-step/plugin.c b/src/plugins/splash/two-step/plugin.c -index 2c6d97a..5cf333f 100644 ---- a/src/plugins/splash/two-step/plugin.c -+++ b/src/plugins/splash/two-step/plugin.c -@@ -62,78 +62,82 @@ - - #ifndef FRAMES_PER_SECOND - #define FRAMES_PER_SECOND 30 - #endif - - #ifndef SHOW_ANIMATION_PERCENT - #define SHOW_ANIMATION_PERCENT 0.9 - #endif - - typedef enum { - PLY_BOOT_SPLASH_DISPLAY_NORMAL, - PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY, - PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY - } ply_boot_splash_display_type_t; - - typedef enum { - PROGRESS_FUNCTION_TYPE_WWOODS, - PROGRESS_FUNCTION_TYPE_LINEAR, - } progress_function_t; - - typedef struct - { - ply_boot_splash_plugin_t *plugin; - ply_pixel_display_t *display; - ply_entry_t *entry; - ply_animation_t *end_animation; - ply_progress_animation_t *progress_animation; - ply_throbber_t *throbber; - ply_label_t *label; - ply_label_t *message_label; -- ply_rectangle_t box_area, lock_area; -+ ply_rectangle_t box_area, lock_area, watermark_area; - ply_trigger_t *end_trigger; - ply_image_t *background_image; - } view_t; - - struct _ply_boot_splash_plugin - { - ply_event_loop_t *loop; - ply_boot_splash_mode_t mode; - ply_image_t *lock_image; - ply_image_t *box_image; - ply_image_t *corner_image; - ply_image_t *header_image; - ply_image_t *background_tile_image; -+ ply_image_t *watermark_image; - ply_list_t *views; - - ply_boot_splash_display_type_t state; - -+ double watermark_horizontal_alignment; -+ double watermark_vertical_alignment; -+ - double animation_horizontal_alignment; - double animation_vertical_alignment; - char *animation_dir; - - ply_progress_animation_transition_t transition; - double transition_duration; - - uint32_t background_start_color; - uint32_t background_end_color; - - progress_function_t progress_function; - - ply_trigger_t *idle_trigger; - ply_trigger_t *stop_trigger; - - uint32_t root_is_mounted : 1; - uint32_t is_visible : 1; - uint32_t is_animating : 1; - uint32_t is_idle : 1; - }; - - ply_boot_splash_plugin_interface_t * ply_boot_splash_plugin_get_interface (void); - - static void stop_animation (ply_boot_splash_plugin_t *plugin, - ply_trigger_t *idle_trigger); - - static void detach_from_event_loop (ply_boot_splash_plugin_t *plugin); - static void display_message (ply_boot_splash_plugin_t *plugin, - const char *message); - static void become_idle (ply_boot_splash_plugin_t *plugin, -@@ -174,60 +178,68 @@ view_free (view_t *view) - ply_entry_free (view->entry); - ply_animation_free (view->end_animation); - ply_progress_animation_free (view->progress_animation); - ply_throbber_free (view->throbber); - ply_label_free (view->label); - ply_label_free (view->message_label); - - if (view->background_image != NULL) - ply_image_free (view->background_image); - - free (view); - } - - static bool - view_load (view_t *view) - { - unsigned long screen_width, screen_height; - ply_boot_splash_plugin_t *plugin; - - plugin = view->plugin; - - screen_width = ply_pixel_display_get_width (view->display); - screen_height = ply_pixel_display_get_height (view->display); - - if (plugin->background_tile_image != NULL) - { - ply_trace ("tiling background to %lux%lu", screen_width, screen_height); - view->background_image = ply_image_tile (plugin->background_tile_image, screen_width, screen_height); - } - -+ if (plugin->watermark_image != NULL) -+ { -+ view->watermark_area.width = ply_image_get_width (plugin->watermark_image); -+ view->watermark_area.height = ply_image_get_height (plugin->watermark_image); -+ view->watermark_area.x = screen_width * plugin->watermark_horizontal_alignment - ply_image_get_width (plugin->watermark_image) * plugin->watermark_horizontal_alignment; -+ view->watermark_area.y = screen_height * plugin->watermark_vertical_alignment - ply_image_get_height (plugin->watermark_image) * plugin->watermark_vertical_alignment; -+ } -+ - ply_trace ("loading entry"); - if (!ply_entry_load (view->entry)) - return false; - - ply_trace ("loading animation"); - if (!ply_animation_load (view->end_animation)) - { - ply_trace ("Default animation wouldn't load, " - "falling back to old naming scheme"); - - /* fallback to throbber- for compatibility - */ - ply_animation_free (view->end_animation); - view->end_animation = ply_animation_new (view->plugin->animation_dir, - "throbber-"); - if (!ply_animation_load (view->end_animation)) - { - ply_trace ("old naming scheme didn't work either"); - return false; - } - - ply_throbber_free (view->throbber); - view->throbber = NULL; - } - - ply_trace ("loading progress animation"); - if (!ply_progress_animation_load (view->progress_animation)) - { - ply_trace ("optional progress animation wouldn't load"); - ply_progress_animation_free (view->progress_animation); -@@ -517,76 +529,94 @@ create_plugin (ply_key_file_t *key_file) - - srand ((int) ply_get_timestamp ()); - plugin = calloc (1, sizeof (ply_boot_splash_plugin_t)); - - image_dir = ply_key_file_get_value (key_file, "two-step", "ImageDir"); - - ply_trace ("Using '%s' as working directory", image_dir); - - asprintf (&image_path, "%s/lock.png", image_dir); - plugin->lock_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/box.png", image_dir); - plugin->box_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/corner-image.png", image_dir); - plugin->corner_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/header-image.png", image_dir); - plugin->header_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/background-tile.png", image_dir); - plugin->background_tile_image = ply_image_new (image_path); - - ply_trace ("loading background tile %s", image_path); - free (image_path); - -+ asprintf (&image_path, "%s/watermark.png", image_dir); -+ plugin->watermark_image = ply_image_new (image_path); -+ free (image_path); -+ - plugin->animation_dir = image_dir; - - alignment = ply_key_file_get_value (key_file, "two-step", "HorizontalAlignment"); - if (alignment != NULL) - plugin->animation_horizontal_alignment = strtod (alignment, NULL); - else - plugin->animation_horizontal_alignment = .5; - free (alignment); - - alignment = ply_key_file_get_value (key_file, "two-step", "VerticalAlignment"); - if (alignment != NULL) - plugin->animation_vertical_alignment = strtod (alignment, NULL); - else - plugin->animation_vertical_alignment = .5; - free (alignment); - -+ alignment = ply_key_file_get_value (key_file, "two-step", "WatermarkHorizontalAlignment"); -+ if (alignment != NULL) -+ plugin->watermark_horizontal_alignment = strtod (alignment, NULL); -+ else -+ plugin->watermark_horizontal_alignment = 1.0; -+ free (alignment); -+ -+ alignment = ply_key_file_get_value (key_file, "two-step", "WatermarkVerticalAlignment"); -+ if (alignment != NULL) -+ plugin->watermark_vertical_alignment = strtod (alignment, NULL); -+ else -+ plugin->watermark_vertical_alignment = .5; -+ free (alignment); -+ - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_NONE; - transition = ply_key_file_get_value (key_file, "two-step", "Transition"); - if (transition != NULL) - { - if (strcmp (transition, "fade-over") == 0) - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_FADE_OVER; - else if (strcmp (transition, "cross-fade") == 0) - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_CROSS_FADE; - else if (strcmp (transition, "merge-fade") == 0) - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_MERGE_FADE; - } - free (transition); - - transition_duration = ply_key_file_get_value (key_file, "two-step", "TransitionDuration"); - if (transition_duration != NULL) - plugin->transition_duration = strtod (transition_duration, NULL); - else - plugin->transition_duration = 0.0; - free (transition_duration); - - color = ply_key_file_get_value (key_file, "two-step", "BackgroundStartColor"); - - if (color != NULL) - plugin->background_start_color = strtol (color, NULL, 0); - else - plugin->background_start_color = PLYMOUTH_BACKGROUND_START_COLOR; - - free (color); - - color = ply_key_file_get_value (key_file, "two-step", "BackgroundEndColor"); -@@ -654,60 +684,63 @@ free_views (ply_boot_splash_plugin_t *plugin) - static void - destroy_plugin (ply_boot_splash_plugin_t *plugin) - { - if (plugin == NULL) - return; - - ply_trace ("destroying plugin"); - - if (plugin->loop != NULL) - { - stop_animation (plugin, NULL); - - ply_event_loop_stop_watching_for_exit (plugin->loop, (ply_event_loop_exit_handler_t) - detach_from_event_loop, - plugin); - detach_from_event_loop (plugin); - } - - ply_image_free (plugin->box_image); - ply_image_free (plugin->lock_image); - - if (plugin->corner_image != NULL) - ply_image_free (plugin->corner_image); - - if (plugin->header_image != NULL) - ply_image_free (plugin->header_image); - - if (plugin->background_tile_image != NULL) - ply_image_free (plugin->background_tile_image); - -+ if (plugin->watermark_image != NULL) -+ ply_image_free (plugin->watermark_image); -+ - free (plugin->animation_dir); - free_views (plugin); - free (plugin); - } - - static void - start_end_animation (ply_boot_splash_plugin_t *plugin, - ply_trigger_t *trigger) - { - ply_trace ("starting end animation"); - - ply_list_node_t *node; - - node = ply_list_get_first_node (plugin->views); - while (node != NULL) - { - ply_list_node_t *next_node; - view_t *view; - ply_trigger_t *throbber_trigger; - - view = ply_list_node_get_data (node); - next_node = ply_list_get_next_node (plugin->views, node); - - ply_trigger_ignore_next_pull (trigger); - - if (view->throbber != NULL) - { - ply_trace ("stopping throbber"); - view->end_trigger = trigger; - throbber_trigger = ply_trigger_new (NULL); -@@ -821,60 +854,68 @@ draw_background (view_t *view, - ply_pixel_buffer_t *pixel_buffer, - int x, - int y, - int width, - int height) - { - ply_boot_splash_plugin_t *plugin; - ply_rectangle_t area; - - plugin = view->plugin; - - area.x = x; - area.y = y; - area.width = width; - area.height = height; - - if (plugin->background_start_color != plugin->background_end_color) - ply_pixel_buffer_fill_with_gradient (pixel_buffer, &area, - plugin->background_start_color, - plugin->background_end_color); - else - ply_pixel_buffer_fill_with_hex_color (pixel_buffer, &area, - plugin->background_start_color); - - if (view->background_image != NULL) - { - uint32_t *data; - data = ply_image_get_data (view->background_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, &area, data); - } -+ -+ if (plugin->watermark_image != NULL) -+ { -+ uint32_t *data; -+ -+ data = ply_image_get_data (plugin->watermark_image); -+ ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, &view->watermark_area, data); -+ } - } - - static void - on_draw (view_t *view, - ply_pixel_buffer_t *pixel_buffer, - int x, - int y, - int width, - int height) - { - ply_boot_splash_plugin_t *plugin; - ply_rectangle_t screen_area; - ply_rectangle_t image_area; - - plugin = view->plugin; - - draw_background (view, pixel_buffer, x, y, width, height); - - ply_pixel_buffer_get_size (pixel_buffer, &screen_area); - - if (plugin->state == PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY || - plugin->state == PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY ) - { - uint32_t *box_data, *lock_data; - - box_data = ply_image_get_data (plugin->box_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, - &view->box_area, - box_data); - -@@ -1015,60 +1056,70 @@ show_splash_screen (ply_boot_splash_plugin_t *plugin, - ply_trace ("loading corner image"); - - if (!ply_image_load (plugin->corner_image)) - { - ply_image_free (plugin->corner_image); - plugin->corner_image = NULL; - } - } - - if (plugin->header_image != NULL) - { - ply_trace ("loading header image"); - - if (!ply_image_load (plugin->header_image)) - { - ply_image_free (plugin->header_image); - plugin->header_image = NULL; - } - } - - if (plugin->background_tile_image != NULL) - { - ply_trace ("loading background tile image"); - if (!ply_image_load (plugin->background_tile_image)) - { - ply_image_free (plugin->background_tile_image); - plugin->background_tile_image = NULL; - } - } - -+ if (plugin->watermark_image != NULL) -+ { -+ ply_trace ("loading watermark image"); -+ if (!ply_image_load (plugin->watermark_image)) -+ { -+ ply_image_free (plugin->watermark_image); -+ plugin->watermark_image = NULL; -+ } -+ } -+ - if (!load_views (plugin)) - { - ply_trace ("couldn't load views"); - return false; - } - - ply_event_loop_watch_for_exit (loop, (ply_event_loop_exit_handler_t) - detach_from_event_loop, - plugin); - - ply_trace ("starting boot animations"); - start_progress_animation (plugin); - - plugin->is_visible = true; - - return true; - } - - static void - update_status (ply_boot_splash_plugin_t *plugin, - const char *status) - { - assert (plugin != NULL); - } - - static void - on_animation_stopped (ply_boot_splash_plugin_t *plugin) - { - if (plugin->idle_trigger != NULL) - { --- -1.8.3.1 - - -From 2ce951c56b4ffa26803072789a6f8d16e4cdca3a Mon Sep 17 00:00:00 2001 -From: Ray Strode -Date: Fri, 25 Oct 2013 16:24:47 -0400 -Subject: [PATCH 5/5] two-step: introduce delayed startup - -Many machines these days can boot in 5 seconds or less. -In those cases, there's little point in showing a boot splash. - -This commit introduces a StartupDelay option to the two step -plugin to prevent it from displaying anything for a few seconds. ---- - src/plugins/splash/two-step/plugin.c | 45 ++++++++++++++++++++++++++++++++++++ - 1 file changed, 45 insertions(+) - -diff --git a/src/plugins/splash/two-step/plugin.c b/src/plugins/splash/two-step/plugin.c -index 5cf333f..fff928c 100644 ---- a/src/plugins/splash/two-step/plugin.c -+++ b/src/plugins/splash/two-step/plugin.c -@@ -65,135 +65,141 @@ - #endif - - #ifndef SHOW_ANIMATION_PERCENT - #define SHOW_ANIMATION_PERCENT 0.9 - #endif - - typedef enum { - PLY_BOOT_SPLASH_DISPLAY_NORMAL, - PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY, - PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY - } ply_boot_splash_display_type_t; - - typedef enum { - PROGRESS_FUNCTION_TYPE_WWOODS, - PROGRESS_FUNCTION_TYPE_LINEAR, - } progress_function_t; - - typedef struct - { - ply_boot_splash_plugin_t *plugin; - ply_pixel_display_t *display; - ply_entry_t *entry; - ply_animation_t *end_animation; - ply_progress_animation_t *progress_animation; - ply_throbber_t *throbber; - ply_label_t *label; - ply_label_t *message_label; - ply_rectangle_t box_area, lock_area, watermark_area; - ply_trigger_t *end_trigger; - ply_image_t *background_image; -+ -+ uint32_t is_blank : 1; - } view_t; - - struct _ply_boot_splash_plugin - { - ply_event_loop_t *loop; - ply_boot_splash_mode_t mode; - ply_image_t *lock_image; - ply_image_t *box_image; - ply_image_t *corner_image; - ply_image_t *header_image; - ply_image_t *background_tile_image; - ply_image_t *watermark_image; - ply_list_t *views; - - ply_boot_splash_display_type_t state; - - double watermark_horizontal_alignment; - double watermark_vertical_alignment; - - double animation_horizontal_alignment; - double animation_vertical_alignment; - char *animation_dir; - - ply_progress_animation_transition_t transition; - double transition_duration; - - uint32_t background_start_color; - uint32_t background_end_color; - - progress_function_t progress_function; - - ply_trigger_t *idle_trigger; - ply_trigger_t *stop_trigger; - -+ double start_time; -+ double startup_delay; -+ - uint32_t root_is_mounted : 1; - uint32_t is_visible : 1; - uint32_t is_animating : 1; - uint32_t is_idle : 1; - }; - - ply_boot_splash_plugin_interface_t * ply_boot_splash_plugin_get_interface (void); - - static void stop_animation (ply_boot_splash_plugin_t *plugin, - ply_trigger_t *idle_trigger); - - static void detach_from_event_loop (ply_boot_splash_plugin_t *plugin); - static void display_message (ply_boot_splash_plugin_t *plugin, - const char *message); - static void become_idle (ply_boot_splash_plugin_t *plugin, - ply_trigger_t *idle_trigger); - - static view_t * - view_new (ply_boot_splash_plugin_t *plugin, - ply_pixel_display_t *display) - { - view_t *view; - - view = calloc (1, sizeof (view_t)); - view->plugin = plugin; - view->display = display; - - view->entry = ply_entry_new (plugin->animation_dir); - view->end_animation = ply_animation_new (plugin->animation_dir, - "animation-"); - view->progress_animation = ply_progress_animation_new (plugin->animation_dir, - "progress-"); - - view->throbber = ply_throbber_new (plugin->animation_dir, - "throbber-"); - ply_progress_animation_set_transition (view->progress_animation, - plugin->transition, - plugin->transition_duration); - - view->label = ply_label_new (); - view->message_label = ply_label_new (); -+ view->is_blank = true; - - return view; - } - - static void - view_free (view_t *view) - { - - ply_entry_free (view->entry); - ply_animation_free (view->end_animation); - ply_progress_animation_free (view->progress_animation); - ply_throbber_free (view->throbber); - ply_label_free (view->label); - ply_label_free (view->message_label); - - if (view->background_image != NULL) - ply_image_free (view->background_image); - - free (view); - } - - static bool - view_load (view_t *view) - { - unsigned long screen_width, screen_height; - ply_boot_splash_plugin_t *plugin; - - plugin = view->plugin; - - screen_width = ply_pixel_display_get_width (view->display); -@@ -494,101 +500,111 @@ view_show_prompt (view_t *view, - if (prompt != NULL) - { - ply_label_set_text (view->label, prompt); - - /* We center the prompt in the middle and use 80% of the horizontal space */ - int label_width = screen_width * 100 / 80; - ply_label_set_alignment (view->label, PLY_LABEL_ALIGN_CENTER); - ply_label_set_width (view->label, label_width); - - x = (screen_width - label_width) / 2; - y = view->box_area.y + view->box_area.height; - - ply_label_show (view->label, view->display, x, y); - } - } - - static void - view_hide_prompt (view_t *view) - { - assert (view != NULL); - - ply_entry_hide (view->entry); - ply_label_hide (view->label); - } - - static ply_boot_splash_plugin_t * - create_plugin (ply_key_file_t *key_file) - { - ply_boot_splash_plugin_t *plugin; - char *image_dir, *image_path; -+ char *startup_delay; - char *alignment; - char *transition; - char *transition_duration; - char *color; - char *progress_function; - - srand ((int) ply_get_timestamp ()); - plugin = calloc (1, sizeof (ply_boot_splash_plugin_t)); - -+ plugin->start_time = ply_get_timestamp (); -+ - image_dir = ply_key_file_get_value (key_file, "two-step", "ImageDir"); - - ply_trace ("Using '%s' as working directory", image_dir); - - asprintf (&image_path, "%s/lock.png", image_dir); - plugin->lock_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/box.png", image_dir); - plugin->box_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/corner-image.png", image_dir); - plugin->corner_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/header-image.png", image_dir); - plugin->header_image = ply_image_new (image_path); - free (image_path); - - asprintf (&image_path, "%s/background-tile.png", image_dir); - plugin->background_tile_image = ply_image_new (image_path); - - ply_trace ("loading background tile %s", image_path); - free (image_path); - - asprintf (&image_path, "%s/watermark.png", image_dir); - plugin->watermark_image = ply_image_new (image_path); - free (image_path); - - plugin->animation_dir = image_dir; - -+ startup_delay = ply_key_file_get_value (key_file, "two-step", "StartupDelay"); -+ if (startup_delay != NULL) -+ plugin->startup_delay = strtod (startup_delay, NULL); -+ else -+ plugin->startup_delay = 5.0; -+ free (startup_delay); -+ - alignment = ply_key_file_get_value (key_file, "two-step", "HorizontalAlignment"); - if (alignment != NULL) - plugin->animation_horizontal_alignment = strtod (alignment, NULL); - else - plugin->animation_horizontal_alignment = .5; - free (alignment); - - alignment = ply_key_file_get_value (key_file, "two-step", "VerticalAlignment"); - if (alignment != NULL) - plugin->animation_vertical_alignment = strtod (alignment, NULL); - else - plugin->animation_vertical_alignment = .5; - free (alignment); - - alignment = ply_key_file_get_value (key_file, "two-step", "WatermarkHorizontalAlignment"); - if (alignment != NULL) - plugin->watermark_horizontal_alignment = strtod (alignment, NULL); - else - plugin->watermark_horizontal_alignment = 1.0; - free (alignment); - - alignment = ply_key_file_get_value (key_file, "two-step", "WatermarkVerticalAlignment"); - if (alignment != NULL) - plugin->watermark_vertical_alignment = strtod (alignment, NULL); - else - plugin->watermark_vertical_alignment = .5; - free (alignment); - - plugin->transition = PLY_PROGRESS_ANIMATION_TRANSITION_NONE; - transition = ply_key_file_get_value (key_file, "two-step", "Transition"); -@@ -878,60 +894,89 @@ draw_background (view_t *view, - if (view->background_image != NULL) - { - uint32_t *data; - data = ply_image_get_data (view->background_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, &area, data); - } - - if (plugin->watermark_image != NULL) - { - uint32_t *data; - - data = ply_image_get_data (plugin->watermark_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, &view->watermark_area, data); - } - } - - static void - on_draw (view_t *view, - ply_pixel_buffer_t *pixel_buffer, - int x, - int y, - int width, - int height) - { - ply_boot_splash_plugin_t *plugin; - ply_rectangle_t screen_area; - ply_rectangle_t image_area; - - plugin = view->plugin; - -+ if (plugin->mode == PLY_BOOT_SPLASH_MODE_BOOT_UP) -+ { -+ double now; -+ -+ now = ply_get_timestamp (); -+ -+ if (now - plugin->start_time < plugin->startup_delay) -+ return; -+ -+ if (view->is_blank) -+ { -+ ply_rectangle_t clip_area; -+ -+ x = 0; -+ y = 0; -+ width = ply_pixel_display_get_width (view->display); -+ height = ply_pixel_display_get_height (view->display); -+ -+ clip_area.x = 0; -+ clip_area.y = 0; -+ clip_area.width = width; -+ clip_area.height = height; -+ ply_pixel_buffer_pop_clip_area (pixel_buffer); -+ ply_pixel_buffer_push_clip_area (pixel_buffer, -+ &clip_area); -+ view->is_blank = false; -+ } -+ } -+ - draw_background (view, pixel_buffer, x, y, width, height); - - ply_pixel_buffer_get_size (pixel_buffer, &screen_area); - - if (plugin->state == PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY || - plugin->state == PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY ) - { - uint32_t *box_data, *lock_data; - - box_data = ply_image_get_data (plugin->box_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, - &view->box_area, - box_data); - - ply_entry_draw_area (view->entry, - pixel_buffer, - x, y, width, height); - ply_label_draw_area (view->label, - pixel_buffer, - x, y, width, height); - - lock_data = ply_image_get_data (plugin->lock_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, - &view->lock_area, - lock_data); - } - else - { - if (view->throbber != NULL && - !ply_throbber_is_stopped (view->throbber)) --- -1.8.3.1 - -From ba50f9e79da79d42ed7f50798b955ef929819daf Mon Sep 17 00:00:00 2001 -From: Ray Strode -Date: Fri, 8 Nov 2013 08:31:32 -0500 -Subject: [PATCH] two-step: fix unlock screen - -The previous commit introduced a bug where the unlock screen won't -get shown if it's requested within the first 5 seconds of startup. - -This commit fixes that by forcing a redraw if the state switches from -NORMAL. ---- - src/plugins/splash/two-step/plugin.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/src/plugins/splash/two-step/plugin.c b/src/plugins/splash/two-step/plugin.c -index fff928c..eaf20b3 100644 ---- a/src/plugins/splash/two-step/plugin.c -+++ b/src/plugins/splash/two-step/plugin.c -@@ -900,61 +900,62 @@ draw_background (view_t *view, - - if (plugin->watermark_image != NULL) - { - uint32_t *data; - - data = ply_image_get_data (plugin->watermark_image); - ply_pixel_buffer_fill_with_argb32_data (pixel_buffer, &view->watermark_area, data); - } - } - - static void - on_draw (view_t *view, - ply_pixel_buffer_t *pixel_buffer, - int x, - int y, - int width, - int height) - { - ply_boot_splash_plugin_t *plugin; - ply_rectangle_t screen_area; - ply_rectangle_t image_area; - - plugin = view->plugin; - - if (plugin->mode == PLY_BOOT_SPLASH_MODE_BOOT_UP) - { - double now; - - now = ply_get_timestamp (); - -- if (now - plugin->start_time < plugin->startup_delay) -+ if ((now - plugin->start_time < plugin->startup_delay) && -+ plugin->state == PLY_BOOT_SPLASH_DISPLAY_NORMAL) - return; - - if (view->is_blank) - { - ply_rectangle_t clip_area; - - x = 0; - y = 0; - width = ply_pixel_display_get_width (view->display); - height = ply_pixel_display_get_height (view->display); - - clip_area.x = 0; - clip_area.y = 0; - clip_area.width = width; - clip_area.height = height; - ply_pixel_buffer_pop_clip_area (pixel_buffer); - ply_pixel_buffer_push_clip_area (pixel_buffer, - &clip_area); - view->is_blank = false; - } - } - - draw_background (view, pixel_buffer, x, y, width, height); - - ply_pixel_buffer_get_size (pixel_buffer, &screen_area); - - if (plugin->state == PLY_BOOT_SPLASH_DISPLAY_QUESTION_ENTRY || - plugin->state == PLY_BOOT_SPLASH_DISPLAY_PASSWORD_ENTRY ) - { - uint32_t *box_data, *lock_data; --- -1.8.3.1 - diff --git a/SOURCES/always-add-text-splash.patch b/SOURCES/always-add-text-splash.patch new file mode 100644 index 0000000..bd4298e --- /dev/null +++ b/SOURCES/always-add-text-splash.patch @@ -0,0 +1,86 @@ +From ccff8a426babb9a34e64b0024ce4d651c1ca25e5 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Fri, 17 Jan 2014 12:51:24 -0500 +Subject: [PATCH] seat: always add text displays when opening seat + +At the moment we add pixel displays if we can, or +text displays if we can't add pixel displays. + +We need to always add text displays, otherwise, the +text splash won't work when explicitly configured by +the user. +--- + src/libply-splash-core/ply-seat.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/libply-splash-core/ply-seat.c b/src/libply-splash-core/ply-seat.c +index 0900346..d9c7a2b 100644 +--- a/src/libply-splash-core/ply-seat.c ++++ b/src/libply-splash-core/ply-seat.c +@@ -110,62 +110,62 @@ bool + ply_seat_open (ply_seat_t *seat, + ply_renderer_type_t renderer_type, + const char *device) + { + if (renderer_type != PLY_RENDERER_TYPE_NONE) + { + ply_renderer_t *renderer; + + renderer = ply_renderer_new (renderer_type, device, seat->terminal); + + if (!ply_renderer_open (renderer) && renderer_type != PLY_RENDERER_TYPE_AUTO) + { + ply_trace ("could not open renderer for %s", device); + ply_renderer_free (renderer); + return false; + } + + seat->renderer = renderer; + seat->renderer_active = true; + } + + if (seat->renderer != NULL) + { + seat->keyboard = ply_keyboard_new_for_renderer (seat->renderer); + add_pixel_displays (seat); + + } + else + { + seat->keyboard = ply_keyboard_new_for_terminal (seat->terminal); +- add_text_displays (seat); + } ++ add_text_displays (seat); + + ply_keyboard_watch_for_input (seat->keyboard); + seat->keyboard_active = true; + + return true; + } + + bool + ply_seat_is_open (ply_seat_t *seat) + { + return ply_list_get_length (seat->pixel_displays) > 0 || + ply_list_get_length (seat->text_displays) > 0; + } + + void + ply_seat_deactivate_keyboard (ply_seat_t *seat) + { + if (!seat->keyboard_active) + return; + + seat->keyboard_active = false; + + if (seat->keyboard == NULL) + return; + + ply_trace ("deactivating keybord"); + ply_keyboard_stop_watching_for_input (seat->keyboard); + } + + void +-- +1.8.3.1 + diff --git a/SOURCES/charge.plymouth b/SOURCES/charge.plymouth index fb1306b..801058b 100644 --- a/SOURCES/charge.plymouth +++ b/SOURCES/charge.plymouth @@ -1,6 +1,6 @@ [Plymouth Theme] Name=Charge -Description=A theme that features the shadowy hull of a Fedora logo charge up and and finally burst into into full form. +Description=A theme that features a spinner and subtle watermark. The Red Hat Enterprise Linux default theme. ModuleName=two-step [two-step] diff --git a/SOURCES/colors.patch b/SOURCES/colors.patch index 1c8ada5..149d164 100644 --- a/SOURCES/colors.patch +++ b/SOURCES/colors.patch @@ -1,6 +1,6 @@ -diff -up plymouth-0.8.4/src/plugins/splash/text/plugin.c.colors plymouth-0.8.4/src/plugins/splash/text/plugin.c ---- plymouth-0.8.4/src/plugins/splash/text/plugin.c.colors 2012-03-20 11:26:05.343149459 -0400 -+++ plymouth-0.8.4/src/plugins/splash/text/plugin.c 2012-03-20 11:26:41.943521354 -0400 +diff -up plymouth-0.8.4/src/plugins/splash/tribar/plugin.c.colors plymouth-0.8.4/src/plugins/splash/text/plugin.c +--- plymouth-0.8.4/src/plugins/splash/tribar/plugin.c.colors 2012-03-20 11:26:05.343149459 -0400 ++++ plymouth-0.8.4/src/plugins/splash/tribar/plugin.c 2012-03-20 11:26:41.943521354 -0400 @@ -183,10 +183,10 @@ view_start_animation (view_t *view) 0xffffff); ply_terminal_set_color_hex_value (terminal, diff --git a/SOURCES/dont-block-show-splash.patch b/SOURCES/dont-block-show-splash.patch new file mode 100644 index 0000000..8f34363 --- /dev/null +++ b/SOURCES/dont-block-show-splash.patch @@ -0,0 +1,575 @@ +From a54df38f86a534b28c1b664bc283e9b8d17be8a1 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 16 Jan 2014 15:44:50 -0500 +Subject: [PATCH 1/2] main: don't rely on show_trigger to cancel show delay + +We're going to be getting rid of show_trigger in a subsequent +commit, so this commit changes the code to use the is_shown +flag instead. +--- + src/main.c | 29 ++++++++++++++++------------- + 1 file changed, 16 insertions(+), 13 deletions(-) + +diff --git a/src/main.c b/src/main.c +index bbd74f9..d9032a5 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -482,74 +482,77 @@ show_default_splash (state_t *state) + + static void + cancel_pending_delayed_show (state_t *state) + { + bool has_open_seats; + + if (isnan (state->splash_delay)) + return; + + ply_event_loop_stop_watching_for_timeout (state->loop, + (ply_event_loop_timeout_handler_t) + show_splash, + state); + state->splash_delay = NAN; + has_open_seats = ply_device_manager_has_open_seats (state->device_manager); + + if (state->is_shown && has_open_seats) + { + ply_trace ("splash delay cancelled, showing splash immediately"); + show_splash (state); + } + } + + static void + on_ask_for_password (state_t *state, + const char *prompt, + ply_trigger_t *answer) + { + ply_entry_trigger_t *entry_trigger; + +- /* Waiting to be shown, boot splash will +- * arrive shortly so just sit tight +- */ +- if (state->show_trigger != NULL) +- { +- ply_trace ("splash still coming up, waiting a bit"); +- cancel_pending_delayed_show (state); +- } +- else if (state->boot_splash == NULL) ++ if (state->boot_splash == NULL) + { +- /* No splash, client will have to get password */ +- ply_trace ("no splash loaded, replying immediately with no password"); +- ply_trigger_pull (answer, NULL); +- return; ++ /* Waiting to be shown, boot splash will ++ * arrive shortly so just sit tight ++ */ ++ if (state->is_shown) ++ { ++ ply_trace ("splash still coming up, waiting a bit"); ++ cancel_pending_delayed_show (state); ++ } ++ else ++ { ++ /* No splash, client will have to get password */ ++ ply_trace ("no splash loaded, replying immediately with no password"); ++ ply_trigger_pull (answer, NULL); ++ return; ++ } + } + + entry_trigger = calloc (1, sizeof (ply_entry_trigger_t)); + entry_trigger->type = PLY_ENTRY_TRIGGER_TYPE_PASSWORD; + entry_trigger->prompt = prompt; + entry_trigger->trigger = answer; + ply_trace ("queuing password request with boot splash"); + ply_list_append_data (state->entry_triggers, entry_trigger); + update_display (state); + } + + static void + on_ask_question (state_t *state, + const char *prompt, + ply_trigger_t *answer) + { + ply_entry_trigger_t *entry_trigger; + + entry_trigger = calloc (1, sizeof (ply_entry_trigger_t)); + entry_trigger->type = PLY_ENTRY_TRIGGER_TYPE_QUESTION; + entry_trigger->prompt = prompt; + entry_trigger->trigger = answer; + ply_trace ("queuing question with boot splash"); + ply_list_append_data (state->entry_triggers, entry_trigger); + update_display (state); + } + + static void + on_display_message (state_t *state, + const char *message) +-- +1.8.3.1 + + +From cdff09d1a2297501f294141182d8d8efcaf6fff3 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 16 Jan 2014 15:38:05 -0500 +Subject: [PATCH 2/2] Revert "boot-server: defer show-splash reply until splash + shown" + +This reverts commit 126345af8704a9b10481657d79d66cbea93e1647. + +If plymouth show-splash blocks until the splash screen is shown, +then systemd-ask-for-password-plymouth will block for 5 seconds +before asking for the password (which would have canceled the 5 +second delay if it weren't for the dependency on plymouth-start.service) +--- + src/main.c | 12 +----------- + src/ply-boot-server.c | 28 +--------------------------- + src/ply-boot-server.h | 1 - + 3 files changed, 2 insertions(+), 39 deletions(-) + +diff --git a/src/main.c b/src/main.c +index d9032a5..db1fd0a 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -74,61 +74,60 @@ typedef struct + const char *keys; + ply_trigger_t *trigger; + } ply_keystroke_watch_t; + + typedef struct + { + enum {PLY_ENTRY_TRIGGER_TYPE_PASSWORD, + PLY_ENTRY_TRIGGER_TYPE_QUESTION} + type; + const char *prompt; + ply_trigger_t *trigger; + } ply_entry_trigger_t; + + typedef struct + { + ply_event_loop_t *loop; + ply_boot_server_t *boot_server; + ply_boot_splash_t *boot_splash; + ply_terminal_session_t *session; + ply_buffer_t *boot_buffer; + ply_progress_t *progress; + ply_list_t *keystroke_triggers; + ply_list_t *entry_triggers; + ply_buffer_t *entry_buffer; + ply_list_t *messages; + ply_command_parser_t *command_parser; + ply_mode_t mode; + ply_terminal_t *local_console_terminal; + ply_device_manager_t *device_manager; + +- ply_trigger_t *show_trigger; + ply_trigger_t *deactivate_trigger; + ply_trigger_t *quit_trigger; + + double start_time; + double splash_delay; + + char kernel_command_line[PLY_MAX_COMMAND_LINE_SIZE]; + uint32_t kernel_command_line_is_set : 1; + uint32_t no_boot_log : 1; + uint32_t showing_details : 1; + uint32_t system_initialized : 1; + uint32_t is_redirected : 1; + uint32_t is_attached : 1; + uint32_t should_be_attached : 1; + uint32_t should_retain_splash : 1; + uint32_t is_inactive : 1; + uint32_t is_shown : 1; + uint32_t should_force_details : 1; + + char *override_splash_path; + char *system_default_splash_path; + char *distribution_default_splash_path; + const char *default_tty; + + int number_of_errors; + } state_t; + + static void show_splash (state_t *state); + static ply_boot_splash_t *load_built_in_theme (state_t *state); + static ply_boot_splash_t *load_theme (state_t *state, +@@ -848,85 +847,83 @@ plymouth_should_show_default_splash (state_t *state) + + if (command_line_has_argument (state->kernel_command_line, "splash=verbose")) + { + ply_trace ("no default splash because kernel command line has option \"splash=verbose\""); + return false; + } + + if (command_line_has_argument (state->kernel_command_line, "rhgb")) + { + ply_trace ("using default splash because kernel command line has option \"rhgb\""); + return true; + } + + if (command_line_has_argument (state->kernel_command_line, "splash")) + { + ply_trace ("using default splash because kernel command line has option \"splash\""); + return true; + } + + if (command_line_has_argument (state->kernel_command_line, "splash=silent")) + { + ply_trace ("using default splash because kernel command line has option \"splash=slient\""); + return true; + } + + ply_trace ("no default splash because kernel command line lacks \"splash\" or \"rhgb\""); + return false; + } + + static void +-on_show_splash (state_t *state, +- ply_trigger_t *show_trigger) ++on_show_splash (state_t *state) + { + bool has_open_seats; + + if (state->is_shown) + { + ply_trace ("show splash called while already shown"); + return; + } + + if (state->is_inactive) + { + ply_trace ("show splash called while inactive"); + return; + } + + if (plymouth_should_ignore_show_splash_calls (state)) + { + ply_trace ("show splash called while ignoring show splash calls"); + dump_details_and_quit_splash (state); + return; + } + +- state->show_trigger = show_trigger; + state->is_shown = true; + has_open_seats = ply_device_manager_has_open_seats (state->device_manager); + + if (!state->is_attached && state->should_be_attached && has_open_seats) + attach_to_running_session (state); + + if (has_open_seats) + { + ply_trace ("at least one seat already open, so loading splash"); + show_splash (state); + } + else + { + ply_trace ("no seats available to show splash on, waiting..."); + } + } + + static void + on_seat_removed (state_t *state, + ply_seat_t *seat) + { + ply_keyboard_t *keyboard; + + keyboard = ply_seat_get_keyboard (seat); + + ply_trace ("no longer listening for keystrokes"); + ply_keyboard_remove_input_handler (keyboard, + (ply_keyboard_input_handler_t) + on_keyboard_input); + ply_trace ("no longer listening for escape"); +@@ -960,67 +957,60 @@ show_splash (state_t *state) + running_time = now - state->start_time; + if (state->splash_delay > running_time) + { + double time_left = state->splash_delay - running_time; + + ply_trace ("delaying show splash for %lf seconds", + time_left); + ply_event_loop_stop_watching_for_timeout (state->loop, + (ply_event_loop_timeout_handler_t) + show_splash, + state); + ply_event_loop_watch_for_timeout (state->loop, + time_left, + (ply_event_loop_timeout_handler_t) + show_splash, + state); + return; + } + } + + if (plymouth_should_show_default_splash (state)) + { + show_default_splash (state); + state->showing_details = false; + } + else + { + show_detailed_splash (state); + state->showing_details = true; + } +- +- if (state->show_trigger != NULL) +- { +- ply_trace ("telling boot server about completed show operation"); +- ply_trigger_pull (state->show_trigger, NULL); +- state->show_trigger = NULL; +- } + } + + static void + on_seat_added (state_t *state, + ply_seat_t *seat) + { + ply_keyboard_t *keyboard; + + if (state->is_shown) + { + if (state->boot_splash == NULL) + { + ply_trace ("seat added before splash loaded, so loading splash now"); + show_splash (state); + } + else + { + ply_trace ("seat added after splash loaded, so attaching to splash"); + ply_boot_splash_attach_to_seat (state->boot_splash, seat); + } + } + + keyboard = ply_seat_get_keyboard (seat); + + ply_trace ("listening for keystrokes"); + ply_keyboard_add_input_handler (keyboard, + (ply_keyboard_input_handler_t) + on_keyboard_input, state); + ply_trace ("listening for escape"); + ply_keyboard_add_escape_handler (keyboard, +diff --git a/src/ply-boot-server.c b/src/ply-boot-server.c +index 78c9c52..3e67bfb 100644 +--- a/src/ply-boot-server.c ++++ b/src/ply-boot-server.c +@@ -283,72 +283,60 @@ ply_boot_connection_send_answer (ply_boot_connection_t *connection, + { + size = strlen (answer); + + if (!ply_write (connection->fd, + PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ANSWER, + strlen (PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ANSWER)) || + !ply_write_uint32 (connection->fd, + size) || + !ply_write (connection->fd, + answer, size)) + ply_trace ("could not finish writing answer: %m"); + + } + + } + + static void + ply_boot_connection_on_password_answer (ply_boot_connection_t *connection, + const char *password) + { + ply_trace ("got password answer"); + + ply_boot_connection_send_answer (connection, password); + if (password != NULL) + ply_list_append_data (connection->server->cached_passwords, + strdup (password)); + + } + + static void +-ply_boot_connection_on_splash_shown (ply_boot_connection_t *connection) +-{ +- ply_trace ("shown"); +- if (!ply_write (connection->fd, +- PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK, +- strlen (PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK))) +- { +- ply_trace ("could not finish writing deactivate reply: %m"); +- } +-} +- +-static void + ply_boot_connection_on_deactivated (ply_boot_connection_t *connection) + { + ply_trace ("deactivated"); + if (!ply_write (connection->fd, + PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK, + strlen (PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK))) + { + ply_trace ("could not finish writing deactivate reply: %m"); + } + } + + static void + ply_boot_connection_on_quit_complete (ply_boot_connection_t *connection) + { + ply_trace ("quit complete"); + if (!ply_write (connection->fd, + PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK, + strlen (PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK))) + { + ply_trace ("could not finish writing quit reply: %m"); + } + } + + static void + ply_boot_connection_on_question_answer (ply_boot_connection_t *connection, + const char *answer) + { + ply_trace ("got question answer: %s", answer); + ply_boot_connection_send_answer (connection, answer); + } +@@ -462,77 +450,63 @@ ply_boot_connection_on_request (ply_boot_connection_t *connection) + ply_error ("failed to parse percentage %s", argument); + value = 0; + } + + ply_trace ("got system-update notification %li%%", value); + if (!ply_write (connection->fd, + PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK, + strlen (PLY_BOOT_PROTOCOL_RESPONSE_TYPE_ACK))) + ply_trace ("could not finish writing update reply: %m"); + + if (server->system_update_handler != NULL) + server->system_update_handler (server->user_data, value, server); + free (argument); + free (command); + return; + } + else if (strcmp (command, PLY_BOOT_PROTOCOL_REQUEST_TYPE_SYSTEM_INITIALIZED) == 0) + { + ply_trace ("got system initialized notification"); + if (server->system_initialized_handler != NULL) + server->system_initialized_handler (server->user_data, server); + } + else if (strcmp (command, PLY_BOOT_PROTOCOL_REQUEST_TYPE_ERROR) == 0) + { + ply_trace ("got error notification"); + if (server->error_handler != NULL) + server->error_handler (server->user_data, server); + } + else if (strcmp (command, PLY_BOOT_PROTOCOL_REQUEST_TYPE_SHOW_SPLASH) == 0) + { +- ply_trigger_t *show_trigger; +- + ply_trace ("got show splash request"); +- +- show_trigger = ply_trigger_new (NULL); +- +- ply_trigger_add_handler (show_trigger, +- (ply_trigger_handler_t) +- ply_boot_connection_on_splash_shown, +- connection); +- + if (server->show_splash_handler != NULL) +- server->show_splash_handler (server->user_data, show_trigger, server); +- +- free (argument); +- free (command); +- return; ++ server->show_splash_handler (server->user_data, server); + } + else if (strcmp (command, PLY_BOOT_PROTOCOL_REQUEST_TYPE_HIDE_SPLASH) == 0) + { + ply_trace ("got hide splash request"); + if (server->hide_splash_handler != NULL) + server->hide_splash_handler (server->user_data, server); + } + else if (strcmp (command, PLY_BOOT_PROTOCOL_REQUEST_TYPE_DEACTIVATE) == 0) + { + ply_trigger_t *deactivate_trigger; + + ply_trace ("got deactivate request"); + + deactivate_trigger = ply_trigger_new (NULL); + + ply_trigger_add_handler (deactivate_trigger, + (ply_trigger_handler_t) + ply_boot_connection_on_deactivated, + connection); + + if (server->deactivate_handler != NULL) + server->deactivate_handler (server->user_data, deactivate_trigger, server); + + free (argument); + free (command); + return; + } + else if (strcmp (command, PLY_BOOT_PROTOCOL_REQUEST_TYPE_REACTIVATE) == 0) + { + ply_trace ("got reactivate request"); +diff --git a/src/ply-boot-server.h b/src/ply-boot-server.h +index 4436be8..b885a81 100644 +--- a/src/ply-boot-server.h ++++ b/src/ply-boot-server.h +@@ -22,61 +22,60 @@ + #ifndef PLY_BOOT_SERVER_H + #define PLY_BOOT_SERVER_H + + #include + #include + #include + + #include "ply-trigger.h" + #include "ply-boot-protocol.h" + #include "ply-event-loop.h" + + typedef struct _ply_boot_server ply_boot_server_t; + + typedef void (* ply_boot_server_update_handler_t) (void *user_data, + const char *status, + ply_boot_server_t *server); + + typedef void (* ply_boot_server_change_mode_handler_t) (void *user_data, + const char *mode, + ply_boot_server_t *server); + + typedef void (* ply_boot_server_system_update_handler_t) (void *user_data, + int progress, + ply_boot_server_t *server); + + typedef void (* ply_boot_server_newroot_handler_t) (void *user_data, + const char *root_dir, + ply_boot_server_t *server); + + typedef void (* ply_boot_server_show_splash_handler_t) (void *user_data, +- ply_trigger_t *show_trigger, + ply_boot_server_t *server); + + typedef void (* ply_boot_server_hide_splash_handler_t) (void *user_data, + ply_boot_server_t *server); + + typedef void (* ply_boot_server_password_answer_handler_t) (void *answer_data, + const char *password, + ply_boot_server_t *server); + typedef void (* ply_boot_server_ask_for_password_handler_t) (void *user_data, + const char *prompt, + ply_trigger_t *answer, + ply_boot_server_t *server); + typedef void (* ply_boot_server_question_answer_handler_t) (void *answer_data, + const char *answer, + ply_boot_server_t *server); + typedef void (* ply_boot_server_ask_question_handler_t) (void *user_data, + const char *prompt, + ply_trigger_t *answer, + ply_boot_server_t *server); + typedef void (* ply_boot_server_display_message_handler_t) (void *user_data, + const char *message, + ply_boot_server_t *server); + typedef void (* ply_boot_server_hide_message_handler_t) (void *user_data, + const char *message, + ply_boot_server_t *server); + typedef void (* ply_boot_server_watch_for_keystroke_handler_t) (void *user_data, + const char *keys, + ply_trigger_t *answer, + ply_boot_server_t *server); + typedef void (* ply_boot_server_ignore_keystroke_handler_t) (void *user_data, +-- +1.8.3.1 + diff --git a/SOURCES/drm-dirty-fb.patch b/SOURCES/drm-dirty-fb.patch deleted file mode 100644 index 88b43c2..0000000 --- a/SOURCES/drm-dirty-fb.patch +++ /dev/null @@ -1,45 +0,0 @@ -diff -up plymouth-0.8.8/src/plugins/renderers/drm/ply-renderer-generic-driver.c.flush plymouth-0.8.8/src/plugins/renderers/drm/ply-renderer-generic-driver.c ---- plymouth-0.8.8/src/plugins/renderers/drm/ply-renderer-generic-driver.c.flush 2012-09-27 02:50:53.000000000 +1000 -+++ plymouth-0.8.8/src/plugins/renderers/drm/ply-renderer-generic-driver.c 2013-03-15 10:57:33.000000000 +1000 -@@ -70,6 +70,7 @@ struct _ply_renderer_buffer - struct _ply_renderer_driver - { - int device_fd; -+ int need_flushes; - ply_hashtable_t *buffers; - }; - -@@ -123,7 +124,7 @@ create_driver (int device_fd) - - driver = calloc (1, sizeof (ply_renderer_driver_t)); - driver->device_fd = device_fd; -- -+ driver->need_flushes = 1; - driver->buffers = ply_hashtable_new (ply_hashtable_direct_hash, - ply_hashtable_direct_compare); - -@@ -326,10 +327,23 @@ end_flush (ply_renderer_driver_t *driver - uint32_t buffer_id) - { - ply_renderer_buffer_t *buffer; -+ struct drm_clip_rect clip; - - buffer = get_buffer_from_id (driver, buffer_id); -- - assert (buffer != NULL); -+ -+ if (driver->need_flushes) { -+ int ret; -+ clip.x1 = 0; -+ clip.y1 = 0; -+ clip.x2 = buffer->width; -+ clip.y2 = buffer->height; -+ -+ ret = drmModeDirtyFB(driver->device_fd, buffer->id, -+ &clip, 1); -+ if (ret == -ENOSYS) -+ driver->need_flushes = 0; -+ } - } - - static void diff --git a/SOURCES/fix-ask-password-race.patch b/SOURCES/fix-ask-password-race.patch new file mode 100644 index 0000000..0bc8658 --- /dev/null +++ b/SOURCES/fix-ask-password-race.patch @@ -0,0 +1,211 @@ +From e0e098f6b1240979f7da473f8966cd8043bce576 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 6 Mar 2014 10:02:21 -0500 +Subject: [PATCH] main: call update_display when splash is shown + +we need to call update display any time a splash is shown, +because there may be a pending password request. + +The code attempted to do this in show_splash, but did it before +the splash was assigned to running state, so function was a noop. + +This commit moves it a little later in code after the splash is +properly assigned. +--- + src/main.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/src/main.c b/src/main.c +index ccb8b63..fb91bf2 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -294,60 +294,61 @@ load_settings (state_t *state, + ply_trace ("Splash delay is set to %lf", state->splash_delay); + state->splash_delay = atof (delay_string); + } + } + + settings_loaded = true; + out: + ply_key_file_free (key_file); + + return settings_loaded; + } + + static void + show_detailed_splash (state_t *state) + { + ply_boot_splash_t *splash; + + if (state->boot_splash != NULL) + return; + + ply_trace ("Showing detailed splash screen"); + splash = show_theme (state, NULL); + + if (splash == NULL) + { + ply_trace ("Could not start detailed splash screen, this could be a problem."); + return; + } + + state->boot_splash = splash; ++ update_display (state); + } + + static const char * + command_line_get_string_after_prefix (const char *command_line, + const char *prefix) + { + char *argument; + + argument = strstr (command_line, prefix); + + if (argument == NULL) + return NULL; + + if (argument == command_line || + argument[-1] == ' ') + return argument + strlen (prefix); + + return NULL; + } + + static bool + command_line_has_argument (const char *command_line, + const char *argument) + { + const char *string; + + string = command_line_get_string_after_prefix (command_line, argument); + + if (string == NULL) + return false; +@@ -450,60 +451,62 @@ show_default_splash (state_t *state) + { + ply_trace ("Trying distribution default splash"); + state->boot_splash = show_theme (state, state->distribution_default_splash_path); + } + + if (state->boot_splash == NULL) + { + ply_trace ("Trying old scheme for default splash"); + state->boot_splash = show_theme (state, PLYMOUTH_THEME_PATH "default.plymouth"); + } + + if (state->boot_splash == NULL) + { + ply_trace ("Could not start default splash screen," + "showing text splash screen"); + state->boot_splash = show_theme (state, PLYMOUTH_THEME_PATH "text/text.plymouth"); + } + + if (state->boot_splash == NULL) + { + ply_trace ("Could not start text splash screen," + "showing built-in splash screen"); + state->boot_splash = show_theme (state, NULL); + } + + if (state->boot_splash == NULL) + { + ply_error ("plymouthd: could not start boot splash: %m"); + return; + } ++ ++ update_display (state); + } + + static void + cancel_pending_delayed_show (state_t *state) + { + if (isnan (state->splash_delay)) + return; + + ply_event_loop_stop_watching_for_timeout (state->loop, + (ply_event_loop_timeout_handler_t) + show_splash, + state); + state->splash_delay = NAN; + } + + static void + on_ask_for_password (state_t *state, + const char *prompt, + ply_trigger_t *answer) + { + ply_entry_trigger_t *entry_trigger; + + if (state->boot_splash == NULL) + { + /* Waiting to be shown, boot splash will + * arrive shortly so just sit tight + */ + if (state->is_shown) + { + bool has_open_seats; +@@ -1671,61 +1674,60 @@ show_theme (state_t *state, + splash = load_theme (state, theme_path); + else + splash = load_built_in_theme (state); + + if (splash == NULL) + return NULL; + + attach_splash_to_seats (state, splash); + ply_device_manager_activate_renderers (state->device_manager); + + if (state->mode == PLY_MODE_SHUTDOWN) + splash_mode = PLY_BOOT_SPLASH_MODE_SHUTDOWN; + else + splash_mode = PLY_BOOT_SPLASH_MODE_BOOT_UP; + + if (!ply_boot_splash_show (splash, splash_mode)) + { + ply_save_errno (); + ply_boot_splash_free (splash); + ply_restore_errno (); + return NULL; + } + + #ifdef PLY_ENABLE_SYSTEMD_INTEGRATION + if (state->is_attached) + tell_systemd_to_print_details (state); + #endif + + ply_device_manager_activate_keyboards (state->device_manager); + show_messages (state); +- update_display (state); + + return splash; + } + + static bool + attach_to_running_session (state_t *state) + { + ply_terminal_session_t *session; + ply_terminal_session_flags_t flags; + bool should_be_redirected; + + flags = 0; + + should_be_redirected = !state->no_boot_log; + + if (should_be_redirected) + flags |= PLY_TERMINAL_SESSION_FLAGS_REDIRECT_CONSOLE; + + if (state->session == NULL) + { + ply_trace ("creating new terminal session"); + session = ply_terminal_session_new (NULL); + + ply_terminal_session_attach_to_event_loop (session, state->loop); + } + else + { + session = state->session; + ply_trace ("session already created"); + } +-- +1.8.3.1 + diff --git a/SOURCES/fix-details.patch b/SOURCES/fix-details.patch new file mode 100644 index 0000000..ef501c7 --- /dev/null +++ b/SOURCES/fix-details.patch @@ -0,0 +1,271 @@ +From 785a0050c01567e3e9eaaf0534e7e52045fc4a9d Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Fri, 24 Jan 2014 14:08:16 -0500 +Subject: [PATCH 1/3] plymouthd: build with -rdynamic so built-in module works + +The details plugin is "built in" to the plymouthd binary, so +it's always available even if the details module isn't installed +(say /usr isn't mounted yet or something) + +Unfortunately, this feature isn't working because plymouthd isn't +built with -rdynamic (except for in my local CFLAGS). + +This commit fixes the makefile goo accordingly. +--- + src/Makefile.am | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/Makefile.am b/src/Makefile.am +index 152cd43..fc2f5da 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -1,47 +1,48 @@ + SUBDIRS = libply libply-splash-core libply-splash-graphics . plugins client viewer + if ENABLE_UPSTART_MONITORING + SUBDIRS += upstart-bridge + endif + AM_CPPFLAGS = -I$(top_srcdir) \ + -I$(srcdir)/libply \ + -I$(srcdir)/libply-splash-core \ + -I$(srcdir) \ + -DPLYMOUTH_LOG_DIRECTORY=\"$(localstatedir)/log\" \ + -DPLYMOUTH_SPOOL_DIRECTORY=\"$(localstatedir)/spool/plymouth\" \ + -DPLYMOUTH_TIME_DIRECTORY=\"$(localstatedir)/lib/plymouth/\" \ + -DPLYMOUTH_LOGO_FILE=\"$(logofile)\" + + plymouthdbindir = $(plymouthdaemondir) + plymouthdbin_PROGRAMS = plymouthd + + plymouthd_CFLAGS = $(PLYMOUTH_CFLAGS) \ ++ -rdynamic \ + -DPLYMOUTH_PLUGIN_PATH=\"$(PLYMOUTH_PLUGIN_PATH)\" \ + -DPLYMOUTH_THEME_PATH=\"$(PLYMOUTH_THEME_PATH)/\" \ + -DPLYMOUTH_POLICY_DIR=\"$(PLYMOUTH_POLICY_DIR)/\" \ + -DPLYMOUTH_RUNTIME_DIR=\"$(PLYMOUTH_RUNTIME_DIR)\" \ + -DPLYMOUTH_CONF_DIR=\"$(PLYMOUTH_CONF_DIR)/\" + plymouthd_LDADD = $(PLYMOUTH_LIBS) libply/libply.la libply-splash-core/libply-splash-core.la + plymouthd_SOURCES = \ + ply-boot-protocol.h \ + ply-boot-server.h \ + ply-boot-server.c \ + plugins/splash/details/plugin.c \ + main.c + + plymouthdrundir = $(localstatedir)/run/plymouth + plymouthdspooldir = $(localstatedir)/spool/plymouth + plymouthdtimedir = $(localstatedir)/lib/plymouth + + pkgconfigdir = $(libdir)/pkgconfig + pkgconfig_DATA = ply-splash-core.pc ply-splash-graphics.pc + + plymouthd_defaultsdir = $(PLYMOUTH_POLICY_DIR) + dist_plymouthd_defaults_DATA = plymouthd.defaults + + plymouthd_confdir = $(PLYMOUTH_CONF_DIR) + dist_plymouthd_conf_DATA = plymouthd.conf + + install-data-hook: + -mkdir -p $(DESTDIR)$(plymouthdrundir) + -mkdir -p $(DESTDIR)$(plymouthdspooldir) + -mkdir -p $(DESTDIR)$(plymouthdtimedir) +-- +1.8.3.1 + + +From 382305e4a9f7b4c221968fcba7394b1cc03b454e Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Fri, 24 Jan 2014 14:29:31 -0500 +Subject: [PATCH 2/3] main: disable hotplug events and splash delay if details + forced + +There's no point in waiting for a graphics device if details are +forced, and we shouldn't ever delay showing details. If details +are requested, we shouldn't be hiding them. +--- + src/main.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/src/main.c b/src/main.c +index 2ccb8ec..43e3a0a 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -2279,60 +2279,69 @@ main (int argc, + } + } + + state.progress = ply_progress_new (); + state.splash_delay = NAN; + + ply_progress_load_cache (state.progress, + get_cache_file_for_mode (state.mode)); + + if (pid_file != NULL) + write_pid_file (pid_file); + + if (daemon_handle != NULL + && !ply_detach_daemon (daemon_handle, 0)) + { + ply_error ("plymouthd: could not tell parent to exit: %m"); + return EX_UNAVAILABLE; + } + + find_override_splash (&state); + find_system_default_splash (&state); + find_distribution_default_splash (&state); + + 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; + ++ if (!plymouth_should_show_default_splash (&state)) ++ { ++ /* don't bother listening for udev events if we're forcing details */ ++ device_manager_flags |= PLY_DEVICE_MANAGER_FLAGS_IGNORE_UDEV; ++ ++ /* don't ever delay showing the detailed splash */ ++ state.splash_delay = NAN; ++ } ++ + load_devices (&state, device_manager_flags); + + ply_trace ("entering event loop"); + exit_code = ply_event_loop_run (state.loop); + ply_trace ("exited event loop"); + + ply_boot_splash_free (state.boot_splash); + state.boot_splash = NULL; + + ply_command_parser_free (state.command_parser); + + ply_boot_server_free (state.boot_server); + state.boot_server = NULL; + + ply_trace ("freeing terminal session"); + ply_terminal_session_free (state.session); + + ply_buffer_free (state.boot_buffer); + ply_progress_free (state.progress); + + ply_trace ("exiting with code %d", exit_code); + + if (debug_buffer != NULL) + { + dump_debug_buffer_to_file (); + ply_buffer_free (debug_buffer); + } + + ply_free_error_log(); + +-- +1.8.3.1 + + +From 9255a442e93a4fce835ca6e7e9dc9023be6eaf30 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Fri, 24 Jan 2014 15:08:10 -0500 +Subject: [PATCH 3/3] seat: proceed without renderer if type is AUTO and + renderer fails + +If a seat gets opened with a renderer type of AUTO, and the renderer +fails to open, then it's okay and expected to proceed without a +renderer (and just use the terminal). The code attempted to do this +but failed to nullify the seat->renderer object, so it ended up +going down the renderer-active code path. + +This commit fixes that. +--- + src/libply-splash-core/ply-seat.c | 17 ++++++++++++----- + 1 file changed, 12 insertions(+), 5 deletions(-) + +diff --git a/src/libply-splash-core/ply-seat.c b/src/libply-splash-core/ply-seat.c +index d9c7a2b..541b29e 100644 +--- a/src/libply-splash-core/ply-seat.c ++++ b/src/libply-splash-core/ply-seat.c +@@ -90,69 +90,76 @@ add_pixel_displays (ply_seat_t *seat) + next_node = ply_list_get_next_node (heads, node); + + display = ply_pixel_display_new (seat->renderer, head); + + ply_list_append_data (seat->pixel_displays, display); + + node = next_node; + } + } + + static void + add_text_displays (ply_seat_t *seat) + { + ply_text_display_t *display; + + display = ply_text_display_new (seat->terminal); + ply_list_append_data (seat->text_displays, display); + } + + bool + ply_seat_open (ply_seat_t *seat, + ply_renderer_type_t renderer_type, + const char *device) + { + if (renderer_type != PLY_RENDERER_TYPE_NONE) + { + ply_renderer_t *renderer; + + renderer = ply_renderer_new (renderer_type, device, seat->terminal); + +- if (!ply_renderer_open (renderer) && renderer_type != PLY_RENDERER_TYPE_AUTO) ++ if (!ply_renderer_open (renderer)) + { + ply_trace ("could not open renderer for %s", device); + ply_renderer_free (renderer); +- return false; +- } + +- seat->renderer = renderer; +- seat->renderer_active = true; ++ seat->renderer = NULL; ++ seat->renderer_active = false; ++ ++ if (renderer_type != PLY_RENDERER_TYPE_AUTO) ++ return false; ++ } ++ else ++ { ++ seat->renderer = renderer; ++ seat->renderer_active = true; ++ } + } + + if (seat->renderer != NULL) + { + seat->keyboard = ply_keyboard_new_for_renderer (seat->renderer); + add_pixel_displays (seat); + + } + else + { + seat->keyboard = ply_keyboard_new_for_terminal (seat->terminal); + } + add_text_displays (seat); + + ply_keyboard_watch_for_input (seat->keyboard); + seat->keyboard_active = true; + + return true; + } + + bool + ply_seat_is_open (ply_seat_t *seat) + { + return ply_list_get_length (seat->pixel_displays) > 0 || + ply_list_get_length (seat->text_displays) > 0; + } + + void + ply_seat_deactivate_keyboard (ply_seat_t *seat) + { +-- +1.8.3.1 + diff --git a/SOURCES/fix-hide-splash.patch b/SOURCES/fix-hide-splash.patch new file mode 100644 index 0000000..729bcb4 --- /dev/null +++ b/SOURCES/fix-hide-splash.patch @@ -0,0 +1,174 @@ +From 1628320b093e3605e91f0aa7183b6859920a0a85 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 6 Feb 2014 14:42:40 -0500 +Subject: [PATCH 1/2] main: don't nullify local_console_terminal in quit_splash + +quit_splash gets called on hide-splash so nullify the terminal +will make it unavailable on later show-splash calls. +--- + src/main.c | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/src/main.c b/src/main.c +index 91e0649..1f9f6dd 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -1042,61 +1042,60 @@ load_devices (state_t *state, + { + state->device_manager = ply_device_manager_new (state->default_tty, flags); + state->local_console_terminal = ply_device_manager_get_default_terminal (state->device_manager); + + ply_device_manager_watch_seats (state->device_manager, + (ply_seat_added_handler_t) + on_seat_added, + (ply_seat_removed_handler_t) + on_seat_removed, + state); + } + + static void + quit_splash (state_t *state) + { + ply_trace ("quiting splash"); + if (state->boot_splash != NULL) + { + ply_trace ("freeing splash"); + ply_boot_splash_free (state->boot_splash); + state->boot_splash = NULL; + } + + if (state->local_console_terminal != NULL) + { + if (!state->should_retain_splash) + { + ply_trace ("Not retaining splash, so deallocating VT"); + ply_terminal_deactivate_vt (state->local_console_terminal); + } +- state->local_console_terminal = NULL; + } + + detach_from_running_session (state); + } + + static void + hide_splash (state_t *state) + { + state->is_shown = false; + + cancel_pending_delayed_show (state); + + if (state->boot_splash == NULL) + return; + + ply_boot_splash_hide (state->boot_splash); + + if (state->local_console_terminal != NULL) + ply_terminal_set_mode (state->local_console_terminal, PLY_TERMINAL_MODE_TEXT); + } + + static void + dump_details_and_quit_splash (state_t *state) + { + state->showing_details = false; + toggle_between_splash_and_details (state); + + ply_device_manager_deactivate_renderers (state->device_manager); + hide_splash (state); + quit_splash (state); +-- +1.8.3.1 + + +From fea0252399bf9d13e88b27b7296f263732f180fc Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 6 Feb 2014 15:22:54 -0500 +Subject: [PATCH 2/2] main: detach from keyboard on hide-splash + +Currently plymouth stays in control of the terminal +after hide-splash. This is wrong. Once plymouth is +hidden, the terminal should be free to use for other +programs. + +This commit makes sure we free up the terminal on +hide splash. +--- + src/main.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/src/main.c b/src/main.c +index 1f9f6dd..92a1cfd 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -1035,66 +1035,69 @@ on_seat_added (state_t *state, + on_enter, state); + + } + + static void + load_devices (state_t *state, + ply_device_manager_flags_t flags) + { + state->device_manager = ply_device_manager_new (state->default_tty, flags); + state->local_console_terminal = ply_device_manager_get_default_terminal (state->device_manager); + + ply_device_manager_watch_seats (state->device_manager, + (ply_seat_added_handler_t) + on_seat_added, + (ply_seat_removed_handler_t) + on_seat_removed, + state); + } + + static void + quit_splash (state_t *state) + { + ply_trace ("quiting splash"); + if (state->boot_splash != NULL) + { + ply_trace ("freeing splash"); + ply_boot_splash_free (state->boot_splash); + state->boot_splash = NULL; + } + ++ ply_device_manager_deactivate_keyboards (state->device_manager); ++ + if (state->local_console_terminal != NULL) + { + if (!state->should_retain_splash) + { + ply_trace ("Not retaining splash, so deallocating VT"); + ply_terminal_deactivate_vt (state->local_console_terminal); ++ ply_terminal_close (state->local_console_terminal); + } + } + + detach_from_running_session (state); + } + + static void + hide_splash (state_t *state) + { + state->is_shown = false; + + cancel_pending_delayed_show (state); + + if (state->boot_splash == NULL) + return; + + ply_boot_splash_hide (state->boot_splash); + + if (state->local_console_terminal != NULL) + ply_terminal_set_mode (state->local_console_terminal, PLY_TERMINAL_MODE_TEXT); + } + + static void + dump_details_and_quit_splash (state_t *state) + { + state->showing_details = false; + toggle_between_splash_and_details (state); + + ply_device_manager_deactivate_renderers (state->device_manager); + hide_splash (state); +-- +1.8.3.1 + diff --git a/SOURCES/fix-startup-race.patch b/SOURCES/fix-startup-race.patch new file mode 100644 index 0000000..c449b77 --- /dev/null +++ b/SOURCES/fix-startup-race.patch @@ -0,0 +1,213 @@ +From 530db7a38000c0ee82ef833eec27ca05539da59e Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Wed, 5 Feb 2014 15:09:13 -0500 +Subject: [PATCH 1/2] main: don't show splash from cancel_pending_delayed_show + +It was a weird to show something in a function called "cancel..show" + +Instead move the logic to the one caller that actually needed that +functionality (on_ask_for_password) +--- + src/main.c | 24 ++++++++++++++---------- + 1 file changed, 14 insertions(+), 10 deletions(-) + +diff --git a/src/main.c b/src/main.c +index e1cbcd9..64552b4 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -455,95 +455,99 @@ show_default_splash (state_t *state) + if (state->boot_splash == NULL) + { + ply_trace ("Trying old scheme for default splash"); + state->boot_splash = show_theme (state, PLYMOUTH_THEME_PATH "default.plymouth"); + } + + if (state->boot_splash == NULL) + { + ply_trace ("Could not start default splash screen," + "showing text splash screen"); + state->boot_splash = show_theme (state, PLYMOUTH_THEME_PATH "text/text.plymouth"); + } + + if (state->boot_splash == NULL) + { + ply_trace ("Could not start text splash screen," + "showing built-in splash screen"); + state->boot_splash = show_theme (state, NULL); + } + + if (state->boot_splash == NULL) + { + ply_error ("plymouthd: could not start boot splash: %m"); + return; + } + } + + static void + cancel_pending_delayed_show (state_t *state) + { +- bool has_open_seats; +- + if (isnan (state->splash_delay)) + return; + + ply_event_loop_stop_watching_for_timeout (state->loop, + (ply_event_loop_timeout_handler_t) + show_splash, + state); + state->splash_delay = NAN; +- has_open_seats = ply_device_manager_has_open_seats (state->device_manager); +- +- if (state->is_shown && has_open_seats) +- { +- ply_trace ("splash delay cancelled, showing splash immediately"); +- show_splash (state); +- } + } + + static void + on_ask_for_password (state_t *state, + const char *prompt, + ply_trigger_t *answer) + { + ply_entry_trigger_t *entry_trigger; + + if (state->boot_splash == NULL) + { + /* Waiting to be shown, boot splash will + * arrive shortly so just sit tight + */ + if (state->is_shown) + { +- ply_trace ("splash still coming up, waiting a bit"); ++ bool has_open_seats; ++ + cancel_pending_delayed_show (state); ++ ++ has_open_seats = ply_device_manager_has_open_seats (state->device_manager); ++ ++ if (has_open_seats) ++ { ++ ply_trace ("seats open now, showing splash immediately"); ++ show_splash (state); ++ } ++ else ++ { ++ ply_trace ("splash still coming up, waiting a bit"); ++ } + } + else + { + /* No splash, client will have to get password */ + ply_trace ("no splash loaded, replying immediately with no password"); + ply_trigger_pull (answer, NULL); + return; + } + } + + entry_trigger = calloc (1, sizeof (ply_entry_trigger_t)); + entry_trigger->type = PLY_ENTRY_TRIGGER_TYPE_PASSWORD; + entry_trigger->prompt = prompt; + entry_trigger->trigger = answer; + ply_trace ("queuing password request with boot splash"); + ply_list_append_data (state->entry_triggers, entry_trigger); + update_display (state); + } + + static void + on_ask_question (state_t *state, + const char *prompt, + ply_trigger_t *answer) + { + ply_entry_trigger_t *entry_trigger; + + entry_trigger = calloc (1, sizeof (ply_entry_trigger_t)); + entry_trigger->type = PLY_ENTRY_TRIGGER_TYPE_QUESTION; + entry_trigger->prompt = prompt; + entry_trigger->trigger = answer; +-- +1.8.3.1 + + +From 09bbba9201456305ac609d5f6a4be96463adcfd2 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Wed, 5 Feb 2014 15:12:17 -0500 +Subject: [PATCH 2/2] main: cancel show_splash timeout on deactivate + +This fixes a race/crash where plymouthd get deactivated +right before the show timer fires and it tries to +show itself after things have been torn down. +--- + src/main.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/src/main.c b/src/main.c +index 64552b4..4a9d91f 100644 +--- a/src/main.c ++++ b/src/main.c +@@ -1211,60 +1211,62 @@ on_boot_splash_idle (state_t *state) + } + else if (state->deactivate_trigger != NULL) + { + ply_trace ("deactivating splash"); + deactivate_splash (state); + } + } + + static void + on_deactivate (state_t *state, + ply_trigger_t *deactivate_trigger) + { + if (state->is_inactive) + { + ply_trigger_pull (deactivate_trigger, NULL); + return; + } + + if (state->deactivate_trigger != NULL) + { + ply_trigger_add_handler (state->deactivate_trigger, + (ply_trigger_handler_t) + ply_trigger_pull, + deactivate_trigger); + return; + } + + state->deactivate_trigger = deactivate_trigger; + + ply_trace ("deactivating"); ++ cancel_pending_delayed_show (state); ++ + ply_device_manager_deactivate_keyboards (state->device_manager); + + if (state->boot_splash != NULL) + { + ply_boot_splash_become_idle (state->boot_splash, + (ply_boot_splash_on_idle_handler_t) + on_boot_splash_idle, + state); + } + else + { + ply_trace ("deactivating splash"); + deactivate_splash (state); + } + } + + static void + on_reactivate (state_t *state) + { + if (!state->is_inactive) + return; + + if (state->local_console_terminal != NULL) + { + ply_terminal_open (state->local_console_terminal); + ply_terminal_watch_for_vt_changes (state->local_console_terminal); + ply_terminal_set_unbuffered_input (state->local_console_terminal); + ply_terminal_ignore_mode_changes (state->local_console_terminal, false); + } + +-- +1.8.3.1 + diff --git a/SOURCES/fix-text-splash-os-string.patch b/SOURCES/fix-text-splash-os-string.patch new file mode 100644 index 0000000..d250024 --- /dev/null +++ b/SOURCES/fix-text-splash-os-string.patch @@ -0,0 +1,140 @@ +From 08f3708e7fe45227deff7424622b7c7a25428a8e Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Fri, 17 Jan 2014 12:37:23 -0500 +Subject: [PATCH] text-progress-bar: prefer REDHAT_BUGZILLA_PRODUCT over + PRETTY_NAME + +The latter is currently filled with incorrect information on install +images and it's apparently hard to fix. +--- + src/libply-splash-core/ply-text-progress-bar.c | 53 +++++++++++++++----------- + 1 file changed, 31 insertions(+), 22 deletions(-) + +diff --git a/src/libply-splash-core/ply-text-progress-bar.c b/src/libply-splash-core/ply-text-progress-bar.c +index 8c4e759..8ca8816 100644 +--- a/src/libply-splash-core/ply-text-progress-bar.c ++++ b/src/libply-splash-core/ply-text-progress-bar.c +@@ -92,89 +92,98 @@ ply_text_progress_bar_free (ply_text_progress_bar_t *progress_bar) + if (progress_bar == NULL) + return; + + free (progress_bar); + } + + static void + get_os_string (void) + { + int fd; + char *buf, *pos, *pos2; + struct stat sbuf; + + buf = NULL; + + fd = open (RELEASE_FILE, O_RDONLY|O_CLOEXEC); + if (fd == -1) + goto out; + + if (fstat (fd, &sbuf) == -1) { + close (fd); + goto out; + } + + buf = calloc (sbuf.st_size + 1, sizeof(char)); + read (fd, buf, sbuf.st_size); + close (fd); + + if (strcmp (RELEASE_FILE, "/etc/os-release") == 0) + { +- char key[] = "PRETTY_NAME="; ++ const char *keys[] = { "REDHAT_BUGZILLA_PRODUCT=", "PRETTY_NAME=", "NAME=", NULL }; ++ int i; + +- for (pos = strstr (buf, key); +- pos != NULL; +- pos = strstr (pos, key)) ++ for (i = 0; keys[i] != NULL; i++) + { +- if (pos == buf || pos[-1] == '\n') +- break; +- } +- +- if (pos != NULL) +- { +- pos += strlen (key); +- pos2 = strstr (pos, "\n"); ++ const char *key; + +- if (pos2 != NULL) +- *pos2 = '\0'; +- else +- pos2 = pos + strlen(pos) - 1; ++ key = keys[i]; + +- if ((*pos == '\"' && pos2[-1] == '\"') || +- (*pos == '\'' && pos2[-1] == '\'')) ++ for (pos = strstr (buf, key); ++ pos != NULL; ++ pos = strstr (pos, key)) + { +- pos++; +- pos2--; ++ if (pos == buf || pos[-1] == '\n') ++ break; ++ } + +- *pos2 = '\0'; ++ if (pos != NULL) ++ { ++ pos += strlen (key); ++ pos2 = strstr (pos, "\n"); ++ ++ if (pos2 != NULL) ++ *pos2 = '\0'; ++ else ++ pos2 = pos + strlen(pos) - 1; ++ ++ if ((*pos == '\"' && pos2[-1] == '\"') || ++ (*pos == '\'' && pos2[-1] == '\'')) ++ { ++ pos++; ++ pos2--; ++ ++ *pos2 = '\0'; ++ } ++ asprintf (&os_string, " %s", pos); ++ goto out; + } +- asprintf (&os_string, " %s", pos); + } + goto out; + } + + pos = strstr (buf, " release "); + + if (pos == NULL) + goto out; + + pos2 = strstr (pos, " ("); + + if (pos2 == NULL) + goto out; + + *pos = '\0'; + pos += strlen (" release "); + + *pos2 = '\0'; + asprintf (&os_string, " %s %s", buf, pos); + + out: + free (buf); + + if (os_string == NULL) + os_string = strdup (""); + } + + void + ply_text_progress_bar_draw (ply_text_progress_bar_t *progress_bar) + { +-- +1.8.3.1 + diff --git a/SOURCES/ignore-early-fb-devices.patch b/SOURCES/ignore-early-fb-devices.patch new file mode 100644 index 0000000..05cb562 --- /dev/null +++ b/SOURCES/ignore-early-fb-devices.patch @@ -0,0 +1,768 @@ +From 10e686c2128bde0e70e7c137191dbe004d2f46fd Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Mon, 3 Mar 2014 13:27:30 -0500 +Subject: [PATCH 1/2] device-manager: handle drm hotplug separately from + /dev/fb + +Right now, we piggyback off fb subsystem events to know whether or +not a drm device is hotplugged (since all drm devices have fb devices +for backward compat). + +This commit makes drm and fb processing more independent, so we don't +rely on the compat device being available for drm hotplug to work.. +--- + src/libply-splash-core/ply-device-manager.c | 182 ++++++++++++++-------------- + 1 file changed, 89 insertions(+), 93 deletions(-) + +diff --git a/src/libply-splash-core/ply-device-manager.c b/src/libply-splash-core/ply-device-manager.c +index 36e814d..25f7d54 100644 +--- a/src/libply-splash-core/ply-device-manager.c ++++ b/src/libply-splash-core/ply-device-manager.c +@@ -11,60 +11,63 @@ + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA + * 02111-1307, USA. + */ + #include "config.h" + #include "ply-device-manager.h" + + #include + #include + #include + #include + #include + #include + #include + #include + #include + + #include + + #include "ply-logger.h" + #include "ply-event-loop.h" + #include "ply-hashtable.h" + #include "ply-list.h" + #include "ply-utils.h" + ++#define SUBSYSTEM_DRM "drm" ++#define SUBSYSTEM_FRAME_BUFFER "graphics" ++ + static void create_seat_for_terminal_and_renderer_type (ply_device_manager_t *manager, + const char *device_path, + ply_terminal_t *terminal, + ply_renderer_type_t renderer_type); + struct _ply_device_manager + { + ply_device_manager_flags_t flags; + ply_event_loop_t *loop; + ply_hashtable_t *terminals; + ply_terminal_t *local_console_terminal; + ply_seat_t *local_console_seat; + ply_list_t *seats; + struct udev *udev_context; + struct udev_queue *udev_queue; + int udev_queue_fd; + ply_fd_watch_t *udev_queue_fd_watch; + struct udev_monitor *udev_monitor; + + ply_seat_added_handler_t seat_added_handler; + ply_seat_removed_handler_t seat_removed_handler; + void *seat_event_handler_data; + }; + + static void + detach_from_event_loop (ply_device_manager_t *manager) + { + assert (manager != NULL); + + manager->loop = NULL; + } +@@ -84,342 +87,334 @@ attach_to_event_loop (ply_device_manager_t *manager, + manager); + } + + static bool + device_is_for_local_console (ply_device_manager_t *manager, + struct udev_device *device) + { + const char *device_path; + struct udev_device *bus_device; + char *bus_device_path; + const char *boot_vga; + bool for_local_console; + + /* Look at the associated bus device to see if this card is the + * card the kernel is using for its console. */ + device_path = udev_device_get_syspath (device); + asprintf (&bus_device_path, "%s/device", device_path); + bus_device = udev_device_new_from_syspath (manager->udev_context, bus_device_path); + + boot_vga = udev_device_get_sysattr_value (bus_device, "boot_vga"); + free (bus_device_path); + + if (boot_vga != NULL && strcmp (boot_vga, "1") == 0) + for_local_console = true; + else + for_local_console = false; + + return for_local_console; + } + +-static char * +-get_drm_device_node_path_from_fb_device (ply_device_manager_t *manager, +- struct udev_device *fb_device) ++static bool ++fb_device_has_drm_device (ply_device_manager_t *manager, ++ struct udev_device *fb_device) + { + struct udev_enumerate *card_matches; + struct udev_list_entry *card_entry; + const char *id_path; +- char *device_node_path = NULL; ++ bool has_drm_device = 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); + udev_enumerate_add_match_is_initialized(card_matches); + udev_enumerate_add_match_parent (card_matches, udev_device_get_parent (fb_device)); + udev_enumerate_add_match_subsystem (card_matches, "drm"); + id_path = udev_device_get_property_value (fb_device, "ID_PATH"); + udev_enumerate_add_match_property (card_matches, "ID_PATH", id_path); + + ply_trace ("trying to find associated drm node for fb device (path: %s)", id_path); + + udev_enumerate_scan_devices (card_matches); + + /* there should only ever be at most one match so we don't iterate through + * the list, but just look at the first entry */ + card_entry = udev_enumerate_get_list_entry (card_matches); + + if (card_entry != NULL) + { + struct udev_device *card_device = NULL; + const char *card_node; + const char *card_path; + + 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) +- device_node_path = strdup (card_node); ++ has_drm_device = true; + else + ply_trace ("no card node!"); + + udev_device_unref (card_device); + } + else + { + ply_trace ("no card entry!"); + } + + udev_enumerate_unref (card_matches); +- return device_node_path; ++ return has_drm_device; + } + + static void + create_seat_for_udev_device (ply_device_manager_t *manager, + struct udev_device *device) + { + bool for_local_console; +- char *card_path; ++ const char *device_path; + ply_terminal_t *terminal = NULL; + + for_local_console = device_is_for_local_console (manager, device); + + ply_trace ("device is for local console: %s", for_local_console? "yes" : "no"); + + if (for_local_console) + terminal = manager->local_console_terminal; + +- card_path = get_drm_device_node_path_from_fb_device (manager, device); ++ device_path = udev_device_get_devnode (device); + +- if (card_path != NULL) +- { +- create_seat_for_terminal_and_renderer_type (manager, +- card_path, +- terminal, +- PLY_RENDERER_TYPE_DRM); +- free (card_path); +- } +- else ++ if (device_path != NULL) + { +- const char *fb_device_node_path; ++ const char *subsystem; ++ ply_renderer_type_t renderer_type = PLY_RENDERER_TYPE_NONE; ++ ++ subsystem = udev_device_get_subsystem (device); ++ ++ if (strcmp (subsystem, SUBSYSTEM_DRM) == 0) ++ { ++ ply_trace ("found DRM device %s", device_path); ++ renderer_type = PLY_RENDERER_TYPE_DRM; ++ } ++ else if (strcmp (subsystem, SUBSYSTEM_FRAME_BUFFER) == 0) ++ { ++ ply_trace ("found frame buffer device %s", device_path); ++ if (!fb_device_has_drm_device (manager, device)) ++ { ++ renderer_type = PLY_RENDERER_TYPE_FRAME_BUFFER; ++ } ++ else ++ { ++ ply_trace ("ignoring, since there's a DRM device associated with it"); ++ } ++ } + +- fb_device_node_path = udev_device_get_devnode (device); +- if (fb_device_node_path != NULL) ++ if (renderer_type != PLY_RENDERER_TYPE_NONE) + create_seat_for_terminal_and_renderer_type (manager, +- fb_device_node_path, ++ device_path, + terminal, +- PLY_RENDERER_TYPE_FRAME_BUFFER); ++ renderer_type); + } + } + + static void + free_seat_from_device_path (ply_device_manager_t *manager, + const char *device_path) + { + ply_list_node_t *node; + + node = ply_list_get_first_node (manager->seats); + while (node != NULL) + { + ply_seat_t *seat; + ply_renderer_t *renderer; + ply_list_node_t *next_node; + const char *renderer_device_path; + + seat = ply_list_node_get_data (node); + next_node = ply_list_get_next_node (manager->seats, node); + renderer = ply_seat_get_renderer (seat); + + if (renderer != NULL) + { + renderer_device_path = ply_renderer_get_device_name (renderer); + + if (renderer_device_path != NULL) + { + if (strcmp (device_path, renderer_device_path) == 0) + { + ply_trace ("removing seat associated with %s", device_path); + + if (manager->seat_removed_handler != NULL) + manager->seat_removed_handler (manager->seat_event_handler_data, seat); + + ply_seat_free (seat); + ply_list_remove_node (manager->seats, node); + break; + } + } + } + + node = next_node; + } + } + + static void + free_seat_for_udev_device (ply_device_manager_t *manager, + struct udev_device *device) + { +- char *card_path; +- +- card_path = get_drm_device_node_path_from_fb_device (manager, device); +- +- if (card_path != NULL) +- { +- free_seat_from_device_path (manager, card_path); +- free (card_path); +- } +- else +- { +- const char *fb_device_node_path; ++ const char *device_path; + +- fb_device_node_path = udev_device_get_devnode (device); ++ device_path = udev_device_get_devnode (device); + +- if (fb_device_node_path != NULL) +- free_seat_from_device_path (manager, fb_device_node_path); +- } ++ if (device_path != NULL) ++ free_seat_from_device_path (manager, device_path); + } + + static bool +-scan_graphics_devices (ply_device_manager_t *manager) ++create_seats_for_subsystem (ply_device_manager_t *manager, ++ const char *subsystem) + { +- struct udev_enumerate *fb_matches; +- struct udev_list_entry *fb_entry; ++ struct udev_enumerate *matches; ++ struct udev_list_entry *entry; + bool found_device = false; + +- ply_trace ("scanning for graphics devices"); +- /* graphics subsystem is for /dev/fb devices. kms drivers provide /dev/fb for backward +- * compatibility, and do so at the end of their initialization, so we can be confident +- * that when this subsystem is available the drm device is fully initialized */ +- fb_matches = udev_enumerate_new (manager->udev_context); +- udev_enumerate_add_match_subsystem (fb_matches, "graphics"); +- udev_enumerate_scan_devices (fb_matches); ++ ply_trace ("creating seats for %s devices", ++ strcmp (subsystem, SUBSYSTEM_FRAME_BUFFER) == 0? ++ "frame buffer": ++ subsystem); + +- udev_list_entry_foreach (fb_entry, udev_enumerate_get_list_entry (fb_matches)) ++ matches = udev_enumerate_new (manager->udev_context); ++ udev_enumerate_add_match_subsystem (matches, subsystem); ++ udev_enumerate_scan_devices (matches); ++ ++ udev_list_entry_foreach (entry, udev_enumerate_get_list_entry (matches)) + { +- struct udev_device *fb_device = NULL; +- const char *fb_path; ++ struct udev_device *device = NULL; ++ const char *path; + +- fb_path = udev_list_entry_get_name (fb_entry); ++ path = udev_list_entry_get_name (entry); + +- if (fb_path == NULL) ++ if (path == NULL) + { +- ply_trace ("fb path was null!"); ++ ply_trace ("path was null!"); + continue; + } + +- ply_trace ("found device %s", fb_path); ++ ply_trace ("found device %s", path); + +- /* skip virtual fbcon device +- */ +- if (strcmp (fb_path, "/sys/devices/virtual/graphics/fbcon") == 0) +- { +- ply_trace ("ignoring since it's fbcon"); +- continue; +- } +- +- fb_device = udev_device_new_from_syspath (manager->udev_context, fb_path); ++ device = udev_device_new_from_syspath (manager->udev_context, path); + + /* if device isn't fully initialized, we'll get an add event later + */ +- if (udev_device_get_is_initialized (fb_device)) ++ if (udev_device_get_is_initialized (device)) + { + ply_trace ("device is initialized"); ++ + /* We only care about devices assigned to a (any) seat. Floating +- * devices should be ignored. As a side-effect, this conveniently +- * filters out the fbcon device which we don't care about. ++ * devices should be ignored. + */ +- if (udev_device_has_tag (fb_device, "seat")) ++ if (udev_device_has_tag (device, "seat")) + { +- const char *fb_node; +- fb_node = udev_device_get_devnode (fb_device); +- if (fb_node != NULL) ++ const char *node; ++ node = udev_device_get_devnode (device); ++ if (node != NULL) + { +- ply_trace ("found node %s", fb_node); ++ ply_trace ("found node %s", node); + found_device = true; +- create_seat_for_udev_device (manager, fb_device); ++ create_seat_for_udev_device (manager, device); + } + } + else + { + ply_trace ("device doesn't have a seat tag"); + } + } + else + { + ply_trace ("it's not initialized"); + } + +- udev_device_unref (fb_device); ++ udev_device_unref (device); + } + +- udev_enumerate_unref (fb_matches); ++ udev_enumerate_unref (matches); + + return found_device; + } + + static void +-on_udev_graphics_event (ply_device_manager_t *manager) ++on_udev_event (ply_device_manager_t *manager) + { + struct udev_device *device; + const char *action; + + device = udev_monitor_receive_device (manager->udev_monitor); + if (device == NULL) + return; + + action = udev_device_get_action (device); + + ply_trace ("got %s event for device %s", action, udev_device_get_sysname (device)); + + if (action == NULL) + return; + + if (strcmp (action, "add") == 0) + create_seat_for_udev_device (manager, device); + else if (strcmp (action, "remove") == 0) + free_seat_for_udev_device (manager, device); + + udev_device_unref (device); + } + + static void + watch_for_udev_events (ply_device_manager_t *manager) + { + int fd; + assert (manager != NULL); + assert (manager->udev_monitor == NULL); + + ply_trace ("watching for udev graphics device add and remove events"); + + manager->udev_monitor = udev_monitor_new_from_netlink (manager->udev_context, "udev"); + +- /* The filter matching here mimics the matching done in scan_graphics_devices. +- * See the comments in that function, for an explanation of what we're doing. +- */ +- udev_monitor_filter_add_match_subsystem_devtype (manager->udev_monitor, "graphics", NULL); ++ udev_monitor_filter_add_match_subsystem_devtype (manager->udev_monitor, SUBSYSTEM_DRM, NULL); ++ udev_monitor_filter_add_match_subsystem_devtype (manager->udev_monitor, SUBSYSTEM_FRAME_BUFFER, NULL); + udev_monitor_filter_add_match_tag (manager->udev_monitor, "seat"); + udev_monitor_enable_receiving (manager->udev_monitor); + + fd = udev_monitor_get_fd (manager->udev_monitor); + ply_event_loop_watch_fd (manager->loop, + fd, + PLY_EVENT_LOOP_FD_STATUS_HAS_DATA, + (ply_event_handler_t) +- on_udev_graphics_event, ++ on_udev_event, + NULL, + manager); + } + + static void + free_seats (ply_device_manager_t *manager) + { + ply_list_node_t *node; + + ply_trace ("removing seats"); + node = ply_list_get_first_node (manager->seats); + while (node != NULL) + { + ply_seat_t *seat; + ply_list_node_t *next_node; + + seat = ply_list_node_get_data (node); + next_node = ply_list_get_next_node (manager->seats, node); + + if (manager->seat_removed_handler != NULL) + manager->seat_removed_handler (manager->seat_event_handler_data, seat); + + ply_seat_free (seat); + ply_list_remove_node (manager->seats, node); + + node = next_node; + } + } + + static void +@@ -657,77 +652,78 @@ create_seats_from_terminals (ply_device_manager_t *manager) + int num_consoles; + + ply_trace ("checking for consoles"); + + if (manager->flags & PLY_DEVICE_MANAGER_FLAGS_IGNORE_SERIAL_CONSOLES) + { + num_consoles = 0; + ply_trace ("ignoring all consoles but default console because explicitly told to."); + } + else + { + num_consoles = add_consoles_from_file (manager, "/sys/class/tty/console/active"); + + if (num_consoles == 0) + ply_trace ("ignoring all consoles but default console because /sys/class/tty/console/active could not be read"); + } + + if (num_consoles > 1) + { + ply_trace ("serial consoles detected, managing them with details forced"); + ply_hashtable_foreach (manager->terminals, + (ply_hashtable_foreach_func_t *) + create_seat_for_terminal, + manager); + return true; + } + + return false; + } + +-static bool ++static void + create_seats_from_udev (ply_device_manager_t *manager) + { +- bool found_device; ++ bool found_drm_device, found_fb_device; + + ply_trace ("Looking for devices from udev"); +- found_device = scan_graphics_devices (manager); +- if (!found_device) +- { +- ply_trace ("Creating non-graphical seat, since there's no suitable graphics hardware"); +- create_seat_for_terminal_and_renderer_type (manager, +- ply_terminal_get_name (manager->local_console_terminal), +- manager->local_console_terminal, +- PLY_RENDERER_TYPE_NONE); +- } + +- return true; ++ found_drm_device = create_seats_for_subsystem (manager, SUBSYSTEM_DRM); ++ found_fb_device = create_seats_for_subsystem (manager, SUBSYSTEM_FRAME_BUFFER); ++ ++ if (found_drm_device || found_fb_device) ++ return; ++ ++ ply_trace ("Creating non-graphical seat, since there's no suitable graphics hardware"); ++ create_seat_for_terminal_and_renderer_type (manager, ++ ply_terminal_get_name (manager->local_console_terminal), ++ manager->local_console_terminal, ++ PLY_RENDERER_TYPE_NONE); + } + + static void + create_fallback_seat (ply_device_manager_t *manager) + { + create_seat_for_terminal_and_renderer_type (manager, + ply_terminal_get_name (manager->local_console_terminal), + manager->local_console_terminal, + PLY_RENDERER_TYPE_AUTO); + } + + static void + on_udev_queue_changed (ply_device_manager_t *manager) + { + + if (!udev_queue_get_queue_is_empty (manager->udev_queue)) + return; + + ply_trace ("udev coldplug complete"); + ply_event_loop_stop_watching_fd (manager->loop, manager->udev_queue_fd_watch); + manager->udev_queue_fd_watch = NULL; + udev_queue_unref (manager->udev_queue); + + close (manager->udev_queue_fd); + manager->udev_queue_fd = -1; + + manager->udev_queue = NULL; + + create_seats_from_udev (manager); + } +-- +1.8.3.1 + + +From 20603c552e7e31f65f6265ed7230ba4bcaf12bf5 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Mon, 3 Mar 2014 17:25:44 -0500 +Subject: [PATCH 2/2] device-manager: defer /dev/fb compat processing until + after coldplug + +We never want to use a /dev/fb device if a DRM device will work instead +(since it supports multi-monitor, isn't a legacy interface, etc) + +Unfortunately, right now plymouthd notices efifb at early start up, +see's there is no DRM device associated with it and chooses it for +the main display, which causes all sort of problems. + +This commit defers using /dev/fb devices until after udev settles. +--- + src/libply-splash-core/ply-device-manager.c | 24 +++++++++++++++++++++--- + 1 file changed, 21 insertions(+), 3 deletions(-) + +diff --git a/src/libply-splash-core/ply-device-manager.c b/src/libply-splash-core/ply-device-manager.c +index 25f7d54..d06e1b5 100644 +--- a/src/libply-splash-core/ply-device-manager.c ++++ b/src/libply-splash-core/ply-device-manager.c +@@ -161,62 +161,63 @@ fb_device_has_drm_device (ply_device_manager_t *manager, + ply_trace ("no card entry!"); + } + + udev_enumerate_unref (card_matches); + return has_drm_device; + } + + static void + create_seat_for_udev_device (ply_device_manager_t *manager, + struct udev_device *device) + { + bool for_local_console; + const char *device_path; + ply_terminal_t *terminal = NULL; + + for_local_console = device_is_for_local_console (manager, device); + + ply_trace ("device is for local console: %s", for_local_console? "yes" : "no"); + + if (for_local_console) + terminal = manager->local_console_terminal; + + device_path = udev_device_get_devnode (device); + + if (device_path != NULL) + { + const char *subsystem; + ply_renderer_type_t renderer_type = PLY_RENDERER_TYPE_NONE; + + subsystem = udev_device_get_subsystem (device); ++ ply_trace ("device subsystem is %s", subsystem); + +- if (strcmp (subsystem, SUBSYSTEM_DRM) == 0) ++ if (subsystem != NULL && strcmp (subsystem, SUBSYSTEM_DRM) == 0) + { + ply_trace ("found DRM device %s", device_path); + renderer_type = PLY_RENDERER_TYPE_DRM; + } + else if (strcmp (subsystem, SUBSYSTEM_FRAME_BUFFER) == 0) + { + ply_trace ("found frame buffer device %s", device_path); + if (!fb_device_has_drm_device (manager, device)) + { + renderer_type = PLY_RENDERER_TYPE_FRAME_BUFFER; + } + else + { + ply_trace ("ignoring, since there's a DRM device associated with it"); + } + } + + if (renderer_type != PLY_RENDERER_TYPE_NONE) + create_seat_for_terminal_and_renderer_type (manager, + device_path, + terminal, + renderer_type); + } + } + + static void + free_seat_from_device_path (ply_device_manager_t *manager, + const char *device_path) + { + ply_list_node_t *node; +@@ -332,63 +333,80 @@ create_seats_for_subsystem (ply_device_manager_t *manager, + { + ply_trace ("it's not initialized"); + } + + udev_device_unref (device); + } + + udev_enumerate_unref (matches); + + return found_device; + } + + static void + on_udev_event (ply_device_manager_t *manager) + { + struct udev_device *device; + const char *action; + + device = udev_monitor_receive_device (manager->udev_monitor); + if (device == NULL) + return; + + action = udev_device_get_action (device); + + ply_trace ("got %s event for device %s", action, udev_device_get_sysname (device)); + + if (action == NULL) + return; + + if (strcmp (action, "add") == 0) +- create_seat_for_udev_device (manager, device); ++ { ++ const char *subsystem; ++ bool coldplug_complete = manager->udev_queue_fd_watch == NULL; ++ ++ subsystem = udev_device_get_subsystem (device); ++ ++ if (strcmp (subsystem, SUBSYSTEM_DRM) == 0 || ++ coldplug_complete) ++ { ++ create_seat_for_udev_device (manager, device); ++ } ++ else ++ { ++ ply_trace ("ignoring since we only handle subsystem %s devices after coldplug completes", subsystem); ++ } ++ } + else if (strcmp (action, "remove") == 0) +- free_seat_for_udev_device (manager, device); ++ { ++ free_seat_for_udev_device (manager, device); ++ } + + udev_device_unref (device); + } + + static void + watch_for_udev_events (ply_device_manager_t *manager) + { + int fd; + assert (manager != NULL); + assert (manager->udev_monitor == NULL); + + ply_trace ("watching for udev graphics device add and remove events"); + + manager->udev_monitor = udev_monitor_new_from_netlink (manager->udev_context, "udev"); + + udev_monitor_filter_add_match_subsystem_devtype (manager->udev_monitor, SUBSYSTEM_DRM, NULL); + udev_monitor_filter_add_match_subsystem_devtype (manager->udev_monitor, SUBSYSTEM_FRAME_BUFFER, NULL); + udev_monitor_filter_add_match_tag (manager->udev_monitor, "seat"); + udev_monitor_enable_receiving (manager->udev_monitor); + + fd = udev_monitor_get_fd (manager->udev_monitor); + ply_event_loop_watch_fd (manager->loop, + fd, + PLY_EVENT_LOOP_FD_STATUS_HAS_DATA, + (ply_event_handler_t) + on_udev_event, + NULL, + manager); + } + +-- +1.8.3.1 + diff --git a/SOURCES/improve-man-pages.patch b/SOURCES/improve-man-pages.patch deleted file mode 100644 index e6f9083..0000000 --- a/SOURCES/improve-man-pages.patch +++ /dev/null @@ -1,918 +0,0 @@ -From 740aa102eec65abf8dcfeeac043ecbcde74f2bf8 Mon Sep 17 00:00:00 2001 -From: Matthias Clasen -Date: Mon, 21 Oct 2013 17:53:33 -0400 -Subject: [PATCH] docs: add docbook based man pages - -This commit adds man pages for the plymouthd and plymouth client -commands. ---- - Makefile.am | 6 +- - configure.ac | 12 ++ - docs/Makefile.am | 33 +++- - docs/plymouth-set-default-theme.xml | 103 +++++++++++ - docs/plymouth.8 | 62 ------- - docs/plymouth.xml | 86 +++++++++ - docs/plymouth1.xml | 351 ++++++++++++++++++++++++++++++++++++ - docs/plymouthd.xml | 121 +++++++++++++ - 8 files changed, 708 insertions(+), 66 deletions(-) - create mode 100644 docs/plymouth-set-default-theme.xml - delete mode 100644 docs/plymouth.8 - create mode 100644 docs/plymouth.xml - create mode 100644 docs/plymouth1.xml - create mode 100644 docs/plymouthd.xml - -diff --git a/Makefile.am b/Makefile.am -index b322463..395c91b 100644 ---- a/Makefile.am -+++ b/Makefile.am -@@ -1,13 +1,17 @@ --SUBDIRS = src themes images scripts docs systemd-units -+SUBDIRS = src themes images scripts systemd-units -+ -+if BUILD_DOCUMENTATION -+SUBDIRS += docs -+endif - - DISTCHECK_CONFIGURE_FLAGS = --disable-tests --without-system-root-install - - EXTRA_DIST = ChangeLog \ - README - - MAINTAINERCLEANFILES = aclocal.m4 \ - config.h.in \ - config.h.in~ \ - config.sub \ - configure \ - Makefile.in -diff --git a/configure.ac b/configure.ac -index bb0207d..6b957d9 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -198,60 +198,72 @@ if test x$enable_libdrm_nouveau = xyes; then - fi - - AC_ARG_ENABLE(libkms, AS_HELP_STRING([--enable-libkms],[enable building with libkms support]),enable_libkms=$enableval,enable_libkms=no) - AM_CONDITIONAL(ENABLE_LIBKMS, [test "$enable_libkms" = yes]) - - if test x$enable_libkms = xyes; then - PKG_CHECK_MODULES(LIBKMS, [libdrm libkms]) - AC_SUBST(LIBKMS_CFLAGS) - AC_SUBST(LIBKMS_LIBS) - AC_DEFINE(PLY_ENABLE_LIBKMS, 1, [Enable support for libkms abstraction over drm drivers]) - fi - - AC_ARG_ENABLE(drm, AS_HELP_STRING([--enable-drm-renderer],[enable building drm kms support]),enable_drm_renderer=$enableval,enable_drm_renderer=yes) - AM_CONDITIONAL(ENABLE_DRM_RENDERER, [test "$enable_drm_renderer" = yes]) - - if test x$enable_drm_renderer = xyes; then - PKG_CHECK_MODULES(DRM, [libdrm]) - fi - - DRM_CFLAGS="$DRM_CFLAGS $DRM_INTEL_CFLAGS $DRM_RADEON_CFLAGS $DRM_NOUVEAU_CFLAGS $LIBKMS_CFLAG" - DRM_LIBS="$DRM_LIBS $DRM_INTEL_LIBS $DRM_RADEON_LIBS $DRM_NOUVEAU_LIBS $LIBKMS_LIBS" - AC_SUBST(DRM_CFLAGS) - AC_SUBST(DRM_LIBS) - - AC_ARG_ENABLE(tracing, AS_HELP_STRING([--enable-tracing],[enable verbose tracing code]),enable_tracing=$enableval,enable_tracing=yes) - - if test x$enable_tracing = xyes; then - AC_DEFINE(PLY_ENABLE_TRACING, 1, [Build in verbose debug tracing spew]) - fi - -+AC_ARG_ENABLE(documentation, -+ AS_HELP_STRING([--enable-documentation], -+ [build documentation]),, -+ enable_documentation=yes) -+if test x$enable_documentation = xyes; then -+ AC_PATH_PROG([XSLTPROC], [xsltproc]) -+ if test x$XSLTPROC = x; then -+ AC_MSG_ERROR([xsltproc is required to build documentation]) -+ fi -+fi -+AM_CONDITIONAL(BUILD_DOCUMENTATION, test x$enable_documentation = xyes) -+ - AC_ARG_ENABLE(tests, AS_HELP_STRING([--enable-tests],[build tests]),enable_tests=$enableval,enable_tests=yes) - - AM_CONDITIONAL(ENABLE_TESTS, [test "$enable_tests" = yes]) - - AC_ARG_ENABLE(gdm-transition, AS_HELP_STRING([--enable-gdm-transition],[enable smooth transition to gdm]),enable_gdm_transition=$enableval,enable_gdm_transition=no) - - if test x$enable_gdm_transition = xyes; then - AC_DEFINE(PLY_ENABLE_DEPRECATED_GDM_TRANSITION, 1, [Enable deprecated smooth transition to GDM]) - fi - - AC_ARG_ENABLE(upstart-monitoring, AS_HELP_STRING([--enable-upstart-monitoring],[listen for messages on the Upstart D-Bus interface]),enable_upstart_monitoring=$enableval,enable_upstart_monitoring=no) - if test x$enable_upstart_monitoring = xyes; then - PKG_CHECK_MODULES(DBUS, [dbus-1]) - AC_SUBST(DBUS_CFLAGS) - AC_SUBST(DBUS_LIBS) - AC_CHECK_HEADERS([ncursesw/term.h ncurses/term.h term.h], [break]) - AC_CHECK_LIB([ncursesw], [initscr], - [CURSES_LIBS="$CURSES_LIBS -lncursesw"], - [AC_CHECK_LIB([ncurses], [initscr], - [CURSES_LIBS="$CURSES_LIBS -lncurses"], - [AC_CHECK_LIB([curses], [initscr], - [CURSES_LIBS="$CURSES_LIBS -lcurses"], - [AC_MSG_ERROR([no curses library found])])])]) - AC_SUBST(CURSES_LIBS) - fi - AM_CONDITIONAL(ENABLE_UPSTART_MONITORING, [test "$enable_upstart_monitoring" = yes]) - - AC_ARG_ENABLE(systemd-integration, AS_HELP_STRING([--enable-systemd-integration],[coordinate boot up with systemd]),enable_systemd_integration=$enableval,enable_systemd_integration=no) - AM_CONDITIONAL(ENABLE_SYSTEMD_INTEGRATION, [test "$enable_systemd_integration" = yes]) - -diff --git a/docs/Makefile.am b/docs/Makefile.am -index dedda55..1a9f7ea 100644 ---- a/docs/Makefile.am -+++ b/docs/Makefile.am -@@ -1,4 +1,31 @@ --dist_man_MANS = plymouth.8 -+XSLTPROC_FLAGS = \ -+ --nonet \ -+ --stringparam man.output.quietly 1 \ -+ --stringparam funcsynopsis.style ansi \ -+ --stringparam man.th.extra1.suppress 1 \ -+ --stringparam man.authors.section.enabled 0 \ -+ --stringparam man.copyright.section.enabled 0 - --%.html: %.txt -- asciidoc $(ASCIIDOC_OPTS) -a toc $*.txt -+ -+plymouth.1: plymouth1.xml -+ $(AM_V_GEN) $(XSLTPROC) $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $< -+ -+%.8: %.xml -+ $(AM_V_GEN) $(XSLTPROC) $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $< -+ -+%.1: %.xml -+ $(AM_V_GEN) $(XSLTPROC) $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $< -+ -+man_MANS = \ -+ plymouth.1 \ -+ plymouth.8 \ -+ plymouthd.8 \ -+ plymouth-set-default-theme.1 -+ -+EXTRA_DIST = \ -+ plymouth.xml \ -+ plymouth1.xml \ -+ plymouth-set-default-theme.xml \ -+ plymouthd.xml -+ -+CLEANFILES = $(man_MANS) -diff --git a/docs/plymouth-set-default-theme.xml b/docs/plymouth-set-default-theme.xml -new file mode 100644 -index 0000000..efb051e ---- /dev/null -+++ b/docs/plymouth-set-default-theme.xml -@@ -0,0 +1,103 @@ -+ -+ -+ -+ -+ -+ -+ plymouth-set-default-theme -+ plymouth -+ -+ -+ -+ Developer -+ Kristian -+ Høgsberg -+ -+ -+ Developer -+ Ray -+ Strode -+ -+ -+ -+ -+ -+ -+ plymouth-set-default-theme -+ 1 -+ User Commands -+ -+ -+ -+ plymouth-set-default-theme -+ Set the plymouth theme -+ -+ -+ -+ -+ plymouth-set-default-theme OPTION THEME -+ -+ -+ -+ -+ Description -+ -+ -+When called with a argument, -+the plymouth-set-default-theme command -+changes the preferred boot theme and also performs the necessary -+regeneration of the initial ramdisk (initrd) since plymouth is loaded -+from the boot loader from the initrd prior to the mounting of the root -+filesystem. -+ -+ -+ -+If plymouth-set-default-theme is invoked with no options -+or parameters, it shows the currently selected theme by default. This output -+is used by the helper scripts plymouth-generate-initrd and -+plymouth-update-initrd to set the proper theme in the initial ramdisk. -+ -+ -+ -+ -+ -+ Options -+ -+ The following options are understood: -+ -+ -+ -+ , -+ Show summary of options. -+ -+ -+ -+ , -+ List available themes. -+ -+ -+ -+ , -+ Reset to default theme. -+ -+ -+ -+ , -+ Rebuild initrd (necessary after changing theme). -+ -+ -+ -+ -+ -+ See Also -+ -+ grub8, -+ plymouth8, -+ plymouthd8, -+ plymouth1, -+ http://www.freedesktop.org/wiki/Software/Plymouth -+ -+ -+ -+ -diff --git a/docs/plymouth.8 b/docs/plymouth.8 -deleted file mode 100644 -index 7f4766b..0000000 ---- a/docs/plymouth.8 -+++ /dev/null -@@ -1,62 +0,0 @@ --\" Hey, EMACS: -*- nroff -*- --.TH PLYMOUTH 8 "December 15, 2009" --.SH NAME --plymouth \- A graphical boot system and logger --.SH SYNOPSIS --.B plymouth-set-default-theme --.RI [ options ] " \" --.SH DESCRIPTION --\fBplymouth\fP is a graphical boot system for Linux which takes advantage of the kernel-based --mode setting (KMS) available for modern graphic cards to provide a seamless, flickerfree --and attractive boot screen. It allows to choose between various, static or --animated graphical themes to spruce up the startup and avoid the noise --generated by the vast amount of kernel messages while the machine boots into X. --On systems where kernel-based mode setting is not available, plymouth falls --back to a text mode boot screen which provides a simple progress bar to provide --feedback during boot. --.PP --To configure plymouth, that is to choose and install the preferred boot theme, the --user has to invoke \fBplymouth-set-default-theme\fP. It changes the configuration --to the new theme and also performs the necessary regeneration of the initial ramdisk --(initrd) since plymouth is loaded from the boot loader from the initrd --prior to the mounting of the root filesystem. The options available to this --script are explained in the \fBOPTIONS\fP paragraph. --.PP --In order for the configured default plymouth theme to be loaded during boot, --the option `splash' (or `rhgb' for backward compatibility with the RHGB boot --splash) must be provided at the kernel command line. With this command line --option, plymouth will default to showing detailed boot output. --.SH OPTIONS --plymouth-set-default-theme follows the usual GNU command line syntax, with long --options starting with two dashes (`-') and short variants of each of them. --.TP --.B \-h, \-\-help --Show summary of options. --.TP --.B \-l, \-\-list --List available themes. --.TP --.B \-r, \-\-reset --Reset to default theme. --.TP --.B \-R, \-\-rebuild\-initrd --Rebuild initrd (necessary after changing theme). --.TP --.B \ --Name of new theme to use. If you want to see which themes are available, invoke the script with just \-\-list. --.PP --If plymouth-set-default-theme is invoked with no options or parameters, it shows the currently selected theme --by default. This output is used by the helper scripts `plymouth-generate-initrd' and `plymouth-update-initrd' --to set the proper theme in the initial ramdisk. --.SH SEE ALSO --.BR grub (8) --.br --.SH AUTHOR --plymouth was originally prototyped and named by Kristian Høgsberg , --originally written by Ray Strode and has had significant contributions --from Charlie Brej . It has also had contributions from --Peter Jones , Adam Jackson , --Frederic Crozat and others. --It can be downloaded here: . --.PP --This manual page was written by Adrian Glaubitz . -diff --git a/docs/plymouth.xml b/docs/plymouth.xml -new file mode 100644 -index 0000000..0f196c6 ---- /dev/null -+++ b/docs/plymouth.xml -@@ -0,0 +1,86 @@ -+ -+ -+ -+ -+ -+ -+ plymouth -+ plymouth -+ -+ -+ -+ Developer -+ Kristian -+ Høgsberg -+ -+ -+ Developer -+ Ray -+ Strode -+ -+ -+ -+ -+ -+ -+ plymouth -+ 8 -+ System Administration -+ -+ -+ -+ plymouth -+ A graphical boot system and logger -+ -+ -+ -+ Description -+ -+ -+plymouth is a graphical boot system for Linux which takes advantage of -+the kernel-based mode setting (KMS) available for modern graphic cards -+to provide a seamless, flickerfree and attractive boot screen. It -+allows to choose between various, static or animated graphical themes -+to spruce up the startup and avoid the noise generated by the vast -+amount of kernel messages while the machine boots into X. On systems -+where kernel-based mode setting is not available, plymouth falls back -+to a text mode boot screen which provides a simple progress bar to pro‐ -+vide feedback during boot. -+ -+ -+In order for the configured default plymouth theme to be loaded during -+boot, the option `splash' (or `rhgb' for backward compatibility with -+the RHGB boot splash) must be provided at the kernel command line. -+Without this command line option, plymouth will default to showing -+detailed boot output. -+ -+ -+ -+During the boot process, the user can switch between the graphical theme -+and the detailed boot output using the Escape key. -+ -+ -+ -+ -+ -+ See Also -+ -+ grub8, -+ plymouth-set-theme1, -+ plymouthd8, -+ plymouth1, -+ http://www.freedesktop.org/wiki/Software/Plymouth -+ -+ -+ -+ -+ Authors -+ -+plymouth was originally prototyped and named by Kristian Høgsberg, -+originally written by Ray Strode and has had significant contributions from -+Charlie Brej. It has also had contributions from Peter Jones, Adam Jackson, -+Frederic Crozat and others. -+ -+ -+ -diff --git a/docs/plymouth1.xml b/docs/plymouth1.xml -new file mode 100644 -index 0000000..b484599 ---- /dev/null -+++ b/docs/plymouth1.xml -@@ -0,0 +1,351 @@ -+ -+ -+ -+ -+ -+ -+ plymouth -+ plymouth -+ -+ -+ -+ Developer -+ Kristian -+ Høgsberg -+ -+ -+ Developer -+ Ray -+ Strode -+ -+ -+ -+ -+ -+ -+ plymouth -+ 1 -+ User Commands -+ -+ -+ -+ plymouth -+ Send commands to plymouthd -+ -+ -+ -+ -+ plymouth OPTION -+ -+ -+ plymouth COMMAND OPTION -+ -+ -+ -+ -+ Description -+ -+ -+The plymouth sends commands to a running -+plymouthd. This is used during the boot -+process to control the display of the graphical boot splash. -+ -+ -+ -+ -+ -+ Options -+ -+ -+The following options are understood. These options are supported -+for compatibility with the old rhgb-client interface, -+and have been replaced by the commands that are described in the -+next section. -+ -+ -+ -+ -+ -+ Show summary of options. -+ -+ -+ -+ -+ Enable verbose debug logging. -+ -+ -+ -+ -+ Get directory where splash plugins are installed. -+ -+ -+ -+ -+ Tell plymouthd that the new root filesystem is mounted. -+ -+ -+ -+ -+ Tell plymouthd to quit. -+ -+ -+ -+ -+ Check if plymouthd is running. -+ -+ -+ -+ -+ Check if plymouthd has an active vt. -+ -+ -+ -+ -+ Tell plymouthd root filesystem is mounted read-write. -+ -+ -+ -+ -+ Show the splash screen. -+ -+ -+ -+ -+ Hide the splash screen. -+ -+ -+ -+ -+ Ask the user for a password. -+ -+ -+ -+ -+ Remove sensitivity to a keystroke. -+ -+ -+ -+ -+ Tell plymouthd an update about boot progress. -+ -+ -+ -+ -+ Tell plymouthd there were errors during boot. -+ -+ -+ -+ -+ Wait for plymouthd to quit. -+ -+ -+ -+ -+ -+ Commands -+ -+ -+The following commands are understood: -+ -+ -+ -+ change-mode OPTION -+ Change the operation mode. -+ -+ -+ -+ Start the system up -+ -+ -+ -+ Shutting the system up -+ -+ -+ -+ Applying updates -+ -+ -+ -+ -+ -+ system-update OPTION -+ Tell plymouthd about boot progress. -+ -+ -+ -+ The percentage progress of the updates -+ -+ -+ -+ -+ -+ update OPTION -+ Tell plymouthd about boot status changes. -+ -+ -+ -+ Tell plymouthd the current boot status -+ -+ -+ -+ -+ -+ update-root-fs OPTION -+ Tell plymouthd about root filesystem changes. -+ -+ -+ -+ Root filesystem is about to change -+ -+ -+ -+ Root filesystem is no longer read-only -+ -+ -+ -+ -+ -+ show-splash -+ Tell plymouthd to show splash screen. -+ -+ -+ hide-splash -+ Tell plymouthd to hide splash screen. -+ -+ -+ ask-for-password OPTION -+ Ask the user for a password. -+ -+ -+ -+ Command to send password to via standard input -+ -+ -+ -+ Message to display when asking for password -+ -+ -+ -+ Number of times to ask before giving up (requires ) -+ -+ -+ -+ Don't pause boot progress bar while asking -+ -+ -+ -+ -+ -+ ask-question -+ Ask the user a question. -+ -+ -+ -+ Command to send the answer to via standard input -+ -+ -+ -+ Message to display when asking the question -+ -+ -+ -+ Don't pause boot progress bar while asking -+ -+ -+ -+ -+ -+ display-message OPTION -+ Display a message. -+ -+ -+ -+ The message text -+ -+ -+ -+ -+ -+ hide-message OPTION -+ Hide a message. -+ -+ -+ -+ The message text -+ -+ -+ -+ -+ -+ watch-keystroke OPTION -+ Become sensitive to a keystroke. -+ -+ -+ -+ Command to send keystroke to via standard input -+ -+ -+ -+ Keys to become sensitive to -+ -+ -+ -+ -+ -+ ignore-keystroke OPTION -+ Remove sensitivity to a keystroke. -+ -+ -+ -+ Keys to remove sensitivitiy from -+ -+ -+ -+ -+ -+ pause-progress -+ Pause boot progress bar. -+ -+ -+ unpause-progress -+ Unpause boot progress bar. -+ -+ -+ report-error -+ Tell plymouthd there were errors during boot. -+ -+ -+ deactivate -+ Tell plymouthd to deactivate. -+ -+ -+ reactivate -+ Tell plymouthd to reactivate. -+ -+ -+ quit OPTION -+ Tell plymouthd to quit. -+ -+ -+ -+ Don't explicitly hide boot splash on exit -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ See Also -+ -+ grub8, -+ plymouth8, -+ plymouthd8, -+ http://www.freedesktop.org/wiki/Software/Plymouth -+ -+ -+ -+ -diff --git a/docs/plymouthd.xml b/docs/plymouthd.xml -new file mode 100644 -index 0000000..4e7e499 ---- /dev/null -+++ b/docs/plymouthd.xml -@@ -0,0 +1,121 @@ -+ -+ -+ -+ -+ -+ -+ plymouthd -+ plymouth -+ -+ -+ -+ Developer -+ Kristian -+ Høgsberg -+ -+ -+ Developer -+ Ray -+ Strode -+ -+ -+ -+ -+ -+ -+ plymouthd -+ 8 -+ System Administration -+ -+ -+ -+ plymouthd -+ The plymouth daemon -+ -+ -+ -+ -+ plymouthd OPTION -+ -+ -+ -+ -+ Description -+ -+ -+The plymouthd daemon is usually run out of -+the initrd. It does the heavy lifting of the plymouth system, logging -+the session and showing the splash screen. -+ -+ -+The plymouth is used to send commands to plymouthd -+that control its behaviour. -+ -+ -+ -+ -+ -+ Options -+ -+ The following options are understood: -+ -+ -+ -+ -+ Show summary of options. -+ -+ -+ -+ -+ Redirect console messages from screen to log. -+ -+ -+ -+ -+ Do not daemonize. -+ -+ -+ -+ -+ Output debugging information. -+ -+ -+ -+ -+ File to write debugging information to. -+ -+ -+ -+ -+ Set mode to either boot or shutdown. -+ -+ -+ -+ -+ Write the PID of the daemon to a file. -+ -+ -+ -+ -+ Fake kernel commandline to use. -+ -+ -+ -+ -+ TTY to ues instead of default. -+ -+ -+ -+ -+ -+ See Also -+ -+ grub8, -+ plymouth8, -+ plymouth1, -+ http://www.freedesktop.org/wiki/Software/Plymouth -+ -+ -+ -+ --- -1.8.3.1 - diff --git a/SOURCES/plymouth-update-initrd b/SOURCES/plymouth-update-initrd new file mode 100755 index 0000000..4ed5709 --- /dev/null +++ b/SOURCES/plymouth-update-initrd @@ -0,0 +1,2 @@ +#!/bin/bash +dracut -f diff --git a/SOURCES/serial-console-fixes.patch b/SOURCES/serial-console-fixes.patch new file mode 100644 index 0000000..6c93491 --- /dev/null +++ b/SOURCES/serial-console-fixes.patch @@ -0,0 +1,541 @@ +From 8a1dfbe91c1b309d361b4053e05bd5e01056fd41 Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Mon, 3 Mar 2014 17:55:59 -0500 +Subject: [PATCH 1/4] device-manager: ignore udev if only console is serial + console + +Right now we use the heuristic, "more than one entry in +/sys/class/tty/console/active" to mean "has serial consoles". + +We used to use the heuristic "file has more than tty0 in it". +The older heuristic is more accurate because a user may have +console=ttyS0 without console=tty0 on the kernel command line. +--- + src/libply-splash-core/ply-device-manager.c | 27 +++++++++++++-------------- + 1 file changed, 13 insertions(+), 14 deletions(-) + +diff --git a/src/libply-splash-core/ply-device-manager.c b/src/libply-splash-core/ply-device-manager.c +index d06e1b5..098fd85 100644 +--- a/src/libply-splash-core/ply-device-manager.c ++++ b/src/libply-splash-core/ply-device-manager.c +@@ -514,204 +514,203 @@ ply_device_manager_new (const char *default_tty, + return manager; + } + + void + ply_device_manager_free (ply_device_manager_t *manager) + { + ply_trace ("freeing device manager"); + + if (manager == NULL) + return; + + ply_event_loop_stop_watching_for_exit (manager->loop, + (ply_event_loop_exit_handler_t) + detach_from_event_loop, + manager); + free_seats (manager); + ply_list_free (manager->seats); + + free_terminals (manager); + ply_hashtable_free (manager->terminals); + + if (manager->udev_monitor != NULL) + udev_monitor_unref (manager->udev_monitor); + + if (manager->udev_context != NULL) + udev_unref (manager->udev_context); + + free (manager); + } + +-static int ++static bool + add_consoles_from_file (ply_device_manager_t *manager, + const char *path) + { + int fd; + char contents[512] = ""; + ssize_t contents_length; +- int num_consoles; ++ bool has_serial_consoles; + const char *remaining_file_contents; + + ply_trace ("opening %s", path); + fd = open (path, O_RDONLY); + + if (fd < 0) + { + ply_trace ("couldn't open it: %m"); +- return 0; ++ return false; + } + + ply_trace ("reading file"); + contents_length = read (fd, contents, sizeof (contents) - 1); + + if (contents_length <= 0) + { + ply_trace ("couldn't read it: %m"); + close (fd); +- return 0; ++ return false; + } + close (fd); + + remaining_file_contents = contents; +- num_consoles = 0; ++ has_serial_consoles = false; + + while (remaining_file_contents < contents + contents_length) + { + char *console; + size_t console_length; + const char *console_device; + ply_terminal_t *terminal; + + /* Advance past any leading whitespace */ + remaining_file_contents += strspn (remaining_file_contents, " \n\t\v"); + + if (*remaining_file_contents == '\0') + { + /* There's nothing left after the whitespace, we're done */ + break; + } + + /* Find trailing whitespace and NUL terminate. If strcspn + * doesn't find whitespace, it gives us the length of the string + * until the next NUL byte, which we'll just overwrite with + * another NUL byte anyway. */ + console_length = strcspn (remaining_file_contents, " \n\t\v"); + console = strndup (remaining_file_contents, console_length); + + terminal = get_terminal (manager, console); + console_device = ply_terminal_get_name (terminal); + + free (console); + + ply_trace ("console %s found!", console_device); +- num_consoles++; ++ ++ if (terminal != manager->local_console_terminal) ++ has_serial_consoles = true; + + /* Move past the parsed console string, and the whitespace we + * may have found above. If we found a NUL above and not whitespace, + * then we're going to jump past the end of the buffer and the loop + * will terminate + */ + remaining_file_contents += console_length + 1; + } + +- return num_consoles; ++ return has_serial_consoles; + } + + static void + create_seat_for_terminal_and_renderer_type (ply_device_manager_t *manager, + const char *device_path, + ply_terminal_t *terminal, + ply_renderer_type_t renderer_type) + { + ply_seat_t *seat; + bool is_local_terminal = false; + + if (terminal != NULL && manager->local_console_terminal == terminal) + is_local_terminal = true; + + if (is_local_terminal && manager->local_console_seat != NULL) + { + ply_trace ("trying to create seat for local console when one already exists"); + return; + } + + ply_trace ("creating seat for %s (renderer type: %u) (terminal: %s)", + device_path? : "", renderer_type, terminal? ply_terminal_get_name (terminal): "none"); + seat = ply_seat_new (terminal); + + if (!ply_seat_open (seat, renderer_type, device_path)) + { + ply_trace ("could not create seat"); + ply_seat_free (seat); + return; + } + + ply_list_append_data (manager->seats, seat); + + if (is_local_terminal) + manager->local_console_seat = seat; + + if (manager->seat_added_handler != NULL) + manager->seat_added_handler (manager->seat_event_handler_data, seat); + } + + static void + create_seat_for_terminal (const char *device_path, + ply_terminal_t *terminal, + ply_device_manager_t *manager) + { + create_seat_for_terminal_and_renderer_type (manager, + device_path, + terminal, + PLY_RENDERER_TYPE_NONE); + } + static bool + create_seats_from_terminals (ply_device_manager_t *manager) + { +- int num_consoles; ++ bool has_serial_consoles; + + ply_trace ("checking for consoles"); + + if (manager->flags & PLY_DEVICE_MANAGER_FLAGS_IGNORE_SERIAL_CONSOLES) + { +- num_consoles = 0; ++ has_serial_consoles = false; + ply_trace ("ignoring all consoles but default console because explicitly told to."); + } + else + { +- num_consoles = add_consoles_from_file (manager, "/sys/class/tty/console/active"); +- +- if (num_consoles == 0) +- ply_trace ("ignoring all consoles but default console because /sys/class/tty/console/active could not be read"); ++ has_serial_consoles = add_consoles_from_file (manager, "/sys/class/tty/console/active"); + } + +- if (num_consoles > 1) ++ if (has_serial_consoles) + { + ply_trace ("serial consoles detected, managing them with details forced"); + ply_hashtable_foreach (manager->terminals, + (ply_hashtable_foreach_func_t *) + create_seat_for_terminal, + manager); + return true; + } + + return false; + } + + static void + create_seats_from_udev (ply_device_manager_t *manager) + { + bool found_drm_device, found_fb_device; + + ply_trace ("Looking for devices from udev"); + + found_drm_device = create_seats_for_subsystem (manager, SUBSYSTEM_DRM); + found_fb_device = create_seats_for_subsystem (manager, SUBSYSTEM_FRAME_BUFFER); + + if (found_drm_device || found_fb_device) + return; + + ply_trace ("Creating non-graphical seat, since there's no suitable graphics hardware"); + create_seat_for_terminal_and_renderer_type (manager, + ply_terminal_get_name (manager->local_console_terminal), + manager->local_console_terminal, + PLY_RENDERER_TYPE_NONE); +-- +1.8.3.1 + + +From 5fbfc8d1ec9da9060ebeaf0938afe8e2e0102b3d Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Mon, 3 Mar 2014 18:00:19 -0500 +Subject: [PATCH 2/4] device-manager: be more tolerant of tty active console + value + +Some kernels mistakenly put tty1 instead of tty0 in the file, +so try to cope with them for maximium compatibility. +--- + src/libply-splash-core/ply-device-manager.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/libply-splash-core/ply-device-manager.c b/src/libply-splash-core/ply-device-manager.c +index 098fd85..dbc203d 100644 +--- a/src/libply-splash-core/ply-device-manager.c ++++ b/src/libply-splash-core/ply-device-manager.c +@@ -441,61 +441,62 @@ free_terminal (char *device, + ply_device_manager_t *manager) + { + ply_hashtable_remove (manager->terminals, device); + + ply_terminal_close (terminal); + ply_terminal_free (terminal); + } + + static void + free_terminals (ply_device_manager_t *manager) + { + ply_hashtable_foreach (manager->terminals, + (ply_hashtable_foreach_func_t *) + free_terminal, + manager); + } + + static ply_terminal_t * + get_terminal (ply_device_manager_t *manager, + const char *device_name) + { + char *full_name = NULL; + ply_terminal_t *terminal; + + if (strncmp (device_name, "/dev/", strlen ("/dev/")) == 0) + full_name = strdup (device_name); + else + asprintf (&full_name, "/dev/%s", device_name); + + if (strcmp (full_name, "/dev/tty0") == 0 || +- strcmp (full_name, "/dev/tty") == 0) ++ strcmp (full_name, "/dev/tty") == 0 || ++ strcmp (full_name, ply_terminal_get_name (manager->local_console_terminal)) == 0) + { + terminal = manager->local_console_terminal; + goto done; + } + + terminal = ply_hashtable_lookup (manager->terminals, full_name); + + if (terminal == NULL) + { + terminal = ply_terminal_new (full_name); + + ply_hashtable_insert (manager->terminals, + (void *) ply_terminal_get_name (terminal), + terminal); + } + + done: + free (full_name); + return terminal; + } + + ply_device_manager_t * + ply_device_manager_new (const char *default_tty, + ply_device_manager_flags_t flags) + { + ply_device_manager_t *manager; + + manager = calloc (1, sizeof (ply_device_manager_t)); + manager->loop = NULL; + manager->terminals = ply_hashtable_new (ply_hashtable_string_hash, ply_hashtable_string_compare); +-- +1.8.3.1 + + +From 0d5fae7feb3c2fb462f124940e91fea16298eb1f Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 6 Mar 2014 14:42:16 -0500 +Subject: [PATCH 3/4] seat: make sure to open terminal when adding text + displays + +If we have a pixel display, the renderer will handle opening the +associated terminal. but if we don't have a pixel display, something +needs to open the terminal. + +This commit adds code to do that. +--- + src/libply-splash-core/ply-seat.c | 13 +++++++++++++ + 1 file changed, 13 insertions(+) + +diff --git a/src/libply-splash-core/ply-seat.c b/src/libply-splash-core/ply-seat.c +index 541b29e..2ac8bf7 100644 +--- a/src/libply-splash-core/ply-seat.c ++++ b/src/libply-splash-core/ply-seat.c +@@ -75,60 +75,73 @@ add_pixel_displays (ply_seat_t *seat) + ply_list_node_t *node; + + heads = ply_renderer_get_heads (seat->renderer); + + ply_trace ("Adding displays for %d heads", + ply_list_get_length (heads)); + + node = ply_list_get_first_node (heads); + while (node != NULL) + { + ply_list_node_t *next_node; + ply_renderer_head_t *head; + ply_pixel_display_t *display; + + head = ply_list_node_get_data (node); + next_node = ply_list_get_next_node (heads, node); + + display = ply_pixel_display_new (seat->renderer, head); + + ply_list_append_data (seat->pixel_displays, display); + + node = next_node; + } + } + + static void + add_text_displays (ply_seat_t *seat) + { + ply_text_display_t *display; + ++ if (!ply_terminal_is_open (seat->terminal)) ++ { ++ if (!ply_terminal_open (seat->terminal)) ++ { ++ ply_trace ("could not add terminal %s: %m", ++ ply_terminal_get_name (seat->terminal)); ++ return; ++ } ++ } ++ ++ ply_trace ("adding text display for terminal %s", ++ ply_terminal_get_name (seat->terminal)); ++ + display = ply_text_display_new (seat->terminal); + ply_list_append_data (seat->text_displays, display); + } + + bool + ply_seat_open (ply_seat_t *seat, + ply_renderer_type_t renderer_type, + const char *device) + { + if (renderer_type != PLY_RENDERER_TYPE_NONE) + { + ply_renderer_t *renderer; + + renderer = ply_renderer_new (renderer_type, device, seat->terminal); + + if (!ply_renderer_open (renderer)) + { + ply_trace ("could not open renderer for %s", device); + ply_renderer_free (renderer); + + seat->renderer = NULL; + seat->renderer_active = false; + + if (renderer_type != PLY_RENDERER_TYPE_AUTO) + return false; + } + else + { + seat->renderer = renderer; + seat->renderer_active = true; +-- +1.8.3.1 + + +From aa2f5ac95c7cc0f4eb5f61465ecaf22247c7047c Mon Sep 17 00:00:00 2001 +From: Ray Strode +Date: Thu, 6 Mar 2014 15:31:20 -0500 +Subject: [PATCH 4/4] device-manager: Don't add local console to terminals hash + table unless passed on cmdline + +it's unexpected for plymouth to show boot messages on the local console +if there is not console=tty0 on the kernel command line. + +This commit fixes that. +--- + src/libply-splash-core/ply-device-manager.c | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +diff --git a/src/libply-splash-core/ply-device-manager.c b/src/libply-splash-core/ply-device-manager.c +index dbc203d..8f5360c 100644 +--- a/src/libply-splash-core/ply-device-manager.c ++++ b/src/libply-splash-core/ply-device-manager.c +@@ -445,92 +445,93 @@ free_terminal (char *device, + ply_terminal_close (terminal); + ply_terminal_free (terminal); + } + + static void + free_terminals (ply_device_manager_t *manager) + { + ply_hashtable_foreach (manager->terminals, + (ply_hashtable_foreach_func_t *) + free_terminal, + manager); + } + + static ply_terminal_t * + get_terminal (ply_device_manager_t *manager, + const char *device_name) + { + char *full_name = NULL; + ply_terminal_t *terminal; + + if (strncmp (device_name, "/dev/", strlen ("/dev/")) == 0) + full_name = strdup (device_name); + else + asprintf (&full_name, "/dev/%s", device_name); + + if (strcmp (full_name, "/dev/tty0") == 0 || + strcmp (full_name, "/dev/tty") == 0 || + strcmp (full_name, ply_terminal_get_name (manager->local_console_terminal)) == 0) + { + terminal = manager->local_console_terminal; ++ ++ ply_hashtable_insert (manager->terminals, ++ (void *) ply_terminal_get_name (terminal), ++ terminal); + goto done; + } + + terminal = ply_hashtable_lookup (manager->terminals, full_name); + + if (terminal == NULL) + { + terminal = ply_terminal_new (full_name); + + ply_hashtable_insert (manager->terminals, + (void *) ply_terminal_get_name (terminal), + terminal); + } + + done: + free (full_name); + return terminal; + } + + ply_device_manager_t * + ply_device_manager_new (const char *default_tty, + ply_device_manager_flags_t flags) + { + ply_device_manager_t *manager; + + manager = calloc (1, sizeof (ply_device_manager_t)); + 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); +- ply_hashtable_insert (manager->terminals, +- (void *) ply_terminal_get_name (manager->local_console_terminal), +- manager->local_console_terminal); + manager->seats = ply_list_new (); + manager->flags = flags; + + if (!(flags & PLY_DEVICE_MANAGER_FLAGS_IGNORE_UDEV)) + manager->udev_context = udev_new (); + + attach_to_event_loop (manager, ply_event_loop_get_default ()); + + return manager; + } + + void + ply_device_manager_free (ply_device_manager_t *manager) + { + ply_trace ("freeing device manager"); + + if (manager == NULL) + return; + + ply_event_loop_stop_watching_for_exit (manager->loop, + (ply_event_loop_exit_handler_t) + detach_from_event_loop, + manager); + free_seats (manager); + ply_list_free (manager->seats); + + free_terminals (manager); + ply_hashtable_free (manager->terminals); + + if (manager->udev_monitor != NULL) +-- +1.8.3.1 + diff --git a/SPECS/plymouth.spec b/SPECS/plymouth.spec index a928847..046fc93 100644 --- a/SPECS/plymouth.spec +++ b/SPECS/plymouth.spec @@ -2,16 +2,18 @@ %define plymouthclient_execdir %{_bindir} %define plymouth_libdir %{_libdir} %define plymouth_initrd_file /boot/initrd-plymouth.img +%global _hardened_build 1 Summary: Graphical Boot Animation and Logger Name: plymouth Version: 0.8.9 -Release: 0.2013.03.26.4%{?dist} +Release: 0.10.20140113%{?dist} License: GPLv2+ Group: System Environment/Base Source0: http://freedesktop.org/software/plymouth/releases/%{name}-%{version}.tar.bz2 Source1: boot-duration Source2: charge.plymouth +Source3: plymouth-update-initrd URL: http://www.freedesktop.org/wiki/Software/Plymouth BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -24,6 +26,7 @@ Conflicts: systemd < 185-3 BuildRequires: pkgconfig(libdrm) BuildRequires: kernel-headers +BuildRequires: pkgconfig(libudev) BuildRequires: automake, autoconf, libtool BuildRequires: libxslt, docbook-style-xsl @@ -33,9 +36,15 @@ Obsoletes: plymouth-theme-pulser < 0.7.0-0.2009.05.08.2 Obsoletes: plymouth-gdm-hooks < 0.8.4-0.20101119.4 Obsoletes: plymouth-utils < 0.8.4-0.20101119.4 -Patch2: drm-dirty-fb.patch -Patch3: improve-man-pages.patch -Patch4: add-two-step-features.patch +Patch0: dont-block-show-splash.patch +Patch1: always-add-text-splash.patch +Patch2: fix-text-splash-os-string.patch +Patch3: fix-details.patch +Patch4: fix-startup-race.patch +Patch5: fix-hide-splash.patch +Patch6: ignore-early-fb-devices.patch +Patch7: fix-ask-password-race.patch +Patch8: serial-console-fixes.patch Patch99: colors.patch %description @@ -244,9 +253,15 @@ Plymouth. It features a small spinner on a dark background. %prep %setup -q -%patch2 -p1 -b .drm-dirty -%patch3 -p1 -b .improve-man-pages -%patch4 -p1 -b .add-two-step-features +%patch0 -p1 -b .dont-block-show-splash +%patch1 -p1 -b .always-add-text-splash +%patch2 -p1 -b .fix-text-splash-os-string +%patch3 -p1 -b .fix-details +%patch4 -p1 -b .fix-startup-race +%patch5 -p1 -b .fix-hide-splash +%patch6 -p1 -b .ignore-early-fb-devices +%patch7 -p1 -b .fix-ask-password-race +%patch8 -p1 -b .serial-console-fixes %patch99 -p1 -b .colors # Change the default theme @@ -255,6 +270,7 @@ sed -i -e 's/fade-in/charge/g' src/plymouthd.defaults %build autoreconf -f -i %configure --enable-tracing --disable-tests \ + --with-release-file=/etc/os-release \ --with-logo=%{_datadir}/pixmaps/system-logo-white.png \ --with-background-start-color-stop=0xc6bdd2 \ --with-background-end-color-stop=0x4e376b \ @@ -293,6 +309,15 @@ cp $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/glow/{box,bullet,entry,lock}.png $ # Drop glow, it's not very Fedora-y rm -rf $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/glow +# Revert text theme back to the tribar one +rm -rf $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/text +mv $RPM_BUILD_ROOT%{_libdir}/plymouth/tribar.so $RPM_BUILD_ROOT%{_libdir}/plymouth/text.so +mv $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/tribar $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/text +mv $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/text/tribar.plymouth $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/text/text.plymouth +sed -i -e 's/tribar/text/' $RPM_BUILD_ROOT%{_datadir}/plymouth/themes/text/text.plymouth + +cp $RPM_SOURCE_DIR/plymouth-update-initrd $RPM_BUILD_ROOT%{_libexecdir}/plymouth/plymouth-update-initrd + %clean rm -rf $RPM_BUILD_ROOT @@ -397,11 +422,7 @@ fi %{_localstatedir}/spool/plymouth %{_mandir}/man?/* %ghost %{_localstatedir}/lib/plymouth/boot-duration -%if 0%{?fedora} > 17 || 0%{?rhel} > 6 -/lib/systemd/system/* -%else -%{_prefix}/lib/systemd/system/plymouth-*.service -%endif +%{_prefix}/lib/systemd/system/* %files devel %defattr(-, root, root) @@ -505,6 +526,83 @@ fi %defattr(-, root, root) %changelog +* Thu Mar 06 2014 Ray Strode 0.8.9-0.10.20140113 +- more serial console fixes + Resolves: #1058049 + +* Mon Mar 03 2014 Ray Strode 0.8.9-0.9.20140113 +- Ignore early fb devices + Resolves: #1063758 + Resolves: #1064235 + Resolves: #1066641 +- Ignore udev if using lone serial console + Resolves: #1058049 +- Fix password at start up race + Resolves: #1070707 + Resolves: #1073145 + +* Tue Feb 11 2014 Ray Strode 0.8.9-0.8.20140113 +- Enable position-independent code + Resolves: #1063953 + +* Thu Feb 06 2014 Ray Strode 0.8.9-0.7.20140113 +- Release terminal on hide-splash + Resolves: #1062334 + +* Wed Feb 05 2014 Ray Strode 0.8.9-0.6.20140113 +- Fix race causing assertion failure at startup + Resolves: #1061186 + +* Tue Jan 28 2014 Daniel Mach - 0.8.9-0.5.20140113 +- Mass rebuild 2014-01-24 + +* Fri Jan 24 2014 Ray Strode 0.8.9-0.4.20140113 +- Make booting without "rhgb" work + Resolves: #1050876 + +* Fri Jan 17 2014 Ray Strode 0.8.9-0.3.20140113 +- Read OS string from REDHAT_BUGZILLA_PRODUCT instead of PRETTY_NAME + in /etc/os-release to work around a lorax bug. + Resolves: #911553 +- Fix text splash when explicitly configured by user + Related: #911553 + Related: #1026571 + +* Thu Jan 16 2014 Ray Strode 0.8.9-0.2.20140113 +- Remove artificial 5 second delay for asking for password + Related: #1043689 + +* Wed Jan 15 2014 Ray Strode 0.8.9-0.1.20140113 +- Update to more compliant versioning scheme + Resolves: #1053769 + +* Mon Jan 13 2014 Ray Strode 0.8.9-0.2014.01.13.1 +- more udev fixes + Related: #1026571 + Related: #1043689 + +* Fri Jan 10 2014 Ray Strode 0.8.9-0.2014.01.10.2 +- Fix plymouth-set-default-theme -R + Resolves: #1045514 + +* Fri Jan 10 2014 Ray Strode 0.8.9-0.2014.01.10.1 +- Update to latest snapshot +- Fixes ask-for-password feature + Resolves: #1043689 +- Drops bogus delay when hitting escape + Resolves: #1049379 + +* Fri Dec 27 2013 Daniel Mach - 0.8.9-0.2014 +- Mass rebuild 2013-12-27 + +* Tue Dec 10 2013 Ray Strode 0.8.9-0.2013.12.10.1 +- Update to latest snapshot, but revert text splash back to tribar +- Fixes systemd unit files and lets us drop our upstreamed patches + Resolves: #1040015 +- Uses udev for device enumeration + Resolves: #1026571 +- Correct "charge" theme description + * Fri Nov 08 2013 Ray Strode 0.8.9-0.2013.03.26.4 - Fix unlock screen Related: #1002219