From eaf75f07060b5569133a2eac0149da9513e26eb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Wed, 28 Apr 2021 09:56:30 +0200 Subject: udev: Don't only check 'platform' device for KMS modifier tag Only checking the 'platform' device missed the tags added for i915 and others, meaning the multi head configurations yet again started to fail due to default modifier behavior is incompatible with multi many head configurations. Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1769 Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1774 Part-of: --- src/backends/native/meta-udev.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/src/backends/native/meta-udev.c b/src/backends/native/meta-udev.c index 5d58d6b56..9127d3bed 100644 --- a/src/backends/native/meta-udev.c +++ b/src/backends/native/meta-udev.c @@ -77,22 +77,21 @@ meta_is_udev_device_boot_vga (GUdevDevice *device) gboolean meta_is_udev_device_disable_modifiers (GUdevDevice *device) { - g_autoptr (GUdevDevice) platform_device = NULL; const char * const * tags; + g_autoptr (GUdevDevice) platform_device = NULL; + + tags = g_udev_device_get_tags (device); + if (tags && g_strv_contains (tags, "mutter-device-disable-kms-modifiers")) + return TRUE; platform_device = g_udev_device_get_parent_with_subsystem (device, "platform", NULL); - if (!platform_device) + if (platform_device) + return meta_is_udev_device_disable_modifiers (platform_device); + else return FALSE; - - tags = g_udev_device_get_tags (platform_device); - - if (!tags) - return FALSE; - - return g_strv_contains (tags, "mutter-device-disable-kms-modifiers"); } gboolean -- cgit v1.2.1