public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Mudusuru, Giri P" <giri.p.mudusuru@intel.com>
To: "Dong, Guo" <guo.dong@intel.com>,
	"edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Cc: "Yao, Jiewen" <jiewen.yao@intel.com>,
	"Ma, Maurice" <maurice.ma@intel.com>,
	"Yarlagadda, Satya P" <satya.p.yarlagadda@intel.com>
Subject: Re: [PATCH] IntelFsp2WrapperPkg: Add a PCD to control if signaling first event.
Date: Tue, 18 Oct 2016 03:32:02 +0000	[thread overview]
Message-ID: <4666AEFED60F8E4198B42BB01DCEABDF76F16C6A@ORSMSX113.amr.corp.intel.com> (raw)
In-Reply-To: <b5771ae0f271bd40b0d4803bbc9ceeabf6eb9e86.1476744752.git.guo.dong@intel.com>

Hello Guo,
FSP wrapper and Coreboot are bootloaders consuming FSP binary. 

FSP must get called Post PCI bus enumeration to do the required silicon initialization. Why do we need a PCD to skip it?

Thanks,
-Giri

> -----Original Message-----
> From: Dong, Guo
> Sent: Monday, October 17, 2016 3:53 PM
> To: edk2-devel@lists.01.org
> Cc: Yao, Jiewen <jiewen.yao@intel.com>; Mudusuru, Giri P
> <giri.p.mudusuru@intel.com>; Dong, Guo <guo.dong@intel.com>
> Subject: [edk2] [PATCH] IntelFsp2WrapperPkg: Add a PCD to control if signaling
> first event.
> 
> PciEnumerationComplete might be signaled to FSP in Coreboot. Add a
> PCD PcdNotifyPciEnumerationComplete so FspWrapperNotifyDxe driver
> could be used in this case.
> 
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: gdong1 <guo.dong@intel.com>
> ---
>  .../FspWrapperNotifyDxe/FspWrapperNotifyDxe.c          | 18 ++++++++++--------
>  .../FspWrapperNotifyDxe/FspWrapperNotifyDxe.inf        |  3 ++-
>  IntelFsp2WrapperPkg/IntelFsp2WrapperPkg.dec            |  5 +++++
>  3 files changed, 17 insertions(+), 9 deletions(-)
> 
> diff --git a/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.c
> b/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.c
> index 0797f44..45eae4b 100644
> --- a/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.c
> +++ b/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.c
> @@ -246,14 +246,16 @@ FspWrapperNotifyDxeEntryPoint (
>      return EFI_SUCCESS;
>    }
> 
> -  ProtocolNotifyEvent = EfiCreateProtocolNotifyEvent (
> -                          &gEfiPciEnumerationCompleteProtocolGuid,
> -                          TPL_CALLBACK,
> -                          OnPciEnumerationComplete,
> -                          NULL,
> -                          &Registration
> -                          );
> -  ASSERT (ProtocolNotifyEvent != NULL);
> +  if (PcdGetBool(PcdNotifyPciEnumerationComplete)) {
> +    ProtocolNotifyEvent = EfiCreateProtocolNotifyEvent (
> +                            &gEfiPciEnumerationCompleteProtocolGuid,
> +                            TPL_CALLBACK,
> +                            OnPciEnumerationComplete,
> +                            NULL,
> +                            &Registration
> +                            );
> +    ASSERT (ProtocolNotifyEvent != NULL);
> +  }
> 
>    Status = EfiCreateEventReadyToBootEx (
>               TPL_CALLBACK,
> diff --git
> a/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.inf
> b/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.inf
> index f851f68..f28356d 100644
> --- a/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.inf
> +++ b/IntelFsp2WrapperPkg/FspWrapperNotifyDxe/FspWrapperNotifyDxe.inf
> @@ -61,7 +61,8 @@
>    gFspHobGuid                                       ## CONSUMES ## HOB
> 
>  [Pcd]
> -  gIntelFsp2WrapperTokenSpaceGuid.PcdFspsBaseAddress  ## CONSUMES
> +  gIntelFsp2WrapperTokenSpaceGuid.PcdFspsBaseAddress               ##
> CONSUMES
> +  gIntelFsp2WrapperTokenSpaceGuid.PcdNotifyPciEnumerationComplete  ##
> CONSUMES
> 
>  [Depex]
>    TRUE
> diff --git a/IntelFsp2WrapperPkg/IntelFsp2WrapperPkg.dec
> b/IntelFsp2WrapperPkg/IntelFsp2WrapperPkg.dec
> index d9d2d80..52ed9d8 100644
> --- a/IntelFsp2WrapperPkg/IntelFsp2WrapperPkg.dec
> +++ b/IntelFsp2WrapperPkg/IntelFsp2WrapperPkg.dec
> @@ -74,6 +74,11 @@
>    ## This is the base address of FSP-T/M/S
> 
> gIntelFsp2WrapperTokenSpaceGuid.PcdFsptBaseAddress|0x00000000|UINT32|
> 0x00000300
> 
> gIntelFsp2WrapperTokenSpaceGuid.PcdFspmBaseAddress|0x00000000|UINT32
> |0x00000301
> +  ## Indicates if the FSP wrapper will notify FSP
> PciEnumerationComplete.<BR><BR>
> +  #   TRUE  - FSP wrapper will notify PciEnumerationComplete to FSP.<BR>
> +  #   FALSE - FSP wrapper will NOT notify PciEnumerationComplete to FSP.<BR>
> +  # @Prompt Notify FSP PciEnumerationComplete.
> +
> gIntelFsp2WrapperTokenSpaceGuid.PcdNotifyPciEnumerationComplete|TRUE|
> BOOLEAN|0x40000009
> 
>  [PcdsFixedAtBuild, PcdsPatchableInModule,PcdsDynamic,PcdsDynamicEx]
> 
> gIntelFsp2WrapperTokenSpaceGuid.PcdFspsBaseAddress|0x00000000|UINT32|
> 0x00001001
> --
> 2.7.0.windows.1



       reply	other threads:[~2016-10-18  3:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <b5771ae0f271bd40b0d4803bbc9ceeabf6eb9e86.1476744752.git.guo.dong@intel.com>
2016-10-18  3:32 ` Mudusuru, Giri P [this message]
     [not found]   ` <0DE6ECBAEEB99B4DA9564FF580F3580A0D2C340A@fmsmsx120.amr.corp.intel.com>
2016-10-18  4:09     ` [PATCH] IntelFsp2WrapperPkg: Add a PCD to control if signaling first event Yao, Jiewen
     [not found]       ` <0DE6ECBAEEB99B4DA9564FF580F3580A0D2C3452@fmsmsx120.amr.corp.intel.com>
2016-10-21 23:23         ` Yao, Jiewen
2016-10-21 23:51           ` Dong, Guo
2016-10-22  5:14             ` Yao, Jiewen
2016-10-23 13:53               ` Mudusuru, Giri P
2016-10-24 17:08                 ` Dong, Guo

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=4666AEFED60F8E4198B42BB01DCEABDF76F16C6A@ORSMSX113.amr.corp.intel.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