qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v5 0/7] hw/cxl: Update CXL events to rev3.2 and add maintenance support for memory repair features
@ 2025-08-07 15:43 shiju.jose--- via
  2025-08-07 15:43 ` [PATCH v5 1/7] hw/cxl/events: Update for rev3.2 common event record format shiju.jose--- via
                   ` (6 more replies)
  0 siblings, 7 replies; 12+ messages in thread
From: shiju.jose--- via @ 2025-08-07 15:43 UTC (permalink / raw)
  To: qemu-devel, linux-cxl, armbru, jonathan.cameron, dave
  Cc: linuxarm, shiju.jose

From: Shiju Jose <shiju.jose@huawei.com>

Add updates for the CXL spec rev3.2 changes, in the CXL events reporting
and QMP command to inject CXL events.

Add maintenance support and emulation support for memory Post Package
Repair(PPR) and memory sparing control features.

Add support for reporting the memory sparing event record.

Changes
=======
v4 -> v5:
1. Changes for comments from Markus Armbruster (Thanks)
1.1. Fixed documentation issues in qapi/cxl.json
     https://lore.kernel.org/all/87wm7gq4fr.fsf@pond.sub.org/
     https://lore.kernel.org/all/87ms8cq3ug.fsf@pond.sub.org/
     https://lore.kernel.org/all/878qjwq3hh.fsf@pond.sub.org/
     https://lore.kernel.org/all/874iukq3d0.fsf@pond.sub.org/

1.2. https://lore.kernel.org/all/87wm7gq4fr.fsf@pond.sub.org/  
     Factor out common command arguments for 3 injection events commands
	 using struct.

2. Changes for comments from Jonathan Cameron (Thanks)
2.1 Removed tabs in qapi/cxl.json
   https://lore.kernel.org/all/20250725134535.00007e8b@huawei.com/
       
2.2. https://lore.kernel.org/all/20250725142635.000014fa@huawei.com/ 
    - Rename title of patch [6] to add Post Package Repair
    - Removed QLIST_REMOVE(ent, node); and g_free(ent);
      when find the maintenance node in the queue list.
    - Changes to store the memory geometry details when they were injected
      for the sparing record.
2.3. https://lore.kernel.org/all/20250725143120.00000eef@huawei.com/
   - Removed wrapping for 'bytes_to_copy' variable in memcpy in few places.
     
v3 -> v4:
1. Took patches applied by Jonathan to recent tag 'cxl-2025-07-03'.
2. Add few more improvements to maintenance PPR[ patch 6] and sparing
   [patch 7] feature patches.


v2 -> v3:
1. Changes for the feedback from Jonathan on v2.
   https://lore.kernel.org/all/20250619151619.1695-1-shiju.jose@huawei.com/
  1.1. https://lore.kernel.org/all/20250620150342.000055aa@huawei.com/
    - Wrap this is sub 70 and should aim for about 75 for commit descriptions.
    - hdr->ld_id = ld_id; to stw_le_p(&hdr->ld_id, ld_id); in cxl_assign_event_header()
    - Make maint_class, maint_subclass, ld_id and head_id as optional parameters in QMP for
      relevant events
    - In QMP rename maint-class to maint-op-class, maint_subclass to maint-op-subclass
      In functions, rename parameters, class to maint_op_class, subclass to maint_op_subclass etc.  
  1.2. https://lore.kernel.org/all/20250620151314.0000535c@huawei.com/ 
    - Make cme-ev-flags and cme-count for general media events as optional parameters in the QMP.
    - Make cme-ev-flags and cvme-count for DRAM event as optional parameters in the QMP.
  1.3. https://lore.kernel.org/all/20250620151655.00001cea@huawei.com/
    - Add variable declarations at start of the local scope.
  1.4. https://lore.kernel.org/all/20250620154052.00002a17@huawei.com/
    - Adjust indent style  in few places.
    - Add support for produce a Memory Sparing Event Record and enabled for
      ppr maintenance request.
    - Replaced hard coded values in few switch-cases with macro definition in few places.
    - Replaced CXL_MBOX_UNSUPPORTED with CXL_MBOX_INVALID_INPUT.
  1.5. https://lore.kernel.org/all/20250620154813.00002bbd@huawei.com/
    - Add support for memory sparing resource availability.
    - LOG_UNIMP logs for sparing maint op removed.
    - Replaced CXL_MBOX_UNSUPPORTED with CXL_MBOX_INVALID_INPUT.
               
v1 -> v2:
1. QMP CXL event injection code has updated for the following
   change in CXL spec r3.2 Table 8-55. Common Event Record Format,
   field: Event Record Flags. Length of this field has changed
   from 2 bytes to 3 bytes. 
2. Rebase to recent tag 'cxl-2025-06-10'.

Davidlohr Bueso (1):
  hw/cxl: Add support for Maintenance command and Post Package Repair
    (PPR)

Shiju Jose (6):
  hw/cxl/events: Update for rev3.2 common event record format
  hw/cxl/events: Updates for rev3.2 general media event record
  hw/cxl/events: Updates for rev3.2 DRAM event record
  hw/cxl/events: Updates for rev3.2 memory module event record
  hw/cxl/cxl-mailbox-utils: Move declaration of scrub and ECS feature
    attributes in cmd_features_set_feature()
  hw/cxl: Add emulation for memory sparing control feature

 hw/cxl/cxl-events.c         |   3 +-
 hw/cxl/cxl-mailbox-utils.c  | 569 +++++++++++++++++++++++++++++++++++-
 hw/mem/cxl_type3.c          | 332 ++++++++++++++++++++-
 hw/mem/cxl_type3_stubs.c    |  41 ++-
 include/hw/cxl/cxl_device.h | 152 +++++++++-
 include/hw/cxl/cxl_events.h |  85 +++++-
 qapi/cxl.json               | 184 ++++++++----
 7 files changed, 1280 insertions(+), 86 deletions(-)

-- 
2.43.0



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2025-08-08 14:05 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-07 15:43 [PATCH v5 0/7] hw/cxl: Update CXL events to rev3.2 and add maintenance support for memory repair features shiju.jose--- via
2025-08-07 15:43 ` [PATCH v5 1/7] hw/cxl/events: Update for rev3.2 common event record format shiju.jose--- via
2025-08-08 10:37   ` Markus Armbruster
2025-08-08 14:04     ` Shiju Jose via
2025-08-08 13:29   ` Jonathan Cameron via
2025-08-08 14:04     ` Shiju Jose via
2025-08-07 15:43 ` [PATCH v5 2/7] hw/cxl/events: Updates for rev3.2 general media event record shiju.jose--- via
2025-08-07 15:43 ` [PATCH v5 3/7] hw/cxl/events: Updates for rev3.2 DRAM " shiju.jose--- via
2025-08-07 15:43 ` [PATCH v5 4/7] hw/cxl/events: Updates for rev3.2 memory module " shiju.jose--- via
2025-08-07 15:43 ` [PATCH v5 5/7] hw/cxl/cxl-mailbox-utils: Move declaration of scrub and ECS feature attributes in cmd_features_set_feature() shiju.jose--- via
2025-08-07 15:43 ` [PATCH v5 6/7] hw/cxl: Add support for Maintenance command and Post Package Repair (PPR) shiju.jose--- via
2025-08-07 15:43 ` [PATCH v5 7/7] hw/cxl: Add emulation for memory sparing control feature shiju.jose--- via

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).