Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp3752013ybg; Mon, 28 Oct 2019 18:45:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqz7FhtLlFY59zFSF7ck55D607spH7+LODfQipA2yMEz14D6YXBhgD4AW3M8HwhPtnTy2UV/ X-Received: by 2002:a17:906:f15:: with SMTP id z21mr847669eji.119.1572313550177; Mon, 28 Oct 2019 18:45:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572313550; cv=none; d=google.com; s=arc-20160816; b=STAptXMuEc3VqJOPuqkovp8o/5In21WyobgFoarNsSfnHAz4zWIqLug95lfm9GeESY JvLJmVgMguaxf6bsyDLMMByQnJpe9eQ/KIHlJgvCoI2C1ll2oj1WeSynK5pjKbG3wIQ6 kEfavIrbm3dHSO6usSBihI84obD1qMiaj0eLjleG7AUnUxF7+82/GCTtpk3/o4kNVeGG EsEhB/ts79LS4pRTck0xTimyWpUjjoYjDxLeWvAakXd9tEozeX1F5frsjyPAB6Go5k7k WFkQitD5rNqsmGbB3tIs7knnX+0bXF2VXqluH6UWsFL9w1MsfME741Ny8fgf27RsnqqK tQgw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=cIXc50+5NShj5GVfLHp2Ko6erwsoS1EC2cpl3eH9z0g=; b=0hDbNj0+Ca/6ASbIJmZwU7+SUQJJcCtyk2QUySDNQ5D7RDuGj+5b/l6ZN5FBTU+/KY 6wm0zDUyaMnUndLNsdG8H9R24C+faPv12HOJdN0D5qWPm/R64JeoIb268PDWUL+jNF/5 YXqIISOcqGWYsXaemsF8k+VcJI7Xm+JA0Mje2i25ywzxIneGlnk7ch0Ia1Tmz7D9yF3e zAvy6fkOkoyyAX7l5FX8q7kt2cXjWG2mZdGQiibjMIBRv7kYs31Mh/5dhOtJb3P/DR7t rPqKtk1GpopAmj/+ylv+gF0TWZ3D0bbfcjYqJPKs1Q/UlcBzzTxgqnBYVEYeI/3WmvAG +HiQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@shutemov-name.20150623.gappssmtp.com header.s=20150623 header.b=f1WGJM1k; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 13si5791541ejw.79.2019.10.28.18.45.26; Mon, 28 Oct 2019 18:45:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@shutemov-name.20150623.gappssmtp.com header.s=20150623 header.b=f1WGJM1k; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389085AbfJ1MbZ (ORCPT + 99 others); Mon, 28 Oct 2019 08:31:25 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:36578 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729360AbfJ1MbZ (ORCPT ); Mon, 28 Oct 2019 08:31:25 -0400 Received: by mail-lf1-f65.google.com with SMTP id u16so7657988lfq.3 for ; Mon, 28 Oct 2019 05:31:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shutemov-name.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=cIXc50+5NShj5GVfLHp2Ko6erwsoS1EC2cpl3eH9z0g=; b=f1WGJM1kyUToCExwbx/CdRQ76h7eSHjP+Y2ccs7CiP8DAWylaZe+hpT8xFznruu1DT 7ajCJV0H9YK/GJpA+RJ5fJgGUN3PA3nB6KeRngGp4hqooSTu6FsxJxQ1B/r7ohchci1J rOdq7M75ixPhHlQlbvE/6BfBwcQBea5JRZn0jBwi5s8lO0Iw410C6OV1CBEefaFxV0wE gQ9Y2fVed8YRw7RTDjOevxVTVHdbKabSDZSwr2y0wl1HVfJemKYwWHjL06zOfxDuqLEP lBE4RP4mp8ioGF3UESn0+NOuFrS+O1PUkD+bE3LdcWSC1rFzkUTJQgSUGXXGhk6G+/8v 21Mg== 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:user-agent; bh=cIXc50+5NShj5GVfLHp2Ko6erwsoS1EC2cpl3eH9z0g=; b=POFwRP1bAU/2pW+if0tvSUsiPVpgdldfZJU8RjYr2zeD5ch8S2pwE+k3T4sd8zScvo nmSAj7LSiF/In9AxnXBTGvV8pYyqtwOutkH7ZVz0S759z81FRfdZfEFW2BODmzyign+4 uoWJISP8UY5Dh2TNWwcTTiCahg2fa1ALRuZp7X6Phj3GBg6t8Q7gRHNP2cUQ0pHKNVNf wBiS1YJDEvhPtsAcX4A2JSgWWmVv5wm6UoKD9kzflZE6m+Pg8nGcArGikD3tGzyKYehL x3SGeSr+GrneFEuOcVn7iUdutrO9yrHkPz4p6z6bsXcu3vogrQKaLRSzPHsbpRawoFFW qhmA== X-Gm-Message-State: APjAAAVYMImfOg4Wp8hmPjoslQpdflsgztwC75H4kNjMqr4dPARH3VKW vwPaxTu3/PcfezMPfIltPp+aBA== X-Received: by 2002:a19:c790:: with SMTP id x138mr4355216lff.61.1572265883446; Mon, 28 Oct 2019 05:31:23 -0700 (PDT) Received: from box.localdomain ([86.57.175.117]) by smtp.gmail.com with ESMTPSA id e8sm7535160ljf.1.2019.10.28.05.31.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Oct 2019 05:31:22 -0700 (PDT) Received: by box.localdomain (Postfix, from userid 1000) id B38B1100242; Mon, 28 Oct 2019 15:31:24 +0300 (+03) Date: Mon, 28 Oct 2019 15:31:24 +0300 From: "Kirill A. Shutemov" To: Mike Rapoport Cc: linux-kernel@vger.kernel.org, Alexey Dobriyan , Andrew Morton , Andy Lutomirski , Arnd Bergmann , Borislav Petkov , Dave Hansen , James Bottomley , Peter Zijlstra , Steven Rostedt , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , linux-api@vger.kernel.org, linux-mm@kvack.org, x86@kernel.org, Mike Rapoport Subject: Re: [PATCH RFC] mm: add MAP_EXCLUSIVE to create exclusive user mappings Message-ID: <20191028123124.ogkk5ogjlamvwc2s@box> References: <1572171452-7958-1-git-send-email-rppt@kernel.org> <1572171452-7958-2-git-send-email-rppt@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1572171452-7958-2-git-send-email-rppt@kernel.org> User-Agent: NeoMutt/20180716 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Oct 27, 2019 at 12:17:32PM +0200, Mike Rapoport wrote: > From: Mike Rapoport > > The mappings created with MAP_EXCLUSIVE are visible only in the context of > the owning process and can be used by applications to store secret > information that will not be visible not only to other processes but to the > kernel as well. > > The pages in these mappings are removed from the kernel direct map and > marked with PG_user_exclusive flag. When the exclusive area is unmapped, > the pages are mapped back into the direct map. I probably blind, but I don't see where you manipulate direct map... -- Kirill A. Shutemov