[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <bffb1a61-bc47-cc60-6d1c-70f57e749e36@amd.com>
Date: Wed, 11 Dec 2024 09:38:04 +0000
From: Alejandro Lucero Palau <alucerop@....com>
To: Edward Cree <ecree.xilinx@...il.com>, alejandro.lucero-palau@....com,
linux-cxl@...r.kernel.org, netdev@...r.kernel.org, dan.j.williams@...el.com,
martin.habets@...inx.com, edward.cree@....com, davem@...emloft.net,
kuba@...nel.org, pabeni@...hat.com, edumazet@...gle.com, dave.jiang@...el.com
Subject: Re: [PATCH v7 28/28] sfc: support pio mapping based on cxl
On 12/11/24 02:39, Edward Cree wrote:
> On 09/12/2024 18:54, alejandro.lucero-palau@....com wrote:
>> From: Alejandro Lucero <alucerop@....com>
>>
>> With a device supporting CXL and successfully initialised, use the cxl
>> region to map the memory range and use this mapping for PIO buffers.
>>
>> Signed-off-by: Alejandro Lucero <alucerop@....com>
> Acked-by: Edward Cree <ecree.xilinx@...il.com>
>
>> @@ -1263,8 +1281,25 @@ static int efx_ef10_dimension_resources(struct efx_nic *efx)
>> iounmap(efx->membase);
>> efx->membase = membase;
>>
>> - /* Set up the WC mapping if needed */
>> - if (wc_mem_map_size) {
>> + if (!wc_mem_map_size)
>> + goto out;
> Maybe this label ought to be called something else; it's not really an
> 'early exit', it's a 'skip over mapping and linking PIO', which just
> _happens_ to be almost the last thing in the function.
I do not know if I follow your point here. This was added following
Martin's previous review for keeping the debugging when PIO is not needed.
It is formally skipping now because the change what I think is good for
keeping indentation simpler with the additional conditional added.
Anyway, I can change the label to something like "out_through_debug
"which adds, IMO, unnecessary name complexity. Just using "debug" could
give the wrong idea ...
Any naming suggestion?
>> @@ -24,9 +24,10 @@ int efx_cxl_init(struct efx_probe_data *probe_data)
>> DECLARE_BITMAP(expected, CXL_MAX_CAPS);
>> DECLARE_BITMAP(found, CXL_MAX_CAPS);
>> struct pci_dev *pci_dev;
>> + resource_size_t max;
>> struct efx_cxl *cxl;
>> struct resource res;
>> - resource_size_t max;
> Why does 'max' have to move? Weird churn.
A previous version (not sure if an official one) had two resource_size_t
variables defined, and I moved it there for preserving the reverse
christmas tree, and when removed one it did not look bad.
I will remove the move.
Thanks!
Powered by blists - more mailing lists