lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <90e9e04d-0df8-4e91-aacd-51e05df36e97@amd.com>
Date: Thu, 8 May 2025 18:17:15 +0100
From: Alejandro Lucero Palau <alucerop@....com>
To: Alison Schofield <alison.schofield@...el.com>
Cc: alejandro.lucero-palau@....com, linux-cxl@...r.kernel.org,
 netdev@...r.kernel.org, dan.j.williams@...el.com, edward.cree@....com,
 davem@...emloft.net, kuba@...nel.org, pabeni@...hat.com,
 edumazet@...gle.com, dave.jiang@...el.com,
 Jonathan Cameron <Jonathan.Cameron@...wei.com>
Subject: Re: [PATCH v14 02/22] sfc: add cxl support


On 5/8/25 18:12, Alison Schofield wrote:
> On Thu, May 08, 2025 at 01:41:15PM +0100, Alejandro Lucero Palau wrote:
>> On 5/8/25 01:33, Alison Schofield wrote:
>>> On Thu, Apr 17, 2025 at 10:29:05PM +0100, alejandro.lucero-palau@....com wrote:
>>>> From: Alejandro Lucero <alucerop@....com>
>>>>
>>>> Add CXL initialization based on new CXL API for accel drivers and make
>>>> it dependent on kernel CXL configuration.
>>>>
>>>> Signed-off-by: Alejandro Lucero <alucerop@....com>
>>>> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@...wei.com>
>>>> ---
>>>>    drivers/net/ethernet/sfc/Kconfig      |  9 +++++
>>>>    drivers/net/ethernet/sfc/Makefile     |  1 +
>>>>    drivers/net/ethernet/sfc/efx.c        | 15 +++++++-
>>>>    drivers/net/ethernet/sfc/efx_cxl.c    | 55 +++++++++++++++++++++++++++
>>>>    drivers/net/ethernet/sfc/efx_cxl.h    | 40 +++++++++++++++++++
>>>>    drivers/net/ethernet/sfc/net_driver.h | 10 +++++
>>>>    6 files changed, 129 insertions(+), 1 deletion(-)
>>>>    create mode 100644 drivers/net/ethernet/sfc/efx_cxl.c
>>>>    create mode 100644 drivers/net/ethernet/sfc/efx_cxl.h
>>>>
>>>> diff --git a/drivers/net/ethernet/sfc/Kconfig b/drivers/net/ethernet/sfc/Kconfig
>>>> index c4c43434f314..979f2801e2a8 100644
>>>> --- a/drivers/net/ethernet/sfc/Kconfig
>>>> +++ b/drivers/net/ethernet/sfc/Kconfig
>>>> @@ -66,6 +66,15 @@ config SFC_MCDI_LOGGING
>>>>    	  Driver-Interface) commands and responses, allowing debugging of
>>>>    	  driver/firmware interaction.  The tracing is actually enabled by
>>>>    	  a sysfs file 'mcdi_logging' under the PCI device.
>>>> +config SFC_CXL
>>>> +	bool "Solarflare SFC9100-family CXL support"
>>>> +	depends on SFC && CXL_BUS >= SFC
>>>> +	default SFC
>>>> +	help
>>>> +	  This enables SFC CXL support if the kernel is configuring CXL for
>>>> +	  using CTPIO with CXL.mem. The SFC device with CXL support and
>>>> +	  with a CXL-aware firmware can be used for minimizing latencies
>>>> +	  when sending through CTPIO.
>>> SFC is a tristate, and this new bool SFC_CXL defaults to it.
>>> default y seems more obvious and follows convention in this Kconfig
>>> file.
>>>
>>> CXL_BUS >= SFC tripped me up in my testing where I had CXL_BUS M
>>> and SFC Y. Why is that not allowable?
>>>
>>>
>> Not sure what you mean here. This means that if SFC can only be a module if
>> CXL_BUS is a module and you want CXL with SFC.
>>
>> You can have SFC as built-in in that case but without CXL support.
> OK - get the desired constraint.
>
> Why use >= with the tristates and why default to the tristate instead of
> 'y' - like this:
>
> 	depends on CXL_BUS
> 	depends on (SFC = m) || (SFC = y && CXL_BUS = y)
> 	default y


It was suggested by Dan and the driver maintainers happy enough.



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ