[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 18/91] hw/cxl/cxl-mailbox-utils: Add dc_event_log_size field to ou
From: |
Michael S. Tsirkin |
Subject: |
[PULL 18/91] hw/cxl/cxl-mailbox-utils: Add dc_event_log_size field to output payload of identify memory device command |
Date: |
Tue, 2 Jul 2024 10:07:51 -0400 |
From: Fan Ni <fan.ni@samsung.com>
Based on CXL spec r3.1 Table 8-127 (Identify Memory Device Output
Payload), dynamic capacity event log size should be part of
output of the Identify command.
Add dc_event_log_size to the output payload for the host to get the info.
Reviewed-by: Gregory Price <gregory.price@memverge.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Fan Ni <fan.ni@samsung.com>
Message-Id: <20240523174651.1089554-4-nifan.cxl@gmail.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
hw/cxl/cxl-mailbox-utils.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/hw/cxl/cxl-mailbox-utils.c b/hw/cxl/cxl-mailbox-utils.c
index 2a64c58e2f..626acc1d0d 100644
--- a/hw/cxl/cxl-mailbox-utils.c
+++ b/hw/cxl/cxl-mailbox-utils.c
@@ -21,6 +21,7 @@
#include "sysemu/hostmem.h"
#define CXL_CAPACITY_MULTIPLIER (256 * MiB)
+#define CXL_DC_EVENT_LOG_SIZE 8
/*
* How to add a new command, example. The command set FOO, with cmd BAR.
@@ -780,8 +781,9 @@ static CXLRetCode cmd_identify_memory_device(const struct
cxl_cmd *cmd,
uint16_t inject_poison_limit;
uint8_t poison_caps;
uint8_t qos_telemetry_caps;
+ uint16_t dc_event_log_size;
} QEMU_PACKED *id;
- QEMU_BUILD_BUG_ON(sizeof(*id) != 0x43);
+ QEMU_BUILD_BUG_ON(sizeof(*id) != 0x45);
CXLType3Dev *ct3d = CXL_TYPE3(cci->d);
CXLType3Class *cvc = CXL_TYPE3_GET_CLASS(ct3d);
CXLDeviceState *cxl_dstate = &ct3d->cxl_dstate;
@@ -807,6 +809,7 @@ static CXLRetCode cmd_identify_memory_device(const struct
cxl_cmd *cmd,
st24_le_p(id->poison_list_max_mer, 256);
/* No limit - so limited by main poison record limit */
stw_le_p(&id->inject_poison_limit, 0);
+ stw_le_p(&id->dc_event_log_size, CXL_DC_EVENT_LOG_SIZE);
*len_out = sizeof(*id);
return CXL_MBOX_SUCCESS;
--
MST
- [PULL 07/91] virtio-ccw: Handle extra notification data, (continued)
- [PULL 07/91] virtio-ccw: Handle extra notification data, Michael S. Tsirkin, 2024/07/02
- [PULL 10/91] vhost-vsock: add VIRTIO_F_RING_PACKED to feature_bits, Michael S. Tsirkin, 2024/07/02
- [PULL 08/91] vhost/vhost-user: Add VIRTIO_F_NOTIFICATION_DATA to vhost feature bits, Michael S. Tsirkin, 2024/07/02
- [PULL 11/91] hw/virtio: Fix obtain the buffer id from the last descriptor, Michael S. Tsirkin, 2024/07/02
- [PULL 13/91] vhost-user-gpu: fix import of DMABUF, Michael S. Tsirkin, 2024/07/02
- [PULL 14/91] Revert "vhost-user: fix lost reconnect", Michael S. Tsirkin, 2024/07/02
- [PULL 12/91] virtio-pci: only reset pm state during resetting, Michael S. Tsirkin, 2024/07/02
- [PULL 09/91] Fix vhost user assertion when sending more than one fd, Michael S. Tsirkin, 2024/07/02
- [PULL 15/91] vhost-user: fix lost reconnect again, Michael S. Tsirkin, 2024/07/02
- [PULL 16/91] hw/cxl/mailbox: change CCI cmd set structure to be a member, not a reference, Michael S. Tsirkin, 2024/07/02
- [PULL 18/91] hw/cxl/cxl-mailbox-utils: Add dc_event_log_size field to output payload of identify memory device command,
Michael S. Tsirkin <=
- [PULL 17/91] hw/cxl/mailbox: interface to add CCI commands to an existing CCI, Michael S. Tsirkin, 2024/07/02
- [PULL 19/91] hw/cxl/cxl-mailbox-utils: Add dynamic capacity region representative and mailbox command support, Michael S. Tsirkin, 2024/07/02
- [PULL 20/91] include/hw/cxl/cxl_device: Rename mem_size as static_mem_size for type3 memory devices, Michael S. Tsirkin, 2024/07/02
- [PULL 22/91] hw/mem/cxl-type3: Refactor ct3_build_cdat_entries_for_mr to take mr size instead of mr as argument, Michael S. Tsirkin, 2024/07/02
- [PULL 21/91] hw/mem/cxl_type3: Add support to create DC regions to type3 memory devices, Michael S. Tsirkin, 2024/07/02
- [PULL 23/91] hw/mem/cxl_type3: Add host backend and address space handling for DC regions, Michael S. Tsirkin, 2024/07/02
- [PULL 25/91] hw/cxl/cxl-mailbox-utils: Add mailbox commands to support add/release dynamic capacity response, Michael S. Tsirkin, 2024/07/02
- [PULL 28/91] hw/cxl/cxl-mailbox-utils: Add superset extent release mailbox support, Michael S. Tsirkin, 2024/07/02
- [PULL 27/91] hw/mem/cxl_type3: Add DPA range validation for accesses to DC regions, Michael S. Tsirkin, 2024/07/02
- [PULL 24/91] hw/mem/cxl_type3: Add DC extent list representative and get DC extent list mailbox support, Michael S. Tsirkin, 2024/07/02