[PATCH v2] UnloadSubModule(): accept pointer value '1' and ignore it.
Matthieu Herrb
matthieu.herrb at laas.fr
Mon Jan 2 05:11:41 PST 2012
Some driver modules try to unload submodules that are now built-in.
Signed-off-by: Matthieu Herrb <matthieu.herrb at laas.fr>
Reviewed-by: Julien Cristau <jcristau at debian.org>
---
hw/xfree86/loader/loadmod.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/hw/xfree86/loader/loadmod.c b/hw/xfree86/loader/loadmod.c
index 5b9f8d1..5b9c119 100644
--- a/hw/xfree86/loader/loadmod.c
+++ b/hw/xfree86/loader/loadmod.c
@@ -1090,6 +1090,9 @@ UnloadSubModule(pointer _mod)
{
ModuleDescPtr mod = (ModuleDescPtr)_mod;
+ /* Some drivers are calling us on built-in submodules, ignore them */
+ if (mod == (ModuleDescPtr)1)
+ return;
RemoveChild(mod);
UnloadModuleOrDriver(mod);
}
--
1.7.6
More information about the xorg-devel
mailing list