All of lore.kernel.org
 help / color / mirror / Atom feed
* [master-next][PATCH 1/3] PSPLASH_FIFO_DIR: refactor
@ 2020-12-23 17:06 Trevor Woerner
  2020-12-23 17:06 ` [master-next][PATCH 2/3] psplash: work on first boot (sysvinit) Trevor Woerner
  2020-12-23 17:06 ` [master-next][PATCH 3/3] sysvinit/rc: improved progress messages Trevor Woerner
  0 siblings, 2 replies; 11+ messages in thread
From: Trevor Woerner @ 2020-12-23 17:06 UTC (permalink / raw)
  To: openembedded-core

Add an entry for the psplash fifo directory to /etc/default/rcS and have the
pieces that need it, source it from there rather than duplicating the location
in multiple places throughout the code.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
---
 meta/recipes-core/psplash/files/psplash-init    | 4 +++-
 meta/recipes-core/sysvinit/sysvinit/rc          | 9 +++++----
 meta/recipes-core/sysvinit/sysvinit/rcS-default | 2 ++
 3 files changed, 10 insertions(+), 5 deletions(-)

diff --git a/meta/recipes-core/psplash/files/psplash-init b/meta/recipes-core/psplash/files/psplash-init
index f58e043733..68dd708123 100755
--- a/meta/recipes-core/psplash/files/psplash-init
+++ b/meta/recipes-core/psplash/files/psplash-init
@@ -7,6 +7,8 @@
 # Default-Stop:
 ### END INIT INFO
 
+. /etc/default/rcS
+
 if [ ! -e /dev/fb0 ]; then
     echo "Framebuffer /dev/fb0 not detected"
     echo "Boot splashscreen disabled"
@@ -23,7 +25,7 @@ for x in $CMDLINE; do
         esac
 done
 
-export PSPLASH_FIFO_DIR=/mnt/.psplash
+export PSPLASH_FIFO_DIR
 [ -d $PSPLASH_FIFO_DIR ] || mkdir -p $PSPLASH_FIFO_DIR
 if ! mountpoint -q $PSPLASH_FIFO_DIR; then
 	mount tmpfs -t tmpfs $PSPLASH_FIFO_DIR -o,size=40k
diff --git a/meta/recipes-core/sysvinit/sysvinit/rc b/meta/recipes-core/sysvinit/sysvinit/rc
index 6995930ee9..1c956a3a56 100755
--- a/meta/recipes-core/sysvinit/sysvinit/rc
+++ b/meta/recipes-core/sysvinit/sysvinit/rc
@@ -17,6 +17,7 @@
 
 . /etc/default/rcS
 export VERBOSE
+export PSPLASH_FIFO_DIR
 
 startup_progress() {
     step=$(($step + $step_change))
@@ -27,8 +28,8 @@ startup_progress() {
     fi
     #echo "PROGRESS is $progress $runlevel $first_step + ($step of $num_steps) $step_change $progress_size"
     if type psplash-write >/dev/null 2>&1; then
-        PSPLASH_FIFO_DIR=/mnt/.psplash psplash-write "MSG $(basename $1 .sh | cut -c 4-)" || true
-        PSPLASH_FIFO_DIR=/mnt/.psplash psplash-write "PROGRESS $progress" || true
+        psplash-write "MSG $(basename $1 .sh | cut -c 4-)" || true
+        psplash-write "PROGRESS $progress" || true
     fi
 }
 
@@ -174,7 +175,7 @@ startup() {
 #Uncomment to cause psplash to exit manually, otherwise it exits when it sees a VC switch
 if [ "x$runlevel" != "xS" ] && [ ! -x /etc/rc${runlevel}.d/S??xserver-nodm ]; then
     if type psplash-write >/dev/null 2>&1; then
-        PSPLASH_FIFO_DIR=/mnt/.psplash psplash-write "QUIT" || true
-    	umount -l /mnt/.psplash
+        psplash-write "QUIT" || true
+        umount -l $PSPLASH_FIFO_DIR
     fi
 fi
diff --git a/meta/recipes-core/sysvinit/sysvinit/rcS-default b/meta/recipes-core/sysvinit/sysvinit/rcS-default
index e608a77c75..70ab25710e 100644
--- a/meta/recipes-core/sysvinit/sysvinit/rcS-default
+++ b/meta/recipes-core/sysvinit/sysvinit/rcS-default
@@ -30,3 +30,5 @@ ROOTFS_READ_ONLY=no
 # rcS is also used when using busybox init and shares initscripts, some initscripts
 # need to have specific behavior depending on init system
 INIT_SYSTEM=sysvinit
+# set psplash fifo directory
+PSPLASH_FIFO_DIR=/mnt/.psplash
-- 
2.30.0.rc0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-12-23 22:55 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-23 17:06 [master-next][PATCH 1/3] PSPLASH_FIFO_DIR: refactor Trevor Woerner
2020-12-23 17:06 ` [master-next][PATCH 2/3] psplash: work on first boot (sysvinit) Trevor Woerner
2020-12-23 18:00   ` [OE-core] " Richard Purdie
2020-12-23 21:50     ` Trevor Woerner
2020-12-23 22:06       ` Richard Purdie
2020-12-23 22:35         ` Trevor Woerner
2020-12-23 22:39           ` Richard Purdie
2020-12-23 22:41       ` Trevor Woerner
2020-12-23 22:43         ` Richard Purdie
2020-12-23 22:55           ` Trevor Woerner
2020-12-23 17:06 ` [master-next][PATCH 3/3] sysvinit/rc: improved progress messages Trevor Woerner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.