/* This constructs a pipe, and sets the read end to be the stdin of the subprocess, and returns the write-end in *@filp.  */
int call_usermodehelper_stdinpipe(struct subprocess_info *sub_info, struct file **filp)
/* This constructs a pipe, and sets the read end to be the stdin of the subprocess, and returns the write-end in *@filp.  */
int call_usermodehelper_stdinpipe(struct subprocess_info *sub_info, struct file **filp)
{
	struct file *f;
	f = create_write_pipe(0);
	if (IS_ERR(f))
		return PTR_ERR(f);
	*filp = f;
	f = create_read_pipe(f, 0);
	if (IS_ERR(f)) {
		free_write_pipe(*filp);
		return PTR_ERR(f);
	}
	sub_info->stdin = f;
	return 0;
}