> In any case, the only thing that "mayfail" seems to control, is in > module_load_file, and is a single printf: > > g_module = g_module_open(fname, flags); > if (!g_module) { > if (!mayfail) { > fprintf(stderr, "Failed to open module: %s\n", > g_module_error()); > } > ret = -EINVAL; > goto out; > } > > > Weird.. Is someone building proprietary modules on top of QEMU?
Nope. But modules have dependencies to stuff like pci bus, usb bus, vga which might not be satisfied by some system emulators, and trying to load those modules will fail then because of unresolved symbols. If you drop that 'make check' will log a pile of errors ... Dropping mayfail and return an 'Error' instead makes sense, then it is up to the caller to report or not report the failure. When calling down from module_load_qom_all() you might want ignore errors for the reasons outlined above, in most other caes it probably makes sense to report them. take care, Gerd