[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v7 12/12] hw/mem/cxl_type3: Allow to release extent superset
From: |
Gregory Price |
Subject: |
Re: [PATCH v7 12/12] hw/mem/cxl_type3: Allow to release extent superset in QMP interface |
Date: |
Fri, 19 Apr 2024 14:20:53 -0400 |
On Thu, Apr 18, 2024 at 04:11:03PM -0700, nifan.cxl@gmail.com wrote:
> From: Fan Ni <fan.ni@samsung.com>
>
> Before the change, the QMP interface used for add/release DC extents
> only allows to release an extent whose DPA range is contained by a single
> accepted extent in the device.
>
> With the change, we relax the constraints. As long as the DPA range of
> the extent is covered by accepted extents, we allow the release.
>
> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Signed-off-by: Fan Ni <fan.ni@samsung.com>
> ---
> hw/mem/cxl_type3.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
Reveiwed-by: Gregory Price <gregory.price@memverge.com>
> diff --git a/hw/mem/cxl_type3.c b/hw/mem/cxl_type3.c
> index a3e1a5de25..9e725647f1 100644
> --- a/hw/mem/cxl_type3.c
> +++ b/hw/mem/cxl_type3.c
> @@ -1941,7 +1941,7 @@ static void
> qmp_cxl_process_dynamic_capacity_prescriptive(const char *path,
> "cannot release extent with pending DPA range");
> return;
> }
> - if (!cxl_extents_contains_dpa_range(&dcd->dc.extents, dpa, len))
> {
> + if (!ct3_test_region_block_backed(dcd, dpa, len)) {
> error_setg(errp,
> "cannot release extent with non-existing DPA
> range");
> return;
> --
> 2.43.0
>
- Re: [PATCH v7 03/12] include/hw/cxl/cxl_device: Rename mem_size as static_mem_size for type3 memory devices, (continued)
- [PATCH v7 06/12] hw/mem/cxl_type3: Add host backend and address space handling for DC regions, nifan . cxl, 2024/04/18
- [PATCH v7 10/12] hw/mem/cxl_type3: Add DPA range validation for accesses to DC regions, nifan . cxl, 2024/04/18
- [PATCH v7 11/12] hw/cxl/cxl-mailbox-utils: Add superset extent release mailbox support, nifan . cxl, 2024/04/18
- [PATCH v7 12/12] hw/mem/cxl_type3: Allow to release extent superset in QMP interface, nifan . cxl, 2024/04/18
- Re: [PATCH v7 12/12] hw/mem/cxl_type3: Allow to release extent superset in QMP interface,
Gregory Price <=
- [PATCH v7 08/12] hw/cxl/cxl-mailbox-utils: Add mailbox commands to support add/release dynamic capacity response, nifan . cxl, 2024/04/18
- [PATCH v7 09/12] hw/cxl/events: Add qmp interfaces to add/release dynamic capacity extents, nifan . cxl, 2024/04/18