From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
To: <qemu-devel@nongnu.org>, Michael Tsirkin <mst@redhat.com>,
Fan Ni <fan.ni@samsung.com>
Cc: linux-cxl@vger.kernel.org, linuxarm@huawei.com,
"Ira Weiny" <ira.weiny@intel.com>,
"Alison Schofield" <alison.schofield@intel.com>,
"Michael Roth" <michael.roth@amd.com>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Dave Jiang" <dave.jiang@intel.com>,
"Markus Armbruster" <armbru@redhat.com>
Subject: [PATCH v3 0/6] hw/cxl: Poison get, inject, clear
Date: Thu, 2 Mar 2023 10:17:04 +0000 [thread overview]
Message-ID: <20230302101710.1652-1-Jonathan.Cameron@huawei.com> (raw)
v3:
- Gather tags. Thanks Fan Ni
- CC qapi maintainers. Thanks Michael Tsirkin
Note Alison has stated the kernel series will be post 6.3 material
so this one isn't quite as urgent as the patches it is based on.
However I think this series in a good state (plus I have lots more queued
behind it) hence promoting it from RFC.
Changes since RFC v2: Thanks to Markus for review.
- Improve documentation for QMP interface
- Add better description of baseline series
- Include precursor refactors around ret_code / CXLRetCode as this is now
the first series in suggeste merge order to rely on those.
- Include Ira's cxl_device_get_timestamp() function as it was better than
the equivalent in the RFC.
Based on following series (in order)
1. [PATCH v4 00/10] hw/cxl: CXL emulation cleanups and minor fixes for upstream
2. [PATCH v6 0/8] hw/cxl: RAS error emulation and injection
3. [PATCH v2 0/2] hw/cxl: Passthrough HDM decoder emulation
4. [PATCH v4 0/2] hw/mem: CXL Type-3 Volatile Memory Support
Based on: Message-Id: 20230206172816.8201-1-Jonathan.Cameron@huawei.com
Based-on: Message-id: 20230227112751.6101-1-Jonathan.Cameron@huawei.com
Based-on: Message-id: 20230227153128.8164-1-Jonathan.Cameron@huawei.com
Based-on: Message-id: 20230227163157.6621-1-Jonathan.Cameron@huawei.com
The series supports:
1) Injection of variable length poison regions via QMP (to fake real
memory corruption and ensure we deal with odd overflow corner cases
such as clearing the middle of a large region making the list overflow
as we go from one long entry to two smaller entries.
2) Read of poison list via the CXL mailbox.
3) Injection via the poison injection mailbox command (limited to 64 byte
entries)
4) Clearing of poison injected via either method.
The implementation is meant to be a valid combination of impdef choices
based on what the spec allowed. There are a number of places where it could
be made more sophisticated that we might consider in future:
* Fusing adjacent poison entries if the types match.
* Separate injection list and main poison list, to test out limits on
injected poison list being smaller than the main list.
* Poison list overflow event (needs event log support in general)
* Connecting up to the poison list error record generation (rather complex
and not needed for currently kernel handling testing).
As the kernel code is currently fairly simple, it is likely that the above
does not yet matter but who knows what will turn up in future!
Kernel patches:
[PATCH v7 0/6] CXL Poison List Retrieval & Tracing
cover.1676685180.git.alison.schofield@intel.com
[PATCH v2 0/6] cxl: CXL Inject & Clear Poison
cover.1674101475.git.alison.schofield@intel.com
Ira Weiny (2):
hw/cxl: Introduce cxl_device_get_timestamp() utility function
bswap: Add the ability to store to an unaligned 24 bit field
Jonathan Cameron (4):
hw/cxl: rename mailbox return code type from ret_code to CXLRetCode
hw/cxl: QMP based poison injection support
hw/cxl: Add poison injection via the mailbox.
hw/cxl: Add clear poison mailbox command support.
hw/cxl/cxl-device-utils.c | 15 ++
hw/cxl/cxl-mailbox-utils.c | 285 ++++++++++++++++++++++++++++++------
hw/mem/cxl_type3.c | 92 ++++++++++++
hw/mem/cxl_type3_stubs.c | 6 +
include/hw/cxl/cxl_device.h | 23 +++
include/qemu/bswap.h | 23 +++
qapi/cxl.json | 18 +++
7 files changed, 420 insertions(+), 42 deletions(-)
--
2.37.2
next reply other threads:[~2023-03-02 10:17 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-02 10:17 Jonathan Cameron [this message]
2023-03-02 10:17 ` [PATCH v3 1/6] hw/cxl: rename mailbox return code type from ret_code to CXLRetCode Jonathan Cameron
2023-03-02 10:17 ` [PATCH v3 2/6] hw/cxl: Introduce cxl_device_get_timestamp() utility function Jonathan Cameron
2023-03-02 10:17 ` [PATCH v3 3/6] bswap: Add the ability to store to an unaligned 24 bit field Jonathan Cameron
2023-03-02 10:17 ` [PATCH v3 4/6] hw/cxl: QMP based poison injection support Jonathan Cameron
2023-03-03 0:50 ` Ira Weiny
2023-03-03 10:03 ` Jonathan Cameron
2023-03-02 10:17 ` [PATCH v3 5/6] hw/cxl: Add poison injection via the mailbox Jonathan Cameron
2023-03-03 0:52 ` Ira Weiny
2023-03-02 10:17 ` [PATCH v3 6/6] hw/cxl: Add clear poison mailbox command support Jonathan Cameron
2023-03-03 1:05 ` Ira Weiny
2023-03-03 9:57 ` 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=20230302101710.1652-1-Jonathan.Cameron@huawei.com \
--to=jonathan.cameron@huawei.com \
--cc=alison.schofield@intel.com \
--cc=armbru@redhat.com \
--cc=dave.jiang@intel.com \
--cc=fan.ni@samsung.com \
--cc=ira.weiny@intel.com \
--cc=linux-cxl@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=michael.roth@amd.com \
--cc=mst@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.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