Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1761272AbZJMXBp (ORCPT ); Tue, 13 Oct 2009 19:01:45 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1760895AbZJMXBo (ORCPT ); Tue, 13 Oct 2009 19:01:44 -0400 Received: from earthlight.etchedpixels.co.uk ([81.2.110.250]:44400 "EHLO www.etchedpixels.co.uk" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1760128AbZJMXBn (ORCPT ); Tue, 13 Oct 2009 19:01:43 -0400 Date: Wed, 14 Oct 2009 00:01:45 +0100 From: Alan Cox To: Linus Torvalds Cc: Paul Fulghum , Boyan , " =?ISO-8859-14?B?RnLpZOlyaWM=?= L. W. Meunier" , "Justin P. Mattock" , Nix , "Rafael J. Wysocki" , Linux Kernel Mailing List , Kernel Testers List , Dmitry Torokhov , Ed Tomlinson , OGAWA Hirofumi Subject: Re: [Bug #14388] keyboard under X with 2.6.31 Message-ID: <20091014000145.3a611c94@lxorguk.ukuu.org.uk> In-Reply-To: References: <56acieJJ2fF.A.nEB.Hzl0KB@chimera> <87ljjgfcbu.fsf@spindle.srvr.nix> <4AD3F769.5080405@gmail.com> <4AD437F9.9020708@yahoo.co.uk> <4AD4DE4C.4010402@yahoo.co.uk> <4AD4F548.2030506@microgate.com> X-Mailer: Claws Mail 3.7.2 (GTK+ 2.14.7; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 846 Lines: 18 > And no, I'm not sure my patch helps. I'd have expected > 'tty_buffer_flush()' to be something very rare, for example. But I also > didn't really check if we may do it some other way. It is rare for most applications > But I _am_ sure that it makes the code a whole lot more straightforward. > Bits that say "we're busy flushing" suddenly actually act that way, and > pointers that say "this is the head of the buffers" also act that wy. The more I look the more I think a mutex is the right answer. It also provides us with a "stop feeding me" lock for ldisc changes and tty close down bits. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/