public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: Laszlo Ersek <lersek@redhat.com>
To: Evgeny Yakovlev <insoreiges@gmail.com>, edk2-devel@lists.01.org
Subject: Re: How to look up ACPI device node from DXE driver
Date: Thu, 18 May 2017 12:59:00 +0200	[thread overview]
Message-ID: <0a8ddf35-cafa-1591-5d5b-5251227f2da1@redhat.com> (raw)
In-Reply-To: <CAM0BJjQATdmhVfO9vOwTiNjvOGPLOUJuvSriqDc+FG1-A4dZaA@mail.gmail.com>

On 05/16/17 14:55, Evgeny Yakovlev wrote:
> I am writing a DXE driver for a paravirtualized HyperV storage device for
> OvmfPkg. Host hypervisor exposes the presence of this device through ACPI
> device node in DSDT. Specific AML path itself may be different from host to
> host but device UID is always a string: "VMBus".
> 
> I was hoping to be able to walk DSDT table in my DXE driver to locate this
> device node and start publishing necessary protocols, but I am having
> trouble figuring out how to do this, i.e. are there any support libraries
> or protocols to traverse ACPI tables or how do I have to do that manually.
> Will be glad for any advice, thanks.

This is one of the goals that EFI_ACPI_SDT_PROTOCOL serves.

The protocol is specified in Volume 5 of the PI spec.

In edk2, the protocol is produced by

  MdeModulePkg/Universal/Acpi/AcpiTableDxe

when the

  gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol

Feature PCD is set to TRUE.

I think there are a handful (?) of protocol consumers in edk2 as well,
for example in

  QuarkPlatformPkg/Acpi/Dxe/AcpiPlatform/

Thanks,
Laszlo


  reply	other threads:[~2017-05-18 10:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-16 12:55 How to look up ACPI device node from DXE driver Evgeny Yakovlev
2017-05-18 10:59 ` Laszlo Ersek [this message]
2017-05-18 11:54   ` Evgeny Yakovlev

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-list 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=0a8ddf35-cafa-1591-5d5b-5251227f2da1@redhat.com \
    --to=devel@edk2.groups.io \
    /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