User Tools

Site Tools


lk_usermodehelper

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Last revision Both sides next revision
lk_usermodehelper [2019/02/14 15:12]
rpjday [drivers/video/fbdev/uvesafb.c]
lk_usermodehelper [2019/02/14 15:16]
rpjday [drivers/macintosh/windfarm_core.c]
Line 309: Line 309:
                                    argv, envp, UMH_WAIT_EXEC);​                                    argv, envp, UMH_WAIT_EXEC);​
 } }
 +</​code>​
 +
 +==== init/​do_mounts_initrd.c ====
 +
 +<​code>​
 +static void __init handle_initrd(void)
 +{
 +        struct subprocess_info *info;
 +        static char *argv[] = { "​linuxrc",​ NULL, };
 +        extern char *envp_init[];​
 +        int error;
 +
 +        real_root_dev = new_encode_dev(ROOT_DEV);​
 +        create_dev("/​dev/​root.old",​ Root_RAM0);
 +        /* mount initrd on rootfs'​ /root */
 +        mount_block_root("/​dev/​root.old",​ root_mountflags & ~MS_RDONLY);​
 +        ksys_mkdir("/​old",​ 0700);
 +        ksys_chdir("/​old"​);​
 +
 +        /*
 +         * In case that a resume from disk is carried out by linuxrc or one of
 +         * its children, we need to tell the freezer not to wait for us.
 +         */
 +        current->​flags |= PF_FREEZER_SKIP;​
 +
 +        info = call_usermodehelper_setup("/​linuxrc",​ argv, envp_init,
 +                                         ​GFP_KERNEL,​ init_linuxrc,​ NULL, NULL);
 +        if (!info)
 +                return;
 +        call_usermodehelper_exec(info,​ UMH_WAIT_PROC);​
 +        ​
 +        ...
 </​code>​ </​code>​
lk_usermodehelper.txt ยท Last modified: 2019/02/14 15:18 by rpjday