[OE-core] [PATCH] xserver-nodm-init: Respawn service in case of failure

Nicolas Dechesne nicolas.dechesne at linaro.org
Tue Apr 10 19:48:23 UTC 2018


On Tue, Apr 10, 2018 at 1:20 PM, Ramon Fried <ramon.fried at linaro.org> wrote:
> From: Ramon Fried <rfried at codeaurora.org>
>
> It appears that sometimes xserver-nodm.service is starting before
> display driver finished loading causing the following failure in
> Xorg log:
> (EE) open /dev/dri/card0: No such file or directory
>
> The introduced by this patch is to restart the service,
> hopefully the display driver will finish loading.
>
> Signed-off-by: Ramon Fried <rfried at codeaurora.org>

we are seeing this issue on Dragonboard with meta-qcom BSP, where all
drivers needed for display/gpu are modules, so the display
initialization comes up 'late' in the boot. I had a discussion with
some upstream gnome folks who indicated that a similar race can be
observed on any hardware, it is not uncommon, and that's why they use
Restart=always in gdm.service as well, so that it keep trying until
the display comes up.

it sounds reasonable change to me.

Reviewed-by: Nicolas Dechesne <nicolas.dechesne at linaro.org>

> ---
>  .../x11-common/xserver-nodm-init/xserver-nodm.service.in                 | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/meta/recipes-graphics/x11-common/xserver-nodm-init/xserver-nodm.service.in b/meta/recipes-graphics/x11-common/xserver-nodm-init/xserver-nodm.service.in
> index 324a26f549..87dc4f8fcd 100644
> --- a/meta/recipes-graphics/x11-common/xserver-nodm-init/xserver-nodm.service.in
> +++ b/meta/recipes-graphics/x11-common/xserver-nodm-init/xserver-nodm.service.in
> @@ -5,6 +5,7 @@ Description=Xserver startup without a display manager
>  EnvironmentFile=/etc/default/xserver-nodm
>  User=@USER@
>  ExecStart=/etc/xserver-nodm/Xserver
> +Restart=always
>
>  [Install]
>  Alias=display-manager.service
> --
> The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
> a Linux Foundation Collaborative Project
>



More information about the Openembedded-core mailing list