From: Johannes Stezenbach <js@sig21.net>
To: Peter Hurley <peter@hurleysoftware.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Jiri Slaby <jslaby@suse.cz>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 5/6] n_tty: Fix stuck write wakeup
Date: Sun, 13 Dec 2015 20:27:40 +0100 [thread overview]
Message-ID: <20151213192740.GA17772@sig21.net> (raw)
In-Reply-To: <566DBB0A.5070108@hurleysoftware.com>
On Sun, Dec 13, 2015 at 10:38:02AM -0800, Peter Hurley wrote:
> On 12/13/2015 07:18 AM, Johannes Stezenbach wrote:
> >
> > There is a related bug that I meant to send a patch, but I
> > never got around because the issue was found with proprietary
> > userspace and ancient kernel. Maybe you could take care of it?
> > The patch might not apply cleanly after your recent changes
> > or might even be invalid now, please check.
>
> Thanks for the patch, Johannes!
>
> Yes, the patch below is still required to prevent excessive SIGIO
> (and to prevent missed SIGIO when the amount actually copied just
> happens to be exactly the amount left to be copied).
>
> I made some comments in the patch; can you re-submit with those
> changes and the patch title in the subject? Or I'd happy to re-work
> it and send it to Greg if you'd prefer; just let me know.
Please rework it, currently I'm in lazy bum mode ;-)
> > @@ -1991,7 +1992,7 @@ static ssize_t n_tty_write(struct tty_st
> > break_out:
> > __set_current_state(TASK_RUNNING);
> > remove_wait_queue(&tty->write_wait, &wait);
> > - if (b - buf != nr && tty->fasync)
> > + if (b - buf != count && tty->fasync)
>
> ... this can be
>
> if (nr && tty->fasync)
> set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags);
Yeah, that's way better.
Thanks,
Johannes
next prev parent reply other threads:[~2015-12-13 19:27 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-12 22:16 [PATCH 0/6] More n_tty fixes Peter Hurley
2015-12-12 22:16 ` [PATCH 1/6] n_tty: Always wake up read()/poll() if new input Peter Hurley
2015-12-13 14:49 ` Johannes Stezenbach
2015-12-13 19:53 ` Peter Hurley
2015-12-12 22:16 ` [PATCH 2/6] tty, n_tty: Remove fasync() ldisc notification Peter Hurley
2015-12-12 22:16 ` [PATCH 3/6] tty: Add fasync() hung up file operation Peter Hurley
2015-12-12 22:16 ` [PATCH 4/6] tty: Fix ioctl(FIOASYNC) on hungup file Peter Hurley
2015-12-12 22:16 ` [PATCH 5/6] n_tty: Fix stuck write wakeup Peter Hurley
2015-12-13 15:18 ` Johannes Stezenbach
2015-12-13 18:38 ` Peter Hurley
2015-12-13 19:27 ` Johannes Stezenbach [this message]
2015-12-12 22:16 ` [PATCH 6/6] n_tty: Remove tty count checks from unthrottle Peter Hurley
2016-01-10 5:45 ` [PATCH v2 0/7] More n_tty fixes Peter Hurley
2016-01-10 5:45 ` [PATCH v2 1/7] n_tty: Always wake up read()/poll() if new input Peter Hurley
2016-01-10 5:45 ` [PATCH v2 2/7] tty, n_tty: Remove fasync() ldisc notification Peter Hurley
2016-01-10 5:45 ` [PATCH v2 3/7] tty: Add fasync() hung up file operation Peter Hurley
2016-01-10 5:45 ` [PATCH v2 4/7] tty: Fix ioctl(FIOASYNC) on hungup file Peter Hurley
2016-01-10 5:45 ` [PATCH v2 5/7] n_tty: Fix stuck write wakeup Peter Hurley
2016-01-10 5:45 ` [PATCH v2 6/7] n_tty: Remove tty count checks from unthrottle Peter Hurley
2016-01-10 5:45 ` [PATCH v2 7/7] tty: n_tty: fix SIGIO for output Peter Hurley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20151213192740.GA17772@sig21.net \
--to=js@sig21.net \
--cc=gregkh@linuxfoundation.org \
--cc=jslaby@suse.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=peter@hurleysoftware.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.