Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759823AbXFVXQu (ORCPT ); Fri, 22 Jun 2007 19:16:50 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751787AbXFVXQn (ORCPT ); Fri, 22 Jun 2007 19:16:43 -0400 Received: from gate.crashing.org ([63.228.1.57]:40962 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751385AbXFVXQn (ORCPT ); Fri, 22 Jun 2007 19:16:43 -0400 Subject: Re: Fix signalfd interaction with thread-private signals From: Benjamin Herrenschmidt To: Linus Torvalds Cc: Oleg Nesterov , Davide Libenzi , Nicholas Miell , Linux Kernel Mailing List In-Reply-To: References: <20070620111415.GA91@tv-sign.ru> <20070621082509.GA88@tv-sign.ru> <20070621182340.GA92@tv-sign.ru> <20070621185856.GA153@tv-sign.ru> <1182468604.24740.22.camel@localhost.localdomain> <20070622084034.GA134@tv-sign.ru> <1182512473.24740.54.camel@localhost.localdomain> <20070622160405.GA189@tv-sign.ru> <1182551618.24740.79.camel@localhost.localdomain> Content-Type: text/plain Date: Sat, 23 Jun 2007 09:16:30 +1000 Message-Id: <1182554190.24740.84.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.10.1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1027 Lines: 27 On Fri, 2007-06-22 at 15:47 -0700, Linus Torvalds wrote: > Quite frankly, it strikes me that if we want to do this, then we shouldn't > save the _process_ information at all, we should save the "sighand" > instead. > > So either we save the process info, or we save the sighand, but saving the > "group_leader" seems totally bogus. Especially as the group leader can > change (by execve()). > > One thing that strikes me as I look at that function is that the whole > signalfd thing doesn't seem to do any reference counting. Ie it looks > totally buggy wrt passing the resulting fd off to somebody else, and then > exiting in the original process. > > What did I miss? Probably nothing... doesn't look good. What are the lifetime rules of a struct sighand tho ? Ben. - 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/