From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ingo Molnar Subject: Re: spinlock contention of files->file_lock Date: Wed, 2 Oct 2013 07:13:19 +0200 Message-ID: <20131002051319.GB27982@gmail.com> References: <1380589503.5326.13.camel@edumazet-glaptop.roam.corp.google.com> <1380663718.19002.49.camel@edumazet-glaptop.roam.corp.google.com> <20131001220453.GY13318@ZenIV.linux.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Eric Dumazet , Linus Torvalds , Peter Zijlstra , Waiman Long , Benjamin Herrenschmidt , "Chandramouleeswaran, Aswin" , Linux Kernel Mailing List , linux-fsdevel To: Al Viro Return-path: Received: from mail-ee0-f51.google.com ([74.125.83.51]:35610 "EHLO mail-ee0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752908Ab3JBFNY (ORCPT ); Wed, 2 Oct 2013 01:13:24 -0400 Content-Disposition: inline In-Reply-To: <20131001220453.GY13318@ZenIV.linux.org.uk> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: * Al Viro wrote: > On Tue, Oct 01, 2013 at 02:41:58PM -0700, Eric Dumazet wrote: > > Maybe I am missing something obvious ? > > Yes. do_execve_common() starts with unshare_files(); there can be > no other thread capable of modifying that descriptor table. Btw., might the Android Binder: drivers/staging/android/binder.c: struct files_struct *files = proc->files; ... drivers/staging/android/binder.c: __fd_install(proc->files, fd, file); ... drivers/staging/android/binder.c: retval = __close_fd(proc->files, fd); violate that assumption? Thanks, Ingo