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=-6.8 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT 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 B9B57C433E6 for ; Tue, 1 Sep 2020 09:19:20 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 5D32A2087D for ; Tue, 1 Sep 2020 09:19:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="RXZgt6M0" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 5D32A2087D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id D30816B005D; Tue, 1 Sep 2020 05:19:19 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id CB95C6B0062; Tue, 1 Sep 2020 05:19:19 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B5AAF6B0068; Tue, 1 Sep 2020 05:19:19 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0073.hostedemail.com [216.40.44.73]) by kanga.kvack.org (Postfix) with ESMTP id 9A34B6B005D for ; Tue, 1 Sep 2020 05:19:19 -0400 (EDT) Received: from smtpin22.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 5D8F2DB3B for ; Tue, 1 Sep 2020 09:19:19 +0000 (UTC) X-FDA: 77213944038.22.plant29_5905e9327097 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin22.hostedemail.com (Postfix) with ESMTP id 2ECA918038E68 for ; Tue, 1 Sep 2020 09:19:19 +0000 (UTC) X-HE-Tag: plant29_5905e9327097 X-Filterd-Recvd-Size: 5902 Received: from mail-pl1-f193.google.com (mail-pl1-f193.google.com [209.85.214.193]) by imf09.hostedemail.com (Postfix) with ESMTP for ; Tue, 1 Sep 2020 09:19:18 +0000 (UTC) Received: by mail-pl1-f193.google.com with SMTP id bh1so229020plb.12 for ; Tue, 01 Sep 2020 02:19:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LKDhu57eucllC3stfGqQp1RE01bX+WGNmYWYWmVH8uA=; b=RXZgt6M0hedr66aPYeE2aauHPij9YS02v77RUWGPdFoRPTmaHiWoV2/ZHZGvh2s+PH z8B4C/jKSh6jqgfT68oeMtzuwAbB17NiYecsPX6EPenPw5YQNEJIot+4EXtvBiVDIUYj wAnkzO7OHtxYdN/UTr1YslXdsXWMtlhFSqNjPPRoEE21Y3vbuhXzaiWig/GqXceOHNrn 4FrFXHeqnQojl9FcQNEmRS6zxtRZTp6PcYdWrZnD6u+GS9TEt5HDI/8LtOkgSs0DP1W/ ebBBKVWfe7ZAjjC+FCpWfpjBoMZeTrcb4ERxEorsNO2Co7B0GJ4o1kROXApEH3lLX0yG 8Q4Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LKDhu57eucllC3stfGqQp1RE01bX+WGNmYWYWmVH8uA=; b=iOBX3wLq8IQo/SJxN5WwjfFIzZM3EWBfwoQQZA/HyBj9PY2dLoq41bYNrCDFqymEFW bIPkCQnF14g7ucRX1njvu0Y8TzhhR/G3YyqhXL3lfcrdwFzAFGbT2VMWoelDeODCM1jt kCWzxodonh0URi3pZQ4d9nOs2bFDxe+iBWecZp0m88hIHgYs3PUeIrOfkI86/vawLu86 gH6kR6pPIZHwJmUlazDyomS8F8oJInPbqmJWUiSmPkKTSa7vsjHaDYJDvDx5lETYTGI1 tje2QSWSOZPoRpsp8LZovJpNx6KaqXC0NfdzZKkHuubvWPxhgnxkLgEwqu33oBT5UdXl LOxg== X-Gm-Message-State: AOAM532pRWMEa8BdljVLtk3nlZgG2NKbPcXmETSkX7oAI67mjjKgfEqn DwJA52TeCQ2d0U8aT6ebSa3cgw== X-Google-Smtp-Source: ABdhPJxNhlDc7MD1X6GJIQAMM12QfFMgW/k9pVSpFNWL3PeQOJU5cYC3DaCNmL0oO3FG1jrng2zvKw== X-Received: by 2002:a17:90a:e98f:: with SMTP id v15mr684361pjy.41.1598951957568; Tue, 01 Sep 2020 02:19:17 -0700 (PDT) Received: from nagraj.local ([49.206.21.239]) by smtp.gmail.com with ESMTPSA id u191sm1337707pgu.56.2020.09.01.02.19.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Sep 2020 02:19:16 -0700 (PDT) From: Sumit Semwal To: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Alexey Dobriyan , Jonathan Corbet Cc: Mauro Carvalho Chehab , Kees Cook , Michal Hocko , Colin Cross , Alexey Gladkov , Matthew Wilcox , Jason Gunthorpe , "Kirill A . Shutemov" , Michel Lespinasse , =?UTF-8?q?Michal=20Koutn=C3=BD?= , Song Liu , Huang Ying , Vlastimil Babka , Yang Shi , chenqiwu , Mathieu Desnoyers , John Hubbard , Mike Christie , Bart Van Assche , Amit Pundir , Thomas Gleixner , Christian Brauner , Daniel Jordan , Adrian Reber , Nicolas Viennot , Al Viro , Thomas Cedeno , linux-fsdevel@vger.kernel.org, John Stultz , Sumit Semwal Subject: [PATCH v6 0/3] Anonymous VMA naming patches Date: Tue, 1 Sep 2020 14:48:58 +0530 Message-Id: <20200901091901.19779-1-sumit.semwal@linaro.org> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 X-Rspamd-Queue-Id: 2ECA918038E68 X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam04 Content-Transfer-Encoding: quoted-printable 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: Version v4 of these patches was sent by Colin Cross a long time ago [1] and [2]. At the time, these patches were not merged, and it looks like th= ey just fell off the radar since. In our efforts to run Android on mainline kernels, we realised that since= past some time, this patchset is needed for Android to boot, hence I am re-pos= ting it to try and get these discussed and hopefully merged. For v5, I rebased these for v5.9-rc3 and fixed minor updates as required. --- v6: Rebased to v5.9-rc3 and addressed review comments: - added missing callers in fs/userfaultd.c - simplified the union - use the new access_remote_vm_locked() in show_map_vma() since that already holds mmap_lock [1]: https://lore.kernel.org/linux-mm/1383170047-21074-1-git-send-email-c= cross@android.com/ [2]: https://lore.kernel.org/linux-mm/1383170047-21074-2-git-send-email-c= cross@android.com/ Best, Sumit. Colin Cross (2): mm: rearrange madvise code to allow for reuse mm: add a field to store names for private anonymous memory Sumit Semwal (1): mm: memory: Add access_remote_vm_locked variant Documentation/filesystems/proc.rst | 2 + fs/proc/task_mmu.c | 24 +- fs/userfaultfd.c | 7 +- include/linux/mm.h | 7 +- include/linux/mm_types.h | 25 +- include/uapi/linux/prctl.h | 3 + kernel/sys.c | 32 +++ mm/interval_tree.c | 2 +- mm/madvise.c | 356 +++++++++++++++++------------ mm/memory.c | 49 +++- mm/mempolicy.c | 3 +- mm/mlock.c | 2 +- mm/mmap.c | 38 +-- mm/mprotect.c | 2 +- 14 files changed, 374 insertions(+), 178 deletions(-) --=20 2.28.0