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-next>] [day] [month] [year] [list]
Message-Id: <20250310135119.4168933-1-arnd@kernel.org>
Date: Mon, 10 Mar 2025 14:51:15 +0100
From: Arnd Bergmann <arnd@...nel.org>
To: Davidlohr Bueso <dave@...olabs.net>,
	Jonathan Cameron <jonathan.cameron@...wei.com>,
	Dave Jiang <dave.jiang@...el.com>,
	Alison Schofield <alison.schofield@...el.com>,
	Vishal Verma <vishal.l.verma@...el.com>,
	Ira Weiny <ira.weiny@...el.com>,
	Dan Williams <dan.j.williams@...el.com>,
	Li Ming <ming.li@...omail.com>,
	Jason Gunthorpe <jgg@...pe.ca>
Cc: Arnd Bergmann <arnd@...db.de>,
	Robert Richter <rrichter@....com>,
	"Mike Rapoport (Microsoft)" <rppt@...nel.org>,
	Masahiro Yamada <masahiroy@...nel.org>,
	linux-cxl@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: [PATCH] cxl: fix FWCTL dependency

From: Arnd Bergmann <arnd@...db.de>

The 'FWCTL' subsystem is selected by CXL_FEATURES, which is a 'bool' symbol
with a dependency on CXL_PCI, but referenced by the cxl_core.ko.
When cxl_core is built-in, but the cxl_pci.ko driver is a loadable mdoule,
this results in a link failure:

ld.lld-21: error: undefined symbol: _fwctl_alloc_device
>>> referenced by features.c:695 (/home/arnd/arm-soc/drivers/cxl/core/features.c:695)
ld.lld-21: error: undefined symbol: fwctl_register
>>> referenced by features.c:699 (/home/arnd/arm-soc/drivers/cxl/core/features.c:699)
ld.lld-21: error: undefined symbol: fwctl_unregister
>>> referenced by features.c:676 (/home/arnd/arm-soc/drivers/cxl/core/features.c:676)

Move the 'select' into the symbol that controls the core module instead.

Fixes: a53a6004e7a5 ("cxl: Add FWCTL support to CXL")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
 drivers/cxl/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/cxl/Kconfig b/drivers/cxl/Kconfig
index ed49e7e7e5bc..cf1ba673b8c2 100644
--- a/drivers/cxl/Kconfig
+++ b/drivers/cxl/Kconfig
@@ -7,6 +7,7 @@ menuconfig CXL_BUS
 	select PCI_DOE
 	select FIRMWARE_TABLE
 	select NUMA_KEEP_MEMINFO if NUMA_MEMBLKS
+	select FWCTL if CXL_FEATURES
 	help
 	  CXL is a bus that is electrically compatible with PCI Express, but
 	  layers three protocols on that signalling (CXL.io, CXL.cache, and
@@ -105,7 +106,6 @@ config CXL_MEM
 config CXL_FEATURES
 	bool "CXL: Features"
 	depends on CXL_PCI
-	select FWCTL
 	help
 	  Enable support for CXL Features. A CXL device that includes a mailbox
 	  supports commands that allows listing, getting, and setting of
-- 
2.39.5


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ