You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
983 B
29 lines
983 B
From a192b9abd77aa14ae794850e41d210472f86b9b0 Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
|
Date: Thu, 25 Jun 2020 10:09:48 +0200
|
|
Subject: [PATCH 2/2] gpu-kms: Reset CRTC, mode and output list if no resources
|
|
|
|
On device removal, the next resource retrieval will fail; handle this by
|
|
just clearing the CRTC, mode and outputs.
|
|
---
|
|
src/backends/native/meta-gpu-kms.c | 3 +++
|
|
1 file changed, 3 insertions(+)
|
|
|
|
diff --git a/src/backends/native/meta-gpu-kms.c b/src/backends/native/meta-gpu-kms.c
|
|
index 93e509def5..dc93abb7b1 100644
|
|
--- a/src/backends/native/meta-gpu-kms.c
|
|
+++ b/src/backends/native/meta-gpu-kms.c
|
|
@@ -871,6 +871,9 @@ meta_gpu_kms_read_current (MetaGpu *gpu,
|
|
local_error->message);
|
|
gpu_kms->resources_init_failed_before = TRUE;
|
|
}
|
|
+ meta_gpu_take_outputs (gpu, NULL);
|
|
+ meta_gpu_take_modes (gpu, NULL);
|
|
+ meta_gpu_take_crtcs (gpu, NULL);
|
|
return TRUE;
|
|
}
|
|
|
|
--
|
|
2.26.2
|
|
|