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=-11.4 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=no 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 EFE7EC433E0 for ; Tue, 19 May 2020 12:57:04 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id AFA5D2081A for ; Tue, 19 May 2020 12:57:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="UmMeMog9" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org AFA5D2081A Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 58370900003; Tue, 19 May 2020 08:57:04 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 533EE900002; Tue, 19 May 2020 08:57:04 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 42310900003; Tue, 19 May 2020 08:57:04 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0094.hostedemail.com [216.40.44.94]) by kanga.kvack.org (Postfix) with ESMTP id 26DDD900002 for ; Tue, 19 May 2020 08:57:04 -0400 (EDT) Received: from smtpin02.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id D037E3D15 for ; Tue, 19 May 2020 12:57:03 +0000 (UTC) X-FDA: 76833468726.02.look59_36b74e12770f X-HE-Tag: look59_36b74e12770f X-Filterd-Recvd-Size: 4161 Received: from mail-pl1-f195.google.com (mail-pl1-f195.google.com [209.85.214.195]) by imf07.hostedemail.com (Postfix) with ESMTP for ; Tue, 19 May 2020 12:57:03 +0000 (UTC) Received: by mail-pl1-f195.google.com with SMTP id a13so4042850pls.8 for ; Tue, 19 May 2020 05:57:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=Vb6RqiVTVLq+YrUuz3LxddPdQqJTjNGlI2TyjoAVayI=; b=UmMeMog9h65hOoFUxo5ezFKF35KsGYdjQNjiVmeUA+13MrgKDGigtHSs58ZhwkbR0U F7JbpupKVYd/J9zm0+MWWDg/CLbNoqKKuKQgC4SPuW+YIHOmlqkxVjss8cpXoRPh2N43 EaEPePlLuFDbKrGx9Zskp0g1EpgASSID3ZNnXJx0w7kSuIz9/8djXqp7IGJkrdTaqzUY Y7I5Rn7WKjEUF1yj4JDBL2UofpLojH0/rOPkJlQ4yEKbzLNjbhS8z2N+Z2AoDqguUDeA 6J5iI0tlsK7vTrykiqPBk0hMrA7dYkkBp30VfvJ5KtiYwXyIFAQ1+9OWx39e94gWKkWQ oWLw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=Vb6RqiVTVLq+YrUuz3LxddPdQqJTjNGlI2TyjoAVayI=; b=jlyipwL7XZhZpk6C0h2MAcb8In4IgzUt14pF6/u7p4zzw56J7XB9LHa0sxijwbxuW7 IWbfhG6ctgL86m3fca0MGkiXxx8bVWfq3/4A4ZzOyRX5JNCMZAz4sisltKKogJry2hQq neOEFeia3BT+wO3jna32TWv54RoX0yrz1yqz33/tL4VSwzA9M7CSfBeAuP6scs1JSdx+ /5GpPNrNJzRfVYckigKqc2WDIvojZoN72Y70YQLSO/hvm4FIahS9Lu95v4qgnbJcNkLv tKOJWOFofayizaNPiEIfwIfStoQWcKttk2I9AiwZDNxgYgMPNNgID2FKDz2zSMQHlkVm 2GhQ== X-Gm-Message-State: AOAM5328YaMitzqMWxP9viKZb2i7KHuDbcMlpG3maqVvWp5efGIhgy// lSsXBBmj0HL3/SFyZLU42v4ajQ== X-Google-Smtp-Source: ABdhPJw4SNWXARa/duHpULSqdLbi/FXph3PxjLqrhOlWqgGBrEei2TrBrCfbjITfVi7yd4sT5y4ZQA== X-Received: by 2002:a17:90a:9292:: with SMTP id n18mr4897759pjo.3.1589893022302; Tue, 19 May 2020 05:57:02 -0700 (PDT) Received: from google.com ([2620:15c:2cd:202:2523:d194:de3b:636f]) by smtp.gmail.com with ESMTPSA id q4sm6761807pfu.42.2020.05.19.05.56.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 May 2020 05:56:58 -0700 (PDT) Date: Tue, 19 May 2020 05:56:56 -0700 From: Michel Lespinasse To: Vlastimil Babka Cc: Andrew Morton , linux-mm , LKML , Peter Zijlstra , Laurent Dufour , Matthew Wilcox , Liam Howlett , Jerome Glisse , Davidlohr Bueso , David Rientjes , Hugh Dickins , Ying Han , Jason Gunthorpe , Daniel Jordan Subject: Re: [PATCH v5 08/10] mmap locking API: add MMAP_LOCK_INITIALIZER Message-ID: <20200519125656.GB189720@google.com> References: <20200422001422.232330-1-walken@google.com> <20200422001422.232330-9-walken@google.com> <90cfe0e5-2ec9-3a10-0ce6-245bb456a120@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <90cfe0e5-2ec9-3a10-0ce6-245bb456a120@suse.cz> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Mon, May 18, 2020 at 12:45:06PM +0200, Vlastimil Babka wrote: > On 4/22/20 2:14 AM, Michel Lespinasse wrote: > > Define a new initializer for the mmap locking api. > > Initially this just evaluates to __RWSEM_INITIALIZER as the API > > is defined as wrappers around rwsem. > > > > Signed-off-by: Michel Lespinasse > > > Reviewed-by: Vlastimil Babka > > > Nit below. > > > +#define MMAP_LOCK_INITIALIZER(name) \ > > + .mmap_sem = __RWSEM_INITIALIZER(name.mmap_sem), > > "(name).mmap_sem" is safer in a macro? Thanks, applied in next version. -- Michel "Walken" Lespinasse A program is never fully debugged until the last user dies.