Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932924AbXBTM4g (ORCPT ); Tue, 20 Feb 2007 07:56:36 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932925AbXBTM4g (ORCPT ); Tue, 20 Feb 2007 07:56:36 -0500 Received: from netops-testserver-3-out.sgi.com ([192.48.171.28]:55218 "EHLO netops-testserver-3.corp.sgi.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932924AbXBTM4f (ORCPT ); Tue, 20 Feb 2007 07:56:35 -0500 Date: Tue, 20 Feb 2007 06:56:26 -0600 From: Robin Holt To: David Howells Cc: "Kawai, Hidehiro" , Andrew Morton , kernel list , Pavel Machek , Robin Holt , Alan Cox , Masami Hiramatsu , sugita , Satoshi OSHIMA , "Hideo AOKI@redhat" Subject: Re: [PATCH 3/4] coredump: ELF-FDPIC: enable to omit anonymous shared memory Message-ID: <20070220125626.GC27551@lnx-holt.americas.sgi.com> References: <45DAC32B.4030603@hitachi.com> <45D5B483.3020502@hitachi.com> <45D5B2E3.3030607@hitachi.com> <20368.1171638335@redhat.com> <18826.1171969097@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <18826.1171969097@redhat.com> User-Agent: Mutt/1.4.2.2i Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1025 Lines: 38 On Tue, Feb 20, 2007 at 10:58:17AM +0000, David Howells wrote: > Kawai, Hidehiro wrote: > Actually, I don't think the locking is that hard or that complex. > > int do_coredump(long signr, int exit_code, struct pt_regs * regs) > { > > > down_read(&coredump_settings_sem); > > ... > > fail: > up_read(&coredump_settings_sem); > return retval; > } > > And: > > static ssize_t proc_coredump_omit_anon_shared_write(struct file *file, > const char __user *buf, > size_t count, > loff_t *ppos) > { > > > down_write(&coredump_settings_sem); If the dump has started, do we want to change this to a trylock and skip changing the value if it is already locked? Thanks, Robin - 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/