]> git.proxmox.com Git - mirror_qemu.git/commitdiff
modules: turn off lazy binding
authorGerd Hoffmann <kraxel@redhat.com>
Wed, 28 Oct 2020 05:49:44 +0000 (06:49 +0100)
committerGerd Hoffmann <kraxel@redhat.com>
Thu, 29 Oct 2020 05:37:24 +0000 (06:37 +0100)
We want missing symbols fail module load right away instead of having
qemu abort later on in case lazy binding fails.  Can happen -- for
example -- when trying to load a module for a pci device
(virtio-gpu-pci) into a qemu without pci support (qemu-system-avr).

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-id: 20201028054944.5772-1-kraxel@redhat.com

util/module.c

index 503c399421c5301968928adacd1959134c50f629..c65060c167df236d6e2163472708cf95e69a02c7 100644 (file)
@@ -132,7 +132,7 @@ static int module_load_file(const char *fname, bool mayfail, bool export_symbols
 
     assert(QTAILQ_EMPTY(&dso_init_list));
 
-    flags = G_MODULE_BIND_LAZY;
+    flags = 0;
     if (!export_symbols) {
         flags |= G_MODULE_BIND_LOCAL;
     }