From: Lukas Wunner <lukas@wunner.de>
To: Manivannan Sadhasivam <mani@kernel.org>
Cc: brgl@bgdev.pl, kernel test robot <lkp@intel.com>,
bhelgaas@google.com, oe-kbuild-all@lists.linux.dev,
linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
Jim Quinlan <james.quinlan@broadcom.com>,
Bjorn Helgaas <helgaas@kernel.org>
Subject: Re: [PATCH v3] PCI/pwrctrl: Move pci_pwrctrl_create_device() definition to drivers/pci/pwrctrl/
Date: Mon, 16 Jun 2025 15:16:31 +0200 [thread overview]
Message-ID: <aFAZL1GgEH9l-zj9@wunner.de> (raw)
In-Reply-To: <ji3pexgvdkfho6mnby5jumkeaxdbzom574kbiyfy4dcqumtgz2@h4nmwjvox7nl>
On Mon, Jun 16, 2025 at 06:07:48PM +0530, Manivannan Sadhasivam wrote:
> On Mon, Jun 16, 2025 at 08:21:20PM +0800, kernel test robot wrote:
> > ld: drivers/pci/probe.o: in function `pci_scan_single_device':
> > >> probe.c:(.text+0x2400): undefined reference to `pci_pwrctrl_create_device'
>
> Hmm, so we cannot have a built-in driver depend on a module...
>
> Bartosz, should we make CONFIG_PCI_PWRCTRL bool then? We can still allow the
> individual pwrctrl drivers be tristate.
I guess the alternative is to just leave it in probe.c. The function is
optimized away in the CONFIG_OF=n case because of_pci_find_child_device()
returns NULL. It's unpleasant that it lives outside of pwrctrl/core.c,
but it doesn't occupy any space in the compiled kernel at least on non-OF
(e.g. ACPI) platforms.
Thanks,
Lukas
next prev parent reply other threads:[~2025-06-16 13:16 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-16 5:32 [PATCH v3] PCI/pwrctrl: Move pci_pwrctrl_create_device() definition to drivers/pci/pwrctrl/ Manivannan Sadhasivam
2025-06-16 9:29 ` Bartosz Golaszewski
2025-06-16 12:21 ` kernel test robot
2025-06-16 12:37 ` Manivannan Sadhasivam
2025-06-16 12:52 ` Lukas Wunner
2025-06-16 13:06 ` Manivannan Sadhasivam
2025-06-16 13:16 ` Lukas Wunner [this message]
2025-06-16 13:30 ` Bartosz Golaszewski
2025-06-16 13:44 ` Manivannan Sadhasivam
2025-06-17 20:44 ` Bjorn Helgaas
2025-06-18 5:05 ` Manivannan Sadhasivam
2025-06-18 18:58 ` Jim Quinlan
2025-06-27 22:45 ` Bjorn Helgaas
2025-06-27 23:27 ` Manivannan Sadhasivam
2025-06-29 19:02 ` Bjorn Helgaas
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=aFAZL1GgEH9l-zj9@wunner.de \
--to=lukas@wunner.de \
--cc=bhelgaas@google.com \
--cc=brgl@bgdev.pl \
--cc=helgaas@kernel.org \
--cc=james.quinlan@broadcom.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lkp@intel.com \
--cc=mani@kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
/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