diff --git a/compositor/main.c b/compositor/main.c index 2c15d16a..34f27d46 100644 --- a/compositor/main.c +++ b/compositor/main.c @@ -2514,6 +2514,7 @@ load_drm_backend(struct weston_compositor *c, struct weston_drm_backend_config config = {{ 0, }}; struct weston_config_section *section; struct wet_compositor *wet = to_wet_compositor(c); + bool without_input = false; int ret = 0; wet->drm_use_current_mode = false; @@ -2528,7 +2529,7 @@ load_drm_backend(struct weston_compositor *c, { WESTON_OPTION_STRING, "drm-device", 0, &config.specific_device }, { WESTON_OPTION_BOOLEAN, "current-mode", 0, &wet->drm_use_current_mode }, { WESTON_OPTION_BOOLEAN, "use-pixman", 0, &config.use_pixman }, - { WESTON_OPTION_BOOLEAN, "continue-without-input", 0, &config.continue_without_input }, + { WESTON_OPTION_BOOLEAN, "continue-without-input", false, &without_input } }; parse_options(options, ARRAY_LENGTH(options), argc, argv); @@ -2541,6 +2542,8 @@ load_drm_backend(struct weston_compositor *c, &config.pageflip_timeout, 0); weston_config_section_get_bool(section, "pixman-shadow", &config.use_pixman_shadow, true); + if (without_input) + c->require_input = !without_input; config.base.struct_version = WESTON_DRM_BACKEND_CONFIG_VERSION; config.base.struct_size = sizeof(struct weston_drm_backend_config); diff --git a/include/libweston/backend-drm.h b/include/libweston/backend-drm.h index 350eeb0d..af2da4aa 100644 --- a/include/libweston/backend-drm.h +++ b/include/libweston/backend-drm.h @@ -35,7 +35,7 @@ extern "C" { #endif -#define WESTON_DRM_BACKEND_CONFIG_VERSION 3 +#define WESTON_DRM_BACKEND_CONFIG_VERSION 4 struct libinput_device; @@ -223,9 +223,6 @@ struct weston_drm_backend_config { /** Use shadow buffer if using Pixman-renderer. */ bool use_pixman_shadow; - - /** Allow compositor to start without input devices. */ - bool continue_without_input; }; #ifdef __cplusplus diff --git a/libweston/backend-drm/drm.c b/libweston/backend-drm/drm.c index 88329b80..8594594d 100644 --- a/libweston/backend-drm/drm.c +++ b/libweston/backend-drm/drm.c @@ -3025,7 +3025,6 @@ drm_backend_create(struct weston_compositor *compositor, NULL, NULL, NULL); compositor->backend = &b->base; - compositor->require_input = !config->continue_without_input; if (parse_gbm_format(config->gbm_format, DRM_FORMAT_XRGB8888, &b->gbm_format) < 0) goto err_compositor;