From: "Arnd Bergmann" <arnd@arndb.de>
To: "Siddharth Vadapalli" <s-vadapalli@ti.com>,
"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
"Manivannan Sadhasivam" <mani@kernel.org>,
"Rob Herring" <robh@kernel.org>,
bhelgaas@google.com, "Chen Wang" <unicorn_wang@outlook.com>,
"Kishon Vijay Abraham I" <kishon@kernel.org>
Cc: stable@vger.kernel.org, linux-pci@vger.kernel.org,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, srk@ti.com
Subject: Re: [PATCH] PCI: cadence: Kconfig: change PCIE_CADENCE configs from tristate to bool
Date: Fri, 14 Nov 2025 08:03:04 +0100 [thread overview]
Message-ID: <201b9ad1-3ebd-4992-acdd-925d2e357d22@app.fastmail.com> (raw)
In-Reply-To: <250d2b94d5785e70530200e00c1f0f46fde4311b.camel@ti.com>
On Fri, Nov 14, 2025, at 06:47, Siddharth Vadapalli wrote:
> On Thu, 2025-11-13 at 11:13 +0100, Arnd Bergmann wrote:
>> On Thu, Nov 13, 2025, at 10:27, Siddharth Vadapalli wrote:
> Thank you for the suggestion. I think that the following Makefile changes
> will be sufficient and Kconfig doesn't need to be modified:
>
> diff --git a/drivers/pci/controller/cadence/Makefile
> b/drivers/pci/controller/cadence/Makefile
> index 5e23f8539ecc..1a97c9b249b8 100644
> --- a/drivers/pci/controller/cadence/Makefile
> +++ b/drivers/pci/controller/cadence/Makefile
> @@ -4,4 +4,6 @@ obj-$(CONFIG_PCIE_CADENCE_HOST) += pcie-cadence-host.o
> obj-$(CONFIG_PCIE_CADENCE_EP) += pcie-cadence-ep.o
> obj-$(CONFIG_PCIE_CADENCE_PLAT) += pcie-cadence-plat.o
> obj-$(CONFIG_PCI_J721E) += pci-j721e.o
> +pci_j721e-y := pci-j721e.o pcie-cadence.o
> obj-$(CONFIG_PCIE_SG2042_HOST) += pcie-sg2042.o
> +pci_sg2042_host-y := pci-sg2042.o pcie-cadence.o
>
> If either of PCI_J721E or SG2042_HOST is selected as a built-in module,
> then pcie-cadence-host.c, pcie-cadence-ep.c and pcie-cadence.c drivers will
> be built-in. If both PCI_J721E and SG2042_HOST are selected as loadable
> modules, only then the library drivers will be enabled as loadable modules.
>
> Please let me know what you think.
I don't think that the version above does what you want,
this would build the pcie-cadence.o file into three separate
modules and break in additional ways if a subset of them are
built-in.
I would still suggest combining pcie-cadence{,-ep,-host}.o into
one module that is used by the other drivers, as that would address
the build failure you are observing.
An alternative would be to change the pcie-j721e.c file to only
reference the host portion if host support is enabled for this
driver.
Arnd
next prev parent reply other threads:[~2025-11-14 7:03 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-13 9:27 [PATCH] PCI: cadence: Kconfig: change PCIE_CADENCE configs from tristate to bool Siddharth Vadapalli
2025-11-13 10:13 ` Arnd Bergmann
2025-11-14 5:47 ` Siddharth Vadapalli
2025-11-14 7:03 ` Arnd Bergmann [this message]
2025-11-17 6:05 ` Siddharth Vadapalli
2025-11-17 9:06 ` Arnd Bergmann
2025-11-17 9:23 ` Siddharth Vadapalli
2025-11-17 9:28 ` Manivannan Sadhasivam
2025-11-17 9:42 ` Arnd Bergmann
2025-11-13 10:38 ` Hans Zhang
2025-11-13 10:43 ` Siddharth Vadapalli
2025-11-13 10:51 ` Hans Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201b9ad1-3ebd-4992-acdd-925d2e357d22@app.fastmail.com \
--to=arnd@arndb.de \
--cc=bhelgaas@google.com \
--cc=kishon@kernel.org \
--cc=kwilczynski@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=mani@kernel.org \
--cc=robh@kernel.org \
--cc=s-vadapalli@ti.com \
--cc=srk@ti.com \
--cc=stable@vger.kernel.org \
--cc=unicorn_wang@outlook.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox