]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
kmod-setup: when we fail to load a kmod, log the error cause
authorLennart Poettering <lennart@poettering.net>
Thu, 11 Jun 2015 10:13:03 +0000 (12:13 +0200)
committerLennart Poettering <lennart@poettering.net>
Thu, 11 Jun 2015 10:13:58 +0000 (12:13 +0200)
(Also, downgrade message from LOG_ERROR to LOG_WARNING, after all we
don't care much and just proceed)

src/core/kmod-setup.c

index cf543c81a3184a95e3e8986b672aa83fcf7cebbb..d956f9b190be8aa72d0c86ec1bd2d8f5e4155130 100644 (file)
@@ -118,8 +118,9 @@ int kmod_setup(void) {
                 else if (r == KMOD_PROBE_APPLY_BLACKLIST)
                         log_info("Module '%s' is blacklisted", kmod_module_get_name(mod));
                 else
-                        log_full((kmod_table[i].warn_if_unavailable || (r < 0 && r != -ENOENT)) ? LOG_ERR : LOG_DEBUG,
-                                 "Failed to insert module '%s'", kmod_module_get_name(mod));
+                        log_full_errno((kmod_table[i].warn_if_unavailable || (r < 0 && r != -ENOENT)) ? LOG_WARNING : LOG_DEBUG,
+                                       r,
+                                       "Failed to insert module '%s': %m", kmod_module_get_name(mod));
 
                 kmod_module_unref(mod);
         }