mod->name);
                add_taint_module(mod, TAINT_TEST, LOCKDEP_STILL_OK);
        }
+#ifdef CONFIG_MODULE_SIG
+       mod->sig_ok = info->sig_ok;
+       if (!mod->sig_ok) {
+               pr_notice_once("%s: module verification failed: signature "
+                              "and/or required key missing - tainting "
+                              "kernel\n", mod->name);
+               add_taint_module(mod, TAINT_UNSIGNED_MODULE, LOCKDEP_STILL_OK);
+       }
+#endif
 }
 
 static int check_modinfo(struct module *mod, struct load_info *info, int flags)
         * We should compromise and converge.
         */
        module_augment_kernel_taints(mod, info);
-#ifdef CONFIG_MODULE_SIG
-       mod->sig_ok = info->sig_ok;
-       if (!mod->sig_ok) {
-               pr_notice_once("%s: module verification failed: signature "
-                              "and/or required key missing - tainting "
-                              "kernel\n", mod->name);
-               add_taint_module(mod, TAINT_UNSIGNED_MODULE, LOCKDEP_STILL_OK);
-       }
-#endif
 
        /* To avoid stressing percpu allocator, do this once we're unique. */
        err = percpu_modalloc(mod, info);