weston-init: update init scripts related to restarting Weston
PATCH 1/1 weston-init: update init scripts related to restarting Weston
* Bypass restarting Weston if SD card has calibration file already
* Increase the sleep time before Weston is restarted
It takes some time to complete the Weston termination procedure. If Weston is restarted before the previous instance is fully terminated, the restart of Weston will fail.
Signed-off-by Hongmei Gou <[email protected]>
Signed-off-by Eric Ruei <[email protected]>
--- meta-arago-distro/recipes-graphics/wayland/weston-init.bbappend | 2 +- meta-arago-distro/recipes-graphics/wayland/weston-init/init | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-)
meta-arago-distro/recipes-graphics/wayland/weston-init.bbappend +1 -1
@@ -1,4 +1,4 @@ -PR_append = "-arago4" +PR_append = "-arago5" FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
meta-arago-distro/recipes-graphics/wayland/weston-init/init +4 -3
@@ -63,8 +63,9 @@ case "$1" in # Check if SD card has a calibration rules file SD_CALUDEV_FILE=/run/media/mmcblk0p1/ws-calibrate.rules if [ "$SD_MOUNTED" = "1" -a -f "$SD_CALUDEV_FILE" ] ; then - # Copy it over to udev location + # Copy it over to udev location, and done cp "$SD_CALUDEV_FILE" "$WS_CALUDEV_FILE" + exit 0 else # Run a calibration app and save output to udev rules echo "Calibrating touchscreen (first time only)"
@@ -85,7 +86,7 @@ case "$1" in udevadm control --reload udevadm trigger killproc weston - sleep 1 + sleep 2 openvt -c 4 -f runWeston ;;
@@ -96,7 +97,7 @@ case "$1" in restart) $0 stop - sleep 1 + sleep 2 $0 start ;;
Signature · 1 line
1.9.1