public inbox for linux-cxl@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/3] hw/cxl: Add fixes in maintenance, PPR and event records
@ 2026-03-06 10:14 shiju.jose
  2026-03-06 10:14 ` [PATCH v2 1/3] hw/cxl: Fix handling of component ID to not assume it is a string shiju.jose
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: shiju.jose @ 2026-03-06 10:14 UTC (permalink / raw)
  To: qemu-devel, linux-cxl, mst, peter.maydell, jonathan.cameron, dave
  Cc: linuxarm, shiju.jose

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

Add few fixes in CXL maintenance, PPR and event records generation.

1. In cxl_create_mem_sparing_event_records(), replace strncpy with memcpy
to solve coverity warning (CID 1645325) to copy the entire component ID
data, which is 16 bytes data, not a string.

2. In cxl_maintenance_insert(),
 - replace strncpy with memcpy to copy full data because component ID is
   16 bytes data, not a string.
 - remove memset which is not required.

3. In cxl_perform_ppr(), remove and free the maintenance entry from QLIST
if match is found and PPR operation is performed.

4. Component ID in CXL events is 16 bytes data, not a string, but event
record generation copy 15 bytes only from the qmp "component-id" field
using strncpy. Replace strncpy with memcpy and copy the entire component
ID data.

Changes:
v1 -> v2
1. Fix for the feedback from Jonathan.
  - Modified title of patch[1] & patch[3].
  - Added fixes tags to all 3 patche's header.

Shiju Jose (3):
  hw/cxl: Fix handling of component ID to not assume it is a string
  hw/cxl: Add fixes in Post Package Repair (PPR)
  hw/cxl/events: Fix handling of component ID in event records
    generation to not assume it is a string

 hw/cxl/cxl-mailbox-utils.c |  6 ++++--
 hw/mem/cxl_type3.c         | 13 ++++---------
 2 files changed, 8 insertions(+), 11 deletions(-)

-- 
2.43.0


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

end of thread, other threads:[~2026-03-17 16:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-06 10:14 [PATCH v2 0/3] hw/cxl: Add fixes in maintenance, PPR and event records shiju.jose
2026-03-06 10:14 ` [PATCH v2 1/3] hw/cxl: Fix handling of component ID to not assume it is a string shiju.jose
2026-03-06 10:14 ` [PATCH v2 2/3] hw/cxl: Add fixes in Post Package Repair (PPR) shiju.jose
2026-03-06 10:14 ` [PATCH v2 3/3] hw/cxl/events: Fix handling of component ID in event records generation to not assume it is a string shiju.jose
2026-03-17 16:45 ` [PATCH v2 0/3] hw/cxl: Add fixes in maintenance, PPR and event records Jonathan Cameron

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox