* [PATCH 1/1] of: unittest: pci_dt_testdrv: Fix compile error
@ 2023-08-24 16:56 Lizhi Hou
2023-08-24 22:22 ` Rob Herring
0 siblings, 1 reply; 2+ messages in thread
From: Lizhi Hou @ 2023-08-24 16:56 UTC (permalink / raw)
To: robh+dt; +Cc: Lizhi Hou, devicetree, sonal.santan
pci_dt_testdrv depends on both PCI_DYNAMIC_OF_NODES and OF_OVERLAY.
Add #if check for OF_OVERLAY.
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202308241954.oRNfVqmB-lkp@intel.com/
Fixes: 26409dd04589 ("of: unittest: Add pci_dt_testdrv pci driver")
Signed-off-by: Lizhi Hou <lizhi.hou@amd.com>
---
drivers/of/unittest.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c
index fef46a9a5e81..beb75d3b33f8 100644
--- a/drivers/of/unittest.c
+++ b/drivers/of/unittest.c
@@ -3732,7 +3732,7 @@ static inline __init void of_unittest_overlay_high_level(void) {}
#endif
-#ifdef CONFIG_PCI_DYNAMIC_OF_NODES
+#if defined(CONFIG_PCI_DYNAMIC_OF_NODES) && defined(CONFIG_OF_OVERLAY)
static int of_unittest_pci_dev_num;
static int of_unittest_pci_child_num;
--
2.34.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] of: unittest: pci_dt_testdrv: Fix compile error
2023-08-24 16:56 [PATCH 1/1] of: unittest: pci_dt_testdrv: Fix compile error Lizhi Hou
@ 2023-08-24 22:22 ` Rob Herring
0 siblings, 0 replies; 2+ messages in thread
From: Rob Herring @ 2023-08-24 22:22 UTC (permalink / raw)
To: Lizhi Hou; +Cc: devicetree, sonal.santan
On Thu, Aug 24, 2023 at 11:56 AM Lizhi Hou <lizhi.hou@amd.com> wrote:
>
> pci_dt_testdrv depends on both PCI_DYNAMIC_OF_NODES and OF_OVERLAY.
> Add #if check for OF_OVERLAY.
Thanks for the quick fix. I just sent an alternative which reduces the
ifdefs[1].
Rob
[1] https://lore.kernel.org/all/20230824221743.1581707-1-robh@kernel.org/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-08-24 22:23 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-24 16:56 [PATCH 1/1] of: unittest: pci_dt_testdrv: Fix compile error Lizhi Hou
2023-08-24 22:22 ` Rob Herring
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).