lkml.org 
[lkml]   [2021]   [Jan]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: tty splice branch (was "Re: Splicing to/from a tty")
From
Date
On 21. 01. 21, 2:18, Linus Torvalds wrote:
> On Tue, Jan 19, 2021 at 8:44 PM Linus Torvalds
> <torvalds@linux-foundation.org> wrote:
>>
>> I'll come back to this tomorrow and do the line-buffered icanon case
>> too (unless pull requests pile up), and then I'll be happy with the
>> tty changes, and I think I can submit this series for real to Greg.
>
> Greg, I don't know how you want to handle this.
>
> I have a branch with my tty splice patches at
>
> git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git tty-splice
>
> and that now includes doing that "cookie continuation" thing even for
> the N_TTY icanon modes.
>
> It passes my local tests, and I did try a few rather odd things. And
> Oliver tested an ealier version without that final commit on his load.
> But...

Hm, I would like to review this first. I noticed the changes only
because a new branch appeared when I grabbed your tree and the branch
has "tty" in its name.

So for example:

> @@ -1038,18 +1045,15 @@ static ssize_t tty_write(struct file *file, const char __user *buf,
> if (tty->ops->write_room == NULL)
> tty_err(tty, "missing write_room method\n");
> ld = tty_ldisc_ref_wait(tty);
> - if (!ld)
> - return hung_up_tty_write(file, buf, count, ppos);
> - if (!ld->ops->write)
> + if (!ld || !ld->ops->write)
> ret = -EIO;
> else
> - ret = do_tty_write(ld->ops->write, tty, file, buf, count);
> + ret = do_tty_write(ld->ops->write, tty, file, from);
> tty_ldisc_deref(ld);

if ld == NULL => crash here.

So can you send the patches to the list and Cc me too?

> return ret;
> }
thanks,
--
js

\
 
 \ /
  Last update: 2021-01-21 09:54    [W:0.113 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site