All of lore.kernel.org
 help / color / mirror / Atom feed
From: Manfred Schlaegl <manfred.schlaegl@gmx.at>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Jiri Slaby <jslaby@suse.cz>,
	Peter Hurley <peter@hurleysoftware.com>,
	Alan Cox <alan@redhat.com>,
	linux-kernel@vger.kernel.org,
	Manfred Schlaegl <manfred.schlaegl@ginzinger.com>
Subject: Re: [PATCH] tty: Fix race condition between __tty_buffer_request_room and flush_to_ldisc
Date: Fri, 18 Apr 2014 10:10:17 +0200	[thread overview]
Message-ID: <5350DDE9.1040102@gmx.at> (raw)
In-Reply-To: <5343EE9C.9010004@gmx.at>

On 2014-04-08 14:42, Manfred Schlaegl wrote:
> The race was introduced while development of linux-3.11 by
> e8437d7ecbc50198705331449367d401ebb3181f and
> e9975fdec0138f1b2a85b9624e41660abd9865d4.
> Originally it was found and reproduced on linux-3.12.15 and
> linux-3.12.15-rt25, by sending 500 byte blocks with 115kbaud to the
> target uart in a loop with 100 milliseconds delay.
> 
> In short:
>  1. The consumer flush_to_ldisc is on to remove the head tty_buffer.
>  2. The producer adds a number of bytes, so that a new tty_buffer must
> 	be allocated and added by __tty_buffer_request_room.
>  3. The consumer removes the head tty_buffer element, without handling
> 	newly committed data.

Hi!

Reminder: The Problem is still existent in linux-3.11, 3.12, 3.13. 3.14 and pre 3.15 kernels.

The lastly delivered patch cleanly applies to pre 3.15 (torvalds tree) and 3.14(.1).

Manfred

  reply	other threads:[~2014-04-18  8:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-08 12:42 [PATCH] tty: Fix race condition between __tty_buffer_request_room and flush_to_ldisc Manfred Schlaegl
2014-04-18  8:10 ` Manfred Schlaegl [this message]
2014-04-22 10:55   ` One Thousand Gnomes
2014-04-22 11:16     ` Greg Kroah-Hartman
  -- strict thread matches above, loose matches on Subject: below --
2014-04-08 12:40 Manfred Schlaegl

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=5350DDE9.1040102@gmx.at \
    --to=manfred.schlaegl@gmx.at \
    --cc=alan@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jslaby@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=manfred.schlaegl@ginzinger.com \
    --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.