[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 04/10] hw/mem/cxl_type3: Add support to create DC regions
From: |
Jonathan Cameron |
Subject: |
Re: [PATCH v4 04/10] hw/mem/cxl_type3: Add support to create DC regions to type3 memory devices |
Date: |
Mon, 26 Feb 2024 17:38:26 +0000 |
On Wed, 21 Feb 2024 10:15:57 -0800
nifan.cxl@gmail.com wrote:
> From: Fan Ni <fan.ni@samsung.com>
>
> With the change, when setting up memory for type3 memory device, we can
> create DC regions.
> A property 'num-dc-regions' is added to ct3_props to allow users to pass the
> number of DC regions to create. To make it easier, other region parameters
> like region base, length, and block size are hard coded. If needed,
> these parameters can be added easily.
>
> With the change, we can create DC regions with proper kernel side
> support like below:
>
> region=$(cat /sys/bus/cxl/devices/decoder0.0/create_dc_region)
> echo $region > /sys/bus/cxl/devices/decoder0.0/create_dc_region
> echo 256 > /sys/bus/cxl/devices/$region/interleave_granularity
> echo 1 > /sys/bus/cxl/devices/$region/interleave_ways
>
> echo "dc0" >/sys/bus/cxl/devices/decoder2.0/mode
> echo 0x40000000 >/sys/bus/cxl/devices/decoder2.0/dpa_size
>
> echo 0x40000000 > /sys/bus/cxl/devices/$region/size
> echo "decoder2.0" > /sys/bus/cxl/devices/$region/target0
> echo 1 > /sys/bus/cxl/devices/$region/commit
> echo $region > /sys/bus/cxl/drivers/cxl_region/bind
>
I'd be tempted to delete the rest of this description.
> However, we cannot really read/write to the DC regions due to lack of
"However, we cannot yet read/write ..."
> 1. host backend and address space setup for DC regions;
> 2. mailbox command support for adding/releasing DC extents.
"This will be added later in the series."
>
> Signed-off-by: Fan Ni <fan.ni@samsung.com>
Without the above additions it sounds like this patch series only partly
does the job :)
A forwards reference is good, or just don't mention it.
No guarantee of code doing anything useful, beyond not crashing
at mid point of a series.
Jonathan
- [PATCH v4 00/10] Enabling DCD emulation support in Qemu, nifan . cxl, 2024/02/21
- [PATCH v4 02/10] hw/cxl/cxl-mailbox-utils: Add dynamic capacity region representative and mailbox command support, nifan . cxl, 2024/02/21
- [PATCH v4 04/10] hw/mem/cxl_type3: Add support to create DC regions to type3 memory devices, nifan . cxl, 2024/02/21
- Re: [PATCH v4 04/10] hw/mem/cxl_type3: Add support to create DC regions to type3 memory devices,
Jonathan Cameron <=
- [PATCH v4 01/10] hw/cxl/cxl-mailbox-utils: Add dc_event_log_size field to output payload of identify memory device command, nifan . cxl, 2024/02/21
- [PATCH v4 03/10] include/hw/cxl/cxl_device: Rename mem_size as static_mem_size for type3 memory devices, nifan . cxl, 2024/02/21
- [PATCH v4 05/10] hw/mem/cxl-type3: Refactor ct3_build_cdat_entries_for_mr to take mr size insead of mr as argument, nifan . cxl, 2024/02/21
- [PATCH v4 06/10] hw/mem/cxl_type3: Add host backend and address space handling for DC regions, nifan . cxl, 2024/02/21
- [PATCH v4 07/10] hw/mem/cxl_type3: Add DC extent list representative and get DC extent list mailbox support, nifan . cxl, 2024/02/21
- [PATCH v4 10/10] hw/mem/cxl_type3: Add dpa range validation for accesses to DC regions, nifan . cxl, 2024/02/21