Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp10009492rwl; Wed, 11 Jan 2023 13:07:50 -0800 (PST) X-Google-Smtp-Source: AMrXdXuqZOzfS39WYlUsIifO0O8lPAPZJ/+J60bwN/9HiK3elkF68YrUZ2g4kCX541qVsjM97VNI X-Received: by 2002:a17:902:b710:b0:192:6429:440e with SMTP id d16-20020a170902b71000b001926429440emr63425823pls.34.1673471269871; Wed, 11 Jan 2023 13:07:49 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1673471269; cv=pass; d=google.com; s=arc-20160816; b=z9Rq4gqOWLehsW4yj+p9Sd/P0Z36DPSidbrmnK3VS6aLXsrBU8m5dwTL60Da4QqSOA TCClmVpvn57HGaXubwHW9JlFpQ3gx5lekd4txTI8GJHWuXQWKtZOCKywAJtIelPVfL62 SL7Tuj4Xd+dIAwe3F+RmIQUG0Tf5tzz3yYa57WKMy4lMz2hvEyDBubp+43AI/EkXDOtD CCZsdlIDtxwNa8XOyNM69Xa8yAQBngxoeKiudWMsrn5SCugZhFrwc466MWA/GcztEQ8Z 5UEGZfXBZVhflk5K1qhZ9JNbKEb67+aOVi+A2BYMK634mNcpYu7+w+cDrHNrdw1dCUhq jNgQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:mail-followup-to:message-id:subject:cc:to :from:date:dkim-signature; bh=wS+GmrFpvGE25kGRXu4cr712LGdTZyedIO8N8BIAZig=; b=QCNfK9LosLhW7EHwvd2hguC+iXgoPn1kgmh/w4quKmf/AQByFZ6HRsKi6IbnYywLfz RmBr6myhexxRSBHxmk9P6R4LixgOsFJK75YQU0EBSfxY1IWVizJr9WVGoj30l8HsvgJQ wI6h++lz8bCDsuvOfuR+PHV0f6TLaSp+Af34UgI/YyjxRKCbn5a6a1s2NprCDSNzyrPM ua9syDY4roCs4XB9jltJeRxlrYKU+mKrav9ycD6QqY+/r7QLKBbUDpfYX3LGXicaZuj0 VHzx8GlkGo8PoL+zhGPTSdp2HkIdUSEOoXlojKRsHhgwzRlKT2+e2k0HlWRIMCkU6tKb Armg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@stgolabs.net header.s=dreamhost header.b=TaLEus5K; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q11-20020a65494b000000b004705b0ca9f1si15272922pgs.545.2023.01.11.13.07.43; Wed, 11 Jan 2023 13:07:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@stgolabs.net header.s=dreamhost header.b=TaLEus5K; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235674AbjAKU3f (ORCPT + 51 others); Wed, 11 Jan 2023 15:29:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44834 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233587AbjAKU2P (ORCPT ); Wed, 11 Jan 2023 15:28:15 -0500 Received: from crane.ash.relay.mailchannels.net (crane.ash.relay.mailchannels.net [23.83.222.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5387312ACA for ; Wed, 11 Jan 2023 12:27:17 -0800 (PST) X-Sender-Id: dreamhost|x-authsender|dave@stgolabs.net Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 632623C0F4C; Wed, 11 Jan 2023 20:18:54 +0000 (UTC) Received: from pdx1-sub0-mail-a292.dreamhost.com (unknown [127.0.0.6]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id D4E573C11B1; Wed, 11 Jan 2023 20:18:52 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1673468333; a=rsa-sha256; cv=none; b=o1bQ0SlWXjhpUMKJqMY++h4yREFBaCy0k2PvwXuAG4DrW1ePtRtSfUHKgUVtCEi7WmtBm1 K8LJstY7q4J9lkTMSkrlDtFxz2URtHnCMulJzWyHywRklCbvHwq3l7cB1v9Us1lk9knA6O j5DXed8U13miKm/nBWvuG4L/DdedVLuIzyfm/vDZ5MpNEfhCMxa2yYfOHrNwDZ0LiS/5pX oDxplhKMvj7qd5oNlYmzaZbgZazs1md5VqHFAbmttlIaf9ci7IYNjmjHh2XrnONnRyKMV2 uCWagx6IWpE2LoeEHzSiL10ss5NmpmrpjEaea/sZqd0SCHkhQ4IOSh+eM2j8eA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1673468333; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references:dkim-signature; bh=wS+GmrFpvGE25kGRXu4cr712LGdTZyedIO8N8BIAZig=; b=H2ZwOVFAek61HzxEZRCNoRGEE3TpYPeKeGa0IA69wusZLobsCkJ1AtQ2+tjkJaDhAi7zOo LbSf+vFGJSg1k2GwlqgIHTbJDKFNdbt3AlJL1RFo8DYO2uz0/m+/08aPY77Y31m4S0qBbv 4MCfRc3iYiP6cfvakD8UwW3PCyMR12fN1G/aCltT8A1awF0+n6eu1tdNAm28zBPNix02sY bnGimyZGhYs7QXBFFFFPuoXli3Yfw01sYBSFWLImeOP0gE+YIO9KnidAWfWuYBRvhvGQfu xURvDIuIDDDbmcNXzJg9wbar6skAsdpq6EcPZcolQ58aC/D5UW79rzGR0JAZug== ARC-Authentication-Results: i=1; rspamd-6f569fcb69-64672; auth=pass smtp.auth=dreamhost smtp.mailfrom=dave@stgolabs.net X-Sender-Id: dreamhost|x-authsender|dave@stgolabs.net X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|dave@stgolabs.net X-MailChannels-Auth-Id: dreamhost X-Plucky-Reign: 1875abcc38b9467a_1673468333974_2650156361 X-MC-Loop-Signature: 1673468333974:760517353 X-MC-Ingress-Time: 1673468333974 Received: from pdx1-sub0-mail-a292.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.99.229.59 (trex/6.7.1); Wed, 11 Jan 2023 20:18:53 +0000 Received: from offworld (ip72-199-50-187.sd.sd.cox.net [72.199.50.187]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: dave@stgolabs.net) by pdx1-sub0-mail-a292.dreamhost.com (Postfix) with ESMTPSA id 4NsfCD1FpdzBR; Wed, 11 Jan 2023 12:18:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=stgolabs.net; s=dreamhost; t=1673468331; bh=wS+GmrFpvGE25kGRXu4cr712LGdTZyedIO8N8BIAZig=; h=Date:From:To:Cc:Subject:Content-Type; b=TaLEus5Kxs4Xgc7EFqEAlAtzzYTJ5Ns/cPdthJRVyguJMTXO22OiW4rUNoNV+jYft MP/2MMYkp0ThoDJyLDqGUOnh0yCFasMO62DOBsGuNoJGZ5IrSxev/cRsPVvLbzqObC dgPbP3psGAjHX83NlTwPhHUjOImqFGW22izEgF06mr4IzxI9GVmAEjwi+ATAQMbJGa VoHJUBiUAd6BgFmPomIsoyyiDr9nV6YhCh1M2ftpXxiLnB4oB+VfaNNTtSVJWPqhoN x3RU+K3bNgNwCDLw3fSHcMpIaP/lxT1tXjlql6EzObb+ULQjwk/xfdmcwEFX2Dbbbn WfXRzd2RzPlaw== Date: Wed, 11 Jan 2023 11:52:50 -0800 From: Davidlohr Bueso To: Suren Baghdasaryan Cc: akpm@linux-foundation.org, michel@lespinasse.org, jglisse@google.com, mhocko@suse.com, vbabka@suse.cz, hannes@cmpxchg.org, mgorman@techsingularity.net, willy@infradead.org, liam.howlett@oracle.com, peterz@infradead.org, ldufour@linux.ibm.com, laurent.dufour@fr.ibm.com, paulmck@kernel.org, luto@kernel.org, songliubraving@fb.com, peterx@redhat.com, david@redhat.com, dhowells@redhat.com, hughd@google.com, bigeasy@linutronix.de, kent.overstreet@linux.dev, punit.agrawal@bytedance.com, lstoakes@gmail.com, peterjung1337@gmail.com, rientjes@google.com, axelrasmussen@google.com, joelaf@google.com, minchan@google.com, jannh@google.com, shakeelb@google.com, tatashin@google.com, edumazet@google.com, gthelen@google.com, gurua@google.com, arjunroy@google.com, soheil@google.com, hughlynch@google.com, leewalsh@google.com, posk@google.com, linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, x86@kernel.org, linux-kernel@vger.kernel.org, kernel-team@android.com Subject: Re: [PATCH 13/41] mm: introduce vma->vm_flags modifier functions Message-ID: <20230111195250.cj27sg4yoslbdjdp@offworld> Mail-Followup-To: Suren Baghdasaryan , akpm@linux-foundation.org, michel@lespinasse.org, jglisse@google.com, mhocko@suse.com, vbabka@suse.cz, hannes@cmpxchg.org, mgorman@techsingularity.net, willy@infradead.org, liam.howlett@oracle.com, peterz@infradead.org, ldufour@linux.ibm.com, laurent.dufour@fr.ibm.com, paulmck@kernel.org, luto@kernel.org, songliubraving@fb.com, peterx@redhat.com, david@redhat.com, dhowells@redhat.com, hughd@google.com, bigeasy@linutronix.de, kent.overstreet@linux.dev, punit.agrawal@bytedance.com, lstoakes@gmail.com, peterjung1337@gmail.com, rientjes@google.com, axelrasmussen@google.com, joelaf@google.com, minchan@google.com, jannh@google.com, shakeelb@google.com, tatashin@google.com, edumazet@google.com, gthelen@google.com, gurua@google.com, arjunroy@google.com, soheil@google.com, hughlynch@google.com, leewalsh@google.com, posk@google.com, linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, x86@kernel.org, linux-kernel@vger.kernel.org, kernel-team@android.com References: <20230109205336.3665937-1-surenb@google.com> <20230109205336.3665937-14-surenb@google.com> <20230111154726.stadwtzicabwh5u5@offworld> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20220429 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 11 Jan 2023, Suren Baghdasaryan wrote: >On Wed, Jan 11, 2023 at 8:13 AM Davidlohr Bueso wrote: >> >> On Mon, 09 Jan 2023, Suren Baghdasaryan wrote: >> >> >To keep vma locking correctness when vm_flags are modified, add modifier >> >functions to be used whenever flags are updated. >> >> How about moving this patch and the ones that follow out of this series, >> into a preliminary patchset? It would reduce the amount of noise in the >> per-vma lock changes, which would then only be adding the needed >> vma_write_lock()ing. > >How about moving those prerequisite patches to the beginning of the >patchset (before maple_tree RCU changes)? I feel like they do belong >in the patchset because as a standalone patchset it would be unclear >why I'm adding all these accessor functions and introducing this >churn. Would that be acceptable? imo the abstraction of vm_flags handling is worth being standalone and is easier to be picked up before a more complex locking scheme change. But either way, it's up to you. Thanks, Davidlohr