From: Sascha Hauer <s.hauer@pengutronix.de>
To: BAREBOX <barebox@lists.infradead.org>
Subject: [PATCH 0/4] PCI: populate PCI host controller device nodes
Date: Thu, 21 May 2026 10:36:54 +0200 [thread overview]
Message-ID: <20260521-pci-of-dynamic-v1-0-951f1878e378@pengutronix.de> (raw)
PCI devices usually don't have and don't need a representation in the
device tree, but sometimes they do. This series adds support for adding
device nodes for PCI devices to the barebox live tree similar to what
Linux does with CONFIG_PCI_DYNAMIC_OF_NODES enabled. We also fixup the
Linux device tree with the PCI device nodes. This allows PCI device
drivers to register of_fixups for PCI devices: The barebox internal
PCI device now gets a device node (from the patched barebox live tree)
and it can use this node to find the corresponding device node in the
Linux device tree (possibly added by barebox as well).
In my case I do not need a PCI device driver to add a node to the
Linux tree. What I want to archieve is that a MAC address of a PCI
device that is initialized in a board specific way is forwarded to
Linux using the mac-address property. For this case there are is no
further code needed, the only piece missing is the creation of the
PCI device nodes added with this series.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
Sascha Hauer (4):
of: fall back to parent-prefixed encoding when address translation fails
pci: fix DT node matching when reg encodes a non-zero bus number
pci: add pci_is_bridge() helper
pci: synthesize devicetree nodes for enumerated devices
drivers/of/base.c | 9 ++-
drivers/pci/Kconfig | 23 +++++++
drivers/pci/Makefile | 1 +
drivers/pci/of-dynamic.c | 173 +++++++++++++++++++++++++++++++++++++++++++++++
drivers/pci/pci.c | 12 +++-
include/linux/pci.h | 14 ++++
include/of_pci.h | 6 ++
7 files changed, 235 insertions(+), 3 deletions(-)
---
base-commit: 6bde1c5bcd518f378189c2f4b41704126713f3c4
change-id: 20260521-pci-of-dynamic-15df50ff7905
Best regards,
--
Sascha Hauer <s.hauer@pengutronix.de>
next reply other threads:[~2026-05-21 8:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-21 8:36 Sascha Hauer [this message]
2026-05-21 8:36 ` [PATCH 1/4] of: fall back to parent-prefixed encoding when address translation fails Sascha Hauer
2026-05-21 8:36 ` [PATCH 2/4] pci: fix DT node matching when reg encodes a non-zero bus number Sascha Hauer
2026-05-21 8:36 ` [PATCH 3/4] pci: add pci_is_bridge() helper Sascha Hauer
2026-05-21 16:23 ` Bjorn Helgaas
2026-05-21 19:46 ` Sascha Hauer
2026-05-21 20:53 ` Bjorn Helgaas
2026-05-21 8:36 ` [PATCH 4/4] pci: synthesize devicetree nodes for enumerated devices Sascha Hauer
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=20260521-pci-of-dynamic-v1-0-951f1878e378@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
/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