[mutter] renderer/native: Move primary GPU choosing later



commit 60ac2838b5964979c722f43700e2382d7d206aea
Author: Emilio Pozuelo Monfort <emilio pozuelo collabora co uk>
Date:   Fri Oct 12 14:19:24 2018 +0200

    renderer/native: Move primary GPU choosing later
    
    Moves the primary GPU choosing to after all secondary gpu data has been
    created.
    
    This makes it possible for a future patch to start looking at secondary
    gpu data in choose_primary_gpu () to determine if it is using a hardware
    driver or a software renderer.
    
    Co-authored by: Pekka Paalanen <pekka paalanen collabora com>
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/271

 src/backends/native/meta-renderer-native.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/backends/native/meta-renderer-native.c b/src/backends/native/meta-renderer-native.c
index 51a7a2cd1..bd63347c8 100644
--- a/src/backends/native/meta-renderer-native.c
+++ b/src/backends/native/meta-renderer-native.c
@@ -3659,8 +3659,6 @@ meta_renderer_native_initable_init (GInitable     *initable,
   GList *gpus;
   GList *l;
 
-  renderer_native->primary_gpu_kms = choose_primary_gpu (monitor_manager);
-
   gpus = meta_monitor_manager_get_gpus (monitor_manager);
   for (l = gpus; l; l = l->next)
     {
@@ -3670,6 +3668,8 @@ meta_renderer_native_initable_init (GInitable     *initable,
         return FALSE;
     }
 
+  renderer_native->primary_gpu_kms = choose_primary_gpu (monitor_manager);
+
   return TRUE;
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]