From: alison.schofield@intel.com
To: Dan Williams <dan.j.williams@intel.com>,
Ira Weiny <ira.weiny@intel.com>,
Vishal Verma <vishal.l.verma@intel.com>,
Ben Widawsky <bwidawsk@kernel.org>,
Dave Jiang <dave.jiang@intel.com>
Cc: Alison Schofield <alison.schofield@intel.com>, linux-cxl@vger.kernel.org
Subject: [PATCH v3 0/8] cxl: CXL Inject & Clear Poison
Date: Wed, 1 Mar 2023 13:36:25 -0800 [thread overview]
Message-ID: <cover.1677704994.git.alison.schofield@intel.com> (raw)
From: Alison Schofield <alison.schofield@intel.com>
Changes in v3:
- Built on cxl/next plus the Get Poison list patchset here:
https://lore.kernel.org/linux-cxl/cover.1676685180.git.alison.schofield@intel.com/
- Two new patches are appended to address Dan's deprecate ask:
cxl/memdev: Make inject and clear poison cmds kernel exclusive
cxl/mbox: Block inject and clear poison opcodes in raw mode
I didn't deprecate the ioctls as Dan suggested. Instead, I followed
on Ira's recent clean up wrt enabled and exclusive commands, deciding
that the honest response to a cxl_query() would be 'Enabled' (if hardware
supports) and kernel 'Exclusive' (always). Please take a look.
- Move IS_ENABLED(CONFIG_CXL_POISON_INJECT) test into each attr check (Dan)
- Fail updates to poison_inject_max when poison list is not empty (DaveJ)
- Make poison_inject_max a sysfs attr, rather than module param (Dan)
- Kconfig: add note regarding debug intent (Dan)
- Kept Jonathan's Reviewed-by Tag on Patches 1-6
Link to v2: https://lore.kernel.org/linux-cxl/cover.1674101475.git.alison.schofield@intel.com/
Introducing Inject and Clear Poison support for CXL Devices.
These are optional commands, meaning not all CXL devices must support
them. The sysfs attributes, inject_poison and clear_poison, are only
visible for devices reporting support of the capability and when the
kernel Kconfig option CONFIG_CXL_POISON_INJECT is on. (Default: off)
Example:
# echo 0x40000000 > /sys/bus/cxl/devices/mem1/inject_poison
# echo 1 > /sys/bus/cxl/devices/mem1/trigger_poison_list
cxl_poison: memdev=mem1 pcidev=cxl_mem.1 region= region_uuid=00000000-0000-0000-0000-000000000000 hpa=0xffffffffffffffff dpa=0x40000000 length=0x40 source=Injected flags= overflow_time=0
Alison Schofield (8):
cxl/memdev: Add support for the Inject Poison mailbox command
cxl/memdev: Add support for the Clear Poison mailbox command
tools/testing/cxl: Mock the Inject Poison mailbox command
tools/testing/cxl: Mock the Clear Poison mailbox command
tools/testing/cxl: Use injected poison for get poison list
tools/testing/cxl: Add a sysfs attr to test poison injection limits
cxl/memdev: Make inject and clear poison cmds kernel exclusive
cxl/mbox: Block inject and clear poison opcodes in raw mode
Documentation/ABI/testing/sysfs-bus-cxl | 40 +++++
drivers/cxl/Kconfig | 11 ++
drivers/cxl/core/mbox.c | 6 +
drivers/cxl/core/memdev.c | 162 ++++++++++++++++++
drivers/cxl/cxlmem.h | 11 ++
include/uapi/linux/cxl_mem.h | 21 ++-
tools/testing/cxl/test/mem.c | 216 +++++++++++++++++++++---
7 files changed, 443 insertions(+), 24 deletions(-)
--
2.37.3
next reply other threads:[~2023-03-01 21:36 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-01 21:36 alison.schofield [this message]
2023-03-01 21:36 ` [PATCH v3 1/8] cxl/memdev: Add support for the Inject Poison mailbox command alison.schofield
2023-03-30 18:13 ` Jonathan Cameron
2023-03-30 18:44 ` Jonathan Cameron
2023-03-01 21:36 ` [PATCH v3 2/8] cxl/memdev: Add support for the Clear " alison.schofield
2023-03-30 18:16 ` Jonathan Cameron
2023-03-01 21:36 ` [PATCH v3 3/8] tools/testing/cxl: Mock the Inject " alison.schofield
2023-03-01 21:36 ` [PATCH v3 4/8] tools/testing/cxl: Mock the Clear " alison.schofield
2023-03-01 21:36 ` [PATCH v3 5/8] tools/testing/cxl: Use injected poison for get poison list alison.schofield
2023-03-01 21:36 ` [PATCH v3 6/8] tools/testing/cxl: Add a sysfs attr to test poison injection limits alison.schofield
2023-03-01 22:16 ` Alison Schofield
2023-03-01 21:36 ` [PATCH v3 7/8] cxl/memdev: Make inject and clear poison cmds kernel exclusive alison.schofield
2023-03-30 18:24 ` Jonathan Cameron
2023-03-01 21:36 ` [PATCH v3 8/8] cxl/mbox: Block inject and clear poison opcodes in raw mode alison.schofield
2023-03-30 18:25 ` Jonathan Cameron
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=cover.1677704994.git.alison.schofield@intel.com \
--to=alison.schofield@intel.com \
--cc=bwidawsk@kernel.org \
--cc=dan.j.williams@intel.com \
--cc=dave.jiang@intel.com \
--cc=ira.weiny@intel.com \
--cc=linux-cxl@vger.kernel.org \
--cc=vishal.l.verma@intel.com \
/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).