diff mbox series

[meta-arago,master/wrynose,2/2] weston-init-arago: set WAIT_CARD_DEVICE_COUNT

Message ID 20261002222954.3580000-2-rs@ti.com
State New
Headers show
Series [meta-arago,master/wrynose,1/2] emptty: upgrade from v0.15.0 to v0.16.1+git | expand

Commit Message

Randolph Sapp Oct. 2, 2026, 10:29 p.m. UTC
From: Randolph Sapp <rs@ti.com>

Update the emptty configuration template and define
WAIT_CARD_DEVICE_COUNT for this usecase. We're not doing anything with a
remote head or fake display right now, so a default value of 1 will make
emptty wait for tidss to initialize. In the devices with a GPU we should
set it to a value of 2 to ensure both expected DRI devices are present.

Signed-off-by: Randolph Sapp <rs@ti.com>
---
 .../recipes-graphics/wayland/weston-init-arago.bb    | 12 ++++++++++++
 .../wayland/weston-init-arago/emptty.conf            |  5 ++++-
 2 files changed, 16 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta-arago-distro/recipes-graphics/wayland/weston-init-arago.bb b/meta-arago-distro/recipes-graphics/wayland/weston-init-arago.bb
index 484d25e18661..1a649342bd16 100644
--- a/meta-arago-distro/recipes-graphics/wayland/weston-init-arago.bb
+++ b/meta-arago-distro/recipes-graphics/wayland/weston-init-arago.bb
@@ -23,9 +23,21 @@  PACKAGECONFIG[use-pixman] = ",,"
 DEFAULTBACKEND ??= ""
 DEFAULTBACKEND:qemuall ?= "drm"
 
+DRI_CARD_COUNT ??= "1"
+DRI_CARD_COUNT:j721e = "2"
+DRI_CARD_COUNT:j721s2 = "2"
+DRI_CARD_COUNT:j784s4 = "2"
+DRI_CARD_COUNT:j742s2 = "2"
+DRI_CARD_COUNT:am62xx = "2"
+DRI_CARD_COUNT:am62pxx = "2"
+DRI_CARD_COUNT:j722s = "2"
+
 do_install() {
 	install -D -p -m0644 weston.ini ${D}${sysconfdir}/xdg/weston/weston.ini
 	install -D -p -m0644 emptty.conf ${D}${sysconfdir}/emptty/conf
+	if [ -n "${DRI_CARD_COUNT}" ]; then
+		sed -i -e "/^#WAIT_CARD_DEVICE_COUNT=/c WAIT_CARD_DEVICE_COUNT=${DRI_CARD_COUNT}" ${D}${sysconfdir}/emptty/conf
+	fi
 
 	if [ -n "${DEFAULTBACKEND}" ]; then
 		sed -i -e "/^\[core\]/a backend=${DEFAULTBACKEND}-backend.so" ${D}${sysconfdir}/xdg/weston/weston.ini
diff --git a/meta-arago-distro/recipes-graphics/wayland/weston-init-arago/emptty.conf b/meta-arago-distro/recipes-graphics/wayland/weston-init-arago/emptty.conf
index ffe1a3c26f64..4c4ac453bb96 100644
--- a/meta-arago-distro/recipes-graphics/wayland/weston-init-arago/emptty.conf
+++ b/meta-arago-distro/recipes-graphics/wayland/weston-init-arago/emptty.conf
@@ -20,7 +20,7 @@  AUTOLOGIN=true
 AUTOLOGIN_SESSION=Weston
 
 # If Autologin is enabled and session does not start correctly, the number of retries in short period is kept to eventually stop the infinite loop of restarts. -1 is for infinite retries, 0 is for no retry.
-AUTOLOGIN_MAX_RETRY=-1
+# AUTOLOGIN_MAX_RETRY=2
 
 # Default LANG, if user does not have set own in init script.
 #LANG=en_US.UTF-8
@@ -75,3 +75,6 @@  SESSION_ERROR_LOGGING=rotate
 
 #If set true, environmental groups are printed to differ Xorg/Wayland/Custom/UserCustom desktops.
 IDENTIFY_ENVS=false
+
+# Number of DRI card devices to wait for before starting the session. A machine with 2 GPUs may want to set this to 2.
+#WAIT_CARD_DEVICE_COUNT=0