All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Holmes-Mitra <dholmesm@google.com>
To: u-boot@lists.u-boot-project.org
Cc: "Heinrich Schuchardt" <xypron.glpk@gmx.de>,
	"Ilias Apalodimas" <ilias.apalodimas@linaro.org>,
	"Tom Rini" <trini@konsulko.com>,
	"Vincent Stehlé" <vincent.stehle@arm.com>
Subject: [PATCH 0/2] efi_loader: Emit standard ACPI/PCI device paths for PCI DM devices
Date: Thu, 03 Dec 2026 02:21:18 GMT	[thread overview]
Message-ID: <20261203022028.05-00-dholmesm@google.com> (raw)

UEFI device paths built from Driver Model PCI devices currently fall back
to U-Boot-specific VenHw() nodes instead of standard
Acpi(PNP0A03,uid)/Pci(dev,func) hardware paths.

1. Define DEVICE_PATH_SUB_TYPE_PCI and struct efi_device_path_pci per
   UEFI Specification Section 10.3.1.1, format PCI nodes in
   EFI_DEVICE_PATH_TO_TEXT_PROTOCOL, and add selftest coverage in
   lib/efi_selftest/efi_selftest_devicepath.c.
2. Teach dp_size() and dp_fill() to emit Acpi(PNP0A03,uid) for PCI root
   bridges (preferring DT linux,pci-domain with fallback to dev_seq(dev)
   so multi-domain FDTs keep matching segment IDs) and Pci(dev,func)
   nodes for devices residing on a PCI bus (including PCI bridges,
   PCI-attached NICs and MMC controllers, and default PCI controllers).

Tested:
- sandbox_defconfig: bootefi selftest 'device path' passed (0 failures),
  including the new Pci(0x1a,0x2) conversion check.
- Live QEMU arm64 (qemu_arm64_defconfig + -device e1000): `efidebug dh`
  reports `/Acpi(PNP0A03,0)/Pci(0x1,0x0)/MAC(525400123456,1)`.
- qemu_arm64_defconfig with CONFIG_PCI=n: efi_device_path.o compiles cleanly.
- Checked with scripts/checkpatch.pl --strict --u-boot (0 errors, 0 warnings).

Dan Holmes-Mitra (2):
  efi_loader: Add PCI hardware device path node and text conversion
  efi_loader: Emit ACPI/PCI device path nodes for PCI DM devices

 include/efi_api.h                          |  7 +++
 lib/efi_loader/efi_device_path.c           | 62 ++++++++++++++++++++--
 lib/efi_loader/efi_device_path_to_text.c   |  6 +++
 lib/efi_selftest/efi_selftest_devicepath.c | 33 ++++++++++++
 4 files changed, 105 insertions(+), 3 deletions(-)


base-commit: d1caced3a435607435cb7969e34499051a4ac1e6
-- 
2.56.1.911.g883d8bcb20-goog


             reply	other threads:[~2026-12-03  5:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-03  2:21 Dan Holmes-Mitra [this message]
2026-12-03  2:21 ` [PATCH 1/2] efi_loader: Add PCI hardware device path node and text conversion Dan Holmes-Mitra
2026-12-03  2:21 ` [PATCH 2/2] efi_loader: Emit ACPI/PCI device path nodes for PCI DM devices Dan Holmes-Mitra

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=20261203022028.05-00-dholmesm@google.com \
    --to=dholmesm@google.com \
    --cc=ilias.apalodimas@linaro.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.u-boot-project.org \
    --cc=vincent.stehle@arm.com \
    --cc=xypron.glpk@gmx.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.