]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - kernel/kmod.c
USB: create new workqueue thread for USB autosuspend
[karo-tx-linux.git] / kernel / kmod.c
index 1d32defa38abe5ab08114281e93d92ccf947ecb3..5c470c57fb57c0997bd5f76e24a1bb5cc24e687b 100644 (file)
@@ -197,11 +197,12 @@ static void __call_usermodehelper(void *data)
 {
        struct subprocess_info *sub_info = data;
        pid_t pid;
+       int wait = sub_info->wait;
 
        /* CLONE_VFORK: wait until the usermode helper has execve'd
         * successfully We need the data structures to stay around
         * until that is done.  */
-       if (sub_info->wait)
+       if (wait)
                pid = kernel_thread(wait_for_helper, sub_info,
                                    CLONE_FS | CLONE_FILES | SIGCHLD);
        else
@@ -211,7 +212,7 @@ static void __call_usermodehelper(void *data)
        if (pid < 0) {
                sub_info->retval = pid;
                complete(sub_info->complete);
-       } else if (!sub_info->wait)
+       } else if (!wait)
                complete(sub_info->complete);
 }