Re: [edk2] Edk2 FAQ - INF SMM dependency

Subject: Re: [edk2] Edk2 FAQ - INF SMM dependency

From: Andrew Fish <afish@apple.com>

To: edk2-devel@lists.sourceforge.net

Date: 2012-07-17 17:49:04

I think what you are asking is how to create an EFI_SECTION_SMM_DEPEX in the FV image for your module? 

The DXE dispatcher uses the EFI_SECTION_DXE_DEPEX for dispatch, while SMM used EFI_SECTION_SMM_DEPEX. The Smst name space is totally independent in regards to the DXE/EFI protocol database. 

So I would imagine if your driver is of type DXE_SMM_DRIVER and you have a [Depex] in your INF that an EFI_SECTION_SMM_DEPEX should be created. If you are not using that driver type then I think you need to use <SMM_DEPEX> sub-section tag. 

I've not tried this, and it is not totally clear from the documentation, but I think it should look like:

[Depex]
  <SMM_DEPEX>
    gSmmProtocolToDependOn

 <DXE_DEPEX>
   gDxeProtocolToDependOn

You should be able to use the VolInfo tool to dump out the FV and see what type of depex sections get created. 

Andrew Fish





On Jul 17, 2012, at 2:03 AM, Naresh Kollu. wrote:

Hi,
 
If same protocol guid is installed in both DXE(using pbs->InstallProtocol()) and SMM(using Smst->InstallProtocol()), when we try to add the same guid dependency in other SMM driver, the dependency is evaluated with DXE instance not SMM instance. Because of this, the dependent SMM driver is getting dispatched before the SMM driver which produces the the protocol GUID.
 
Is there any other way by which we can refer to SMM instance for the same GUID ?
 
I think this should be supported by EDKII INF component but do not know exactly how to use this. If EDKII INF supports, can you please give an example ?
 
Please give your suggestions on it.
 
Thanks,
Naresh
 
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel