public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "gaoliming" <gaoliming@byosoft.com.cn>
To: <devel@edk2.groups.io>, <kraxel@redhat.com>, <ncoleon@amazon.com>
Cc: <atugup@amazon.com>, "'Alexander Graf'" <graf@amazon.de>
Subject: 回复: [edk2-devel] [PATCH v3 7/8] MdeModulePkg/Pci MdePkg: Create service to retrieve PCI base addresses
Date: Sat, 29 Jan 2022 09:44:24 +0800	[thread overview]
Message-ID: <000301d814b1$bed35f00$3c7a1d00$@byosoft.com.cn> (raw)
In-Reply-To: <20220128105240.2uofqayzqo5mfbto@sirius.home.kraxel.org>



> -----邮件原件-----
> 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Gerd
> Hoffmann
> 发送时间: 2022年1月28日 18:53
> 收件人: devel@edk2.groups.io; ncoleon@amazon.com
> 抄送: atugup@amazon.com; Alexander Graf <graf@amazon.de>
> 主题: Re: [edk2-devel] [PATCH v3 7/8] MdeModulePkg/Pci MdePkg: Create
> service to retrieve PCI base addresses
> 
>   Hi,
> 
> > --- a/MdePkg/Include/Protocol/PciHostBridgeResourceAllocation.h
> > +++ b/MdePkg/Include/Protocol/PciHostBridgeResourceAllocation.h
> > @@ -367,6 +367,33 @@ EFI_STATUS
> >    IN EFI_PCI_CONTROLLER_RESOURCE_ALLOCATION_PHASE
> Phase
> >    );
> >
> > +/**
> > +  Retrieves the base addresses of ost bridge resources.
> > +
> > +  @param This              The pointer to the
> EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL instance.
> > +  @param RootBridgeHandle  The PCI root bridge handle.
> > +  @param IoBase            The pointer to PIO aperture base
> address.
> > +  @param Mem32Base         The pointer to 32-bit aperture base
> address.
> > +  @param PMem32Base        The pointer to 32-bit prefetchable
> aperture base address.
> > +  @param Mem64Base         The pointer to 64-bit aperture base
> address.
> > +  @param PMem64Base        The pointer to 64-bit prefetchable
> aperture base address.
> > +
> > +  @retval EFI_SUCCESS      Succeed.
> > +  @retval EFI_NOT_FOUND    Root bridge was not found.
> > +
> > +**/
> > +typedef
> > +EFI_STATUS
> > +(EFIAPI
> *EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL_GET_RESOU
> RCES_BASES)(
> > +  IN EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL *This,
> > +  IN EFI_HANDLE
> RootBridgeHandle,
> > +  OUT UINT64
> *IoBase,
> > +  OUT UINT64
> *Mem32Base,
> > +  OUT UINT64
> *PMem32Base,
> > +  OUT UINT64
> *Mem64Base,
> > +  OUT UINT64
> *PMem64Base
> > +  );
> > +
> >  ///
> >  /// Provides the basic interfaces to abstract a PCI host bridge
resource
> allocation.
> >  ///
> > @@ -415,6 +442,12 @@ struct
> _EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL {
> >    /// before enumeration.
> >    ///
> >
> EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL_PREPROCESS_
> CONTROLLER     PreprocessController;
> > +
> > +  ///
> > +  /// Returns the aligned base addresses of the different resource
> windows
> > +  /// of the host bridge. Intended for use before resources are
submitted.
> > +  ///
> > +
> EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL_GET_RESOUR
> CES_BASES       GetResourcesBases;
> >  };
> 
> Hmm, not sure the protocol can be changed like that without risking
> breakage, the uefi protocols are the binary interface between uefi
> modules ...
> 

This protocol is defined in PI spec. Its change needs to get UEFI org
approve.
If this service is required, one new protocol can be added into MdeModulePkg
as 
edk2 implementation protocol. 

Thanks
Liming
> take care,
>   Gerd
> 
> 
> 
> 
> 




  reply	other threads:[~2022-01-29  1:44 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-25 14:30 [PATCH v3 0/8] Handling of multiple PCI host bridges specified Ojeda Leon, Nicolas
2022-01-25 14:30 ` [PATCH v3 1/8] OvmfPkg/Library: Create base HardwareInfoLib for PCI Host Bridges Ojeda Leon, Nicolas
2022-01-28 10:36   ` Gerd Hoffmann
2022-01-25 14:30 ` [PATCH v3 2/8] Ovmf/HardwareInfoLib: Create Pei lib to parse directly from fw-cfg Ojeda Leon, Nicolas
2022-01-28 10:36   ` Gerd Hoffmann
2022-01-25 14:30 ` [PATCH v3 3/8] Ovmf/HardwareInfoLib: Add Dxe lib to dynamically parse heterogenous data Ojeda Leon, Nicolas
2022-01-28 10:36   ` Gerd Hoffmann
2022-01-25 14:30 ` [PATCH v3 4/8] Ovmf/PlatformPei: Use host-provided GPA end if available Ojeda Leon, Nicolas
2022-01-28 10:37   ` Gerd Hoffmann
2022-01-25 14:35 ` [PATCH v3 5/8] OvmfPkg/PciHostBridgeUtilityLib: Initialize RootBridges apertures with spec Ojeda Leon, Nicolas
2022-01-28 10:41   ` [edk2-devel] " Gerd Hoffmann
2022-01-25 14:36 ` [PATCH v3 6/8] MdeModulePkg, OvmfPkg: Add Pcd token for PCI pre-populated BARs Ojeda Leon, Nicolas
2022-01-25 14:37 ` [PATCH v3 7/8] MdeModulePkg/Pci MdePkg: Create service to retrieve PCI base addresses Ojeda Leon, Nicolas
2022-01-28 10:52   ` [edk2-devel] " Gerd Hoffmann
2022-01-29  1:44     ` gaoliming [this message]
2022-01-25 14:38 ` [PATCH v3 8/8] MdeModulePkg/PciBusDxe: Handling of pre-populated PCI BARs Ojeda Leon, Nicolas

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='000301d814b1$bed35f00$3c7a1d00$@byosoft.com.cn' \
    --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