Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965705Ab2FASvf (ORCPT ); Fri, 1 Jun 2012 14:51:35 -0400 Received: from mail-we0-f174.google.com ([74.125.82.174]:44487 "EHLO mail-we0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932805Ab2FASve (ORCPT ); Fri, 1 Jun 2012 14:51:34 -0400 MIME-Version: 1.0 In-Reply-To: <1338574627.2760.1545.camel@edumazet-glaptop> References: <4FC6189B.9080909@fusionio.com> <1338402812.2760.413.camel@edumazet-glaptop> <4FC66D3D.6080509@fusionio.com> <1338404902.2760.451.camel@edumazet-glaptop> <1338410107.2760.544.camel@edumazet-glaptop> <1338456918.2760.1318.camel@edumazet-glaptop> <1338574627.2760.1545.camel@edumazet-glaptop> From: Linus Torvalds Date: Fri, 1 Jun 2012 11:51:13 -0700 X-Google-Sender-Auth: BWcKaI3rkgwmS11rZhnN1hRBon8 Message-ID: Subject: Re: [PATCH] tty: add lockdep annotations To: Eric Dumazet Cc: Alan Cox , "linux-kernel@vger.kernel.org" , Jens Axboe Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1191 Lines: 32 On Fri, Jun 1, 2012 at 11:17 AM, Eric Dumazet wrote: > > About 10% of boots on my machine, and this looks like (hand written) > > general protection fault: 0000 [#1] SMP DEBUG_PAGEALLOC > ... > RIP : tty_shutdown+0x15/)x70 Ok, DEBUG_PAGEALLOC and with that offset fairly early in tty_shutdown, it's almost certainly one of the accesses in the tty->driver->ops->remove chain when it does the (inlined) tty_driver_remove_tty(tty->driver, tty); you could check which one it is at that offset 0x15, but I think both the ops and the driver structures should be statically allocated, so I suspect it's the "tty" itself that is already freed. Odd. But yes, smells very much like a refcount issue, probably due to broken locking. Does the problem go away if you revert commits d29f3ef39be4 ("tty_lock: Localise the lock") and 3af502b96649 ("tty_lock: undo the old tty_lock use on the ctty")? Linus -- 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/