public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: Andrew Fish <afish@apple.com>
To: Mike Kinney <michael.d.kinney@intel.com>
Cc: edk2-devel <edk2-devel@lists.01.org>
Subject: Re: Can you set a PCD value DSC default per ModuleType?
Date: Thu, 01 Mar 2018 21:54:26 -0800	[thread overview]
Message-ID: <2068B7CB-24DD-4189-AF42-1E141E99E4A7@apple.com> (raw)
In-Reply-To: <E92EE9817A31E24EB0585FDF735412F5B896E52E@ORSMSX113.amr.corp.intel.com>



> On Mar 1, 2018, at 9:43 PM, Kinney, Michael D <michael.d.kinney@intel.com> wrote:
> 
> Andrew,
> 
> DSC does not support module type specific syntax.
> Just arch specific syntax.
> 
> https://edk2-docs.gitbooks.io/edk-ii-dsc-specification/content/2_dsc_overview/29_pcd_sections.html#29-pcd-sections
> 

Mike,

I understand. My question is why?

Actually I have a module with some shared code and a shared INF and I was looking at a way of conditionally including code. So I tried this. Which I notice is no longer in the tree. 

MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf:40:  X64/VirtualMemory.c  ||||gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode

The reason for conditionally including the code is the library can run in a lot of different module types, but I need to call one line that is module specific and I was trying to figure out if I could do that conditionally?  Do I really need a new Library class to abstract  one line of code? Or do I need to clone the INF. The problem is my library gets include in the DXE CORE and SMM CORE and I'm have one line of DXE CORE only magic I was trying to abstract. 

Is there a way short of a new library class for one line of code to do this? The PCD worked, but I had to use the <> override to every place the DXE Core was referenced, which is not ideal. 

Thanks,

Andrew Fish

> Mike
> 
>> -----Original Message-----
>> From: edk2-devel [mailto:edk2-devel-
>> bounces@lists.01.org] On Behalf Of Andrew Fish
>> Sent: Thursday, March 1, 2018 8:07 PM
>> To: edk2-devel <edk2-devel@lists.01.org>
>> Subject: Re: [edk2] Can you set a PCD value DSC default
>> per ModuleType?
>> 
>> Sorry for a FeatureFlag, obviously anything dynamic
>> needs to be generic.
>> 
>> Thanks,
>> 
>> Andrew Fish
>> 
>>> On Mar 1, 2018, at 8:05 PM, Andrew Fish
>> <afish@apple.com> wrote:
>>> 
>>> Can you set a PCD value DSC default per ModuleType?
>> If not why not?
>>> 
>>> Thanks,
>>> 
>>> Andrew Fish
>>> _______________________________________________
>>> edk2-devel mailing list
>>> edk2-devel@lists.01.org
>>> https://lists.01.org/mailman/listinfo/edk2-devel
>> 
>> _______________________________________________
>> edk2-devel mailing list
>> edk2-devel@lists.01.org
>> https://lists.01.org/mailman/listinfo/edk2-devel



      reply	other threads:[~2018-03-02  5:49 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-02  4:05 Can you set a PCD value DSC default per ModuleType? Andrew Fish
2018-03-02  4:07 ` Andrew Fish
2018-03-02  5:43   ` Kinney, Michael D
2018-03-02  5:54     ` Andrew Fish [this message]

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=2068B7CB-24DD-4189-AF42-1E141E99E4A7@apple.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