nvdimm.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Dan Williams <dan.j.williams@intel.com>
To: Davidlohr Bueso <dave@stgolabs.net>, <dan.j.williams@intel.com>
Cc: <x86@kernel.org>, <nvdimm@lists.linux.dev>,
	<linux-cxl@vger.kernel.org>, <peterz@infradead.org>,
	<bp@alien8.de>, <akpm@linux-foundation.org>,
	<dave.jiang@intel.com>, <Jonathan.Cameron@huawei.com>,
	<vishal.l.verma@intel.com>, <ira.weiny@intel.com>,
	<a.manzanares@samsung.com>, <linux-kernel@vger.kernel.org>,
	<dave@stgolabs.net>, <hch@lst.de>
Subject: RE: [PATCH -next] memregion: Add arch_flush_memregion() interface
Date: Mon, 29 Aug 2022 16:02:22 -0700	[thread overview]
Message-ID: <630d457ee7739_259e5b29444@dwillia2-xfh.jf.intel.com.notmuch> (raw)
In-Reply-To: <20220829212918.4039240-1-dave@stgolabs.net>

[ add Christoph ]

Davidlohr Bueso wrote:
> With CXL security features, global CPU cache flushing nvdimm requirements
> are no longer specific to that subsystem, even beyond the scope of
> security_ops. CXL will need such semantics for features not necessarily
> limited to persistent memory.
> 
> The functionality this is enabling is to be able to instantaneously
> secure erase potentially terabytes of memory at once and the kernel
> needs to be sure that none of the data from before the secure is still
> present in the cache. It is also used when unlocking a memory device
> where speculative reads and firmware accesses could have cached poison
> from before the device was unlocked.
> 
> This capability is typically only used once per-boot (for unlock), or
> once per bare metal provisioning event (secure erase), like when handing
> off the system to another tenant or decommissioning a device.
> 
> Users must first call arch_has_flush_memregion() to know whether this
> functionality is available on the architecture. Only enable it on x86-64
> via the wbinvd() hammer.
> 
> Signed-off-by: Davidlohr Bueso <dave@stgolabs.net>
> ---
> 
> Changes from v2 (https://lore.kernel.org/all/20220819171024.1766857-1-dave@stgolabs.net/):
> - Redid to use memregion based interfaces + VMM check on x86 (Dan)
> - Restricted the flushing to x86-64.
> 
> Note: Since we still are dealing with a physical "range" at this level,
> added the spa range for nfit even though this is unused.

Looks reasonable to me.

Reviewed-by: Dan Williams <dan.j.williams@intel.com>

  reply	other threads:[~2022-08-29 23:02 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-29 21:29 [PATCH -next] memregion: Add arch_flush_memregion() interface Davidlohr Bueso
2022-08-29 23:02 ` Dan Williams [this message]
2022-09-07 14:36 ` Davidlohr Bueso
2022-09-07 16:46   ` Dan Williams
2022-09-07 16:05 ` Borislav Petkov
2022-09-07 16:22   ` Davidlohr Bueso
2022-09-07 16:52     ` Dan Williams
2022-09-07 17:24       ` Davidlohr Bueso
2022-09-08  4:35       ` Borislav Petkov
2022-09-08  6:53         ` Dan Williams
2022-09-08 13:00           ` Jonathan Cameron
2022-09-08  4:31     ` Borislav Petkov
2022-09-07 22:30 ` Andrew Morton
2022-09-08  1:07   ` Dan Williams
2022-09-08 13:13     ` Jonathan Cameron
2022-09-08 22:51       ` Dan Williams
2022-09-08 23:00         ` Andrew Morton
2022-09-08 23:22           ` Dan Williams
2022-09-09 11:43             ` Jonathan Cameron
2022-09-13 15:56               ` Davidlohr Bueso

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=630d457ee7739_259e5b29444@dwillia2-xfh.jf.intel.com.notmuch \
    --to=dan.j.williams@intel.com \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=a.manzanares@samsung.com \
    --cc=akpm@linux-foundation.org \
    --cc=bp@alien8.de \
    --cc=dave.jiang@intel.com \
    --cc=dave@stgolabs.net \
    --cc=hch@lst.de \
    --cc=ira.weiny@intel.com \
    --cc=linux-cxl@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nvdimm@lists.linux.dev \
    --cc=peterz@infradead.org \
    --cc=vishal.l.verma@intel.com \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).