From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 93813C4361A for ; Fri, 4 Dec 2020 05:19:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4C3EE22582 for ; Fri, 4 Dec 2020 05:19:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727885AbgLDFTn (ORCPT ); Fri, 4 Dec 2020 00:19:43 -0500 Received: from mx2.suse.de ([195.135.220.15]:51198 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725300AbgLDFTm (ORCPT ); Fri, 4 Dec 2020 00:19:42 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 81AF5B1C4; Fri, 4 Dec 2020 05:19:01 +0000 (UTC) Date: Thu, 3 Dec 2020 20:54:01 -0800 From: Davidlohr Bueso To: Linus Torvalds Cc: "Eric W. Biederman" , Waiman Long , Linux Kernel Mailing List , Peter Zijlstra , Ingo Molnar , Will Deacon , Jann Horn , Vasiliy Kulikov , Al Viro , Bernd Edlinger , Oleg Nesterov , Christopher Yeoh , Cyrill Gorcunov , Sargun Dhillon , Christian Brauner , Arnd Bergmann , Arnaldo Carvalho de Melo Subject: Re: [PATCH 0/3] exec: Transform exec_update_mutex into a rw_semaphore Message-ID: <20201204045401.4njfkrgpbmeak4qw@linux-p48b.lan> References: <87tut2bqik.fsf@x220.int.ebiederm.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20180716 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 03 Dec 2020, Linus Torvalds wrote: >On Thu, Dec 3, 2020 at 12:10 PM Eric W. Biederman wrote: >> >> The simplest and most robust solution appears to be making >> exec_update_mutex a read/write lock and having everything execept for >> exec take the lock for read. > >Looks sane to me. > >I'd like the locking people to look at the down_read_*() functions, >even if they look simple. Adding Waiman and Davidlohr to the cc just >in case they would look at that too, since they've worked on that >code. rwsem changes look good to me - and 3/3 looks much nicer than the previous alternatives to the deadlock. Acked-by: Davidlohr Bueso