[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 3/9] include/hw/cxl/cxl_device: Rename mem_size as static_
From: |
Jonathan Cameron |
Subject: |
Re: [PATCH v3 3/9] include/hw/cxl/cxl_device: Rename mem_size as static_mem_size for type3 memory devices |
Date: |
Wed, 24 Jan 2024 14:54:37 +0000 |
On Tue, 7 Nov 2023 10:07:07 -0800
nifan.cxl@gmail.com wrote:
> From: Fan Ni <fan.ni@samsung.com>
>
> Rename mem_size as static_mem_size for type3 memdev to cover static RAM and
> pmem capacity, preparing for the introduction of dynamic capacity to support
> dynamic capacity devices.
>
> Signed-off-by: Fan Ni <fan.ni@samsung.com>
Hi Fan,
One trivial comment inline.
> ---
> hw/cxl/cxl-mailbox-utils.c | 4 ++--
> hw/mem/cxl_type3.c | 8 ++++----
> include/hw/cxl/cxl_device.h | 2 +-
> 3 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/hw/cxl/cxl-mailbox-utils.c b/hw/cxl/cxl-mailbox-utils.c
> index f80dd6474f..707fd9fe7f 100644
> --- a/hw/cxl/cxl-mailbox-utils.c
> +++ b/hw/cxl/cxl-mailbox-utils.c
> @@ -774,7 +774,7 @@ static CXLRetCode cmd_identify_memory_device(const struct
> cxl_cmd *cmd,
> snprintf(id->fw_revision, 0x10, "BWFW VERSION %02d", 0);
>
> stq_le_p(&id->total_capacity,
> - cxl_dstate->mem_size / CXL_CAPACITY_MULTIPLIER);
> + cxl_dstate->static_mem_size / CXL_CAPACITY_MULTIPLIER);
Indent ended up one space short.
> stq_le_p(&id->persistent_capacity,
> cxl_dstate->pmem_size / CXL_CAPACITY_MULTIPLIER);
> stq_le_p(&id->volatile_capacity,
> @@ -1149,7 +1149,7 @@ static CXLRetCode cmd_media_clear_poison(const struct
> cxl_cmd *cmd,
> struct clear_poison_pl *in = (void *)payload_in;
>
> dpa = ldq_le_p(&in->dpa);
> - if (dpa + CXL_CACHE_LINE_SIZE > cxl_dstate->mem_size) {
> + if (dpa + CXL_CACHE_LINE_SIZE > cxl_dstate->static_mem_size) {
> return CXL_MBOX_INVALID_PA;
> }
>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH v3 3/9] include/hw/cxl/cxl_device: Rename mem_size as static_mem_size for type3 memory devices,
Jonathan Cameron <=