Commit Graph

12 Commits

Author SHA1 Message Date
Michael D Kinney b26f0cf9ee OvmfPkg: Replace BSD License with BSD+Patent License
https://bugzilla.tianocore.org/show_bug.cgi?id=1373

Replace BSD 2-Clause License with BSD+Patent License.  This change is
based on the following emails:

  https://lists.01.org/pipermail/edk2-devel/2019-February/036260.html
  https://lists.01.org/pipermail/edk2-devel/2018-October/030385.html

RFCs with detailed process for the license change:

  V3: https://lists.01.org/pipermail/edk2-devel/2019-March/038116.html
  V2: https://lists.01.org/pipermail/edk2-devel/2019-March/037669.html
  V1: https://lists.01.org/pipermail/edk2-devel/2019-March/037500.html

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
2019-04-09 10:58:19 -07:00
chenc2 dbf9cc87cb OvmfPkg: Removing ipf which is no longer supported from edk2.
Removing rules for Ipf sources file:
* Remove the source file which path with "ipf" and also listed in
  [Sources.IPF] section of INF file.
* Remove the source file which listed in [Components.IPF] section
  of DSC file and not listed in any other [Components] section.
* Remove the embedded Ipf code for MDE_CPU_IPF.

Removing rules for Inf file:
* Remove IPF from VALID_ARCHITECTURES comments.
* Remove DXE_SAL_DRIVER from LIBRARY_CLASS in [Defines] section.
* Remove the INF which only listed in [Components.IPF] section in DSC.
* Remove statements from [BuildOptions] that provide IPF specific flags.
* Remove any IPF sepcific sections.

Removing rules for Dec file:
* Remove [Includes.IPF] section from Dec.

Removing rules for Dsc file:
* Remove IPF from SUPPORTED_ARCHITECTURES in [Defines] section of DSC.
* Remove any IPF specific sections.
* Remove statements from [BuildOptions] that provide IPF specific flags.

Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Chen A Chen <chen.a.chen@intel.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
2018-06-29 16:19:47 +08:00
Laszlo Ersek c5d917158d OvmfPkg/EmuVariableFvbRuntimeDxe: stop using PcdVariableStoreSize
In commit 62f43f7c19, we set PcdVariableStoreSize to the same value as
PcdFlashNvStorageVariableSize (which in turn comes from VARS_LIVE_SIZE in
"OvmfPkg.fdf.inc").

This equality between both PCDs is a false requirement from
EmuVariableFvbRuntimeDxe. FVB drivers should use
PcdFlashNvStorageVariableSize for supporting non-volatile variables (even
if they happen to be kept in RAM only), along the other PcdFlashNvStorage*
PCDs. Whereas PcdVariableStoreSize is for variables that are volatile at
the gRT->SetVariable() / gRT->GetVariable() API level.

(PlatformPei too bases the preallocation for EmuVariableFvbRuntimeDxe on
PcdFlashNvStorageFtwSpareSize.)

Replace PcdVariableStoreSize in EmuVariableFvbRuntimeDxe with the
same-value PcdFlashNvStorageVariableSize. This means no change in
behavior, and it allows us to increase PcdVariableStoreSize in a later
patch without disturbing EmuVariableFvbRuntimeDxe (or PlatformPei).

Cc: Anthony Perard <anthony.perard@citrix.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Gary Ching-Pang Lin <glin@suse.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Julien Grall <julien.grall@linaro.org>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Gary Lin <glin@suse.com>
Tested-by: Gary Lin <glin@suse.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
2018-03-30 21:18:35 +02:00
Laszlo Ersek 2762bbe9a7 OvmfPkg/EmuVariableFvbRuntimeDxe: list "Fvb.h" in the INF file
Among other things, the header file provides (extern) declarations for the
EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL member functions that are defined in
"Fvb.c". This way "mEmuVarsFvb.FwVolBlockInstance" can be initialized near
the top of "Fvb.c", ahead of the member function definitions.

Cc: Anthony Perard <anthony.perard@citrix.com>
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Julien Grall <julien.grall@linaro.org>
Suggested-by: Michael Kinney <michael.d.kinney@intel.com>
Ref: http://mid.mail-archive.com/E92EE9817A31E24EB0585FDF735412F56327F7D3@ORSMSX113.amr.corp.intel.com
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2018-03-13 14:30:33 +01:00
Laszlo Ersek 6d7af0c9bc OvmfPkg/EmuVariableFvbRuntimeDxe: always format an auth varstore header
In this patch, we extend commit d92eaabefb ("OvmfPkg: simplify
VARIABLE_STORE_HEADER generation", 2016-02-05) to
EmuVariableFvbRuntimeDxe.

This is the difference between FvAndVarTemplate and
FvAndAuthenticatedVarTemplate:

> --- non-auth    2017-05-05 22:32:06.001512283 +0200
> +++ auth        2017-05-05 22:32:18.841364882 +0200
> @@ -1,7 +1,7 @@
>    //
> -  // Templates for standard (non-authenticated) variable FV header
> +  // Templates for authenticated variable FV header
>    //
> -  STATIC FVB_FV_HDR_AND_VARS_TEMPLATE FvAndVarTemplate = {
> +  STATIC FVB_FV_HDR_AND_VARS_TEMPLATE FvAndAuthenticatedVarTemplate = {
>      { // EFI_FIRMWARE_VOLUME_HEADER FvHdr;
>        // UINT8                     ZeroVector[16];
>        { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
> @@ -34,7 +34,7 @@
>        EFI_FVH_REVISION,
>
>        // EFI_FV_BLOCK_MAP_ENTRY    BlockMap[1];
> -      {
> +      {
>          {
>            2, // UINT32 NumBlocks;
>            EMU_FVB_BLOCK_SIZE  // UINT32 Length;
> @@ -44,8 +44,8 @@
>      // EFI_FV_BLOCK_MAP_ENTRY     EndBlockMap;
>      { 0, 0 }, // End of block map
>      { // VARIABLE_STORE_HEADER      VarHdr;
> -      // EFI_GUID  Signature;
> -      EFI_VARIABLE_GUID,
> +        // EFI_GUID  Signature;     // need authenticated variables for secure boot
> +        EFI_AUTHENTICATED_VARIABLE_GUID,
>
>        // UINT32  Size;
>        (

After this change, using "-bios", the variable driver logs:

- with the SB feature enabled:
> Variable driver will work with auth variable format!
> Variable driver will work with auth variable support!

- with the SB feature disabled:
> Variable driver will work with auth variable format!
> Variable driver will continue to work without auth variable support!

Cc: Jordan Justen <jordan.l.justen@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2017-05-18 10:12:20 +02:00
jljusten bdf93df856 OvmfPkg/EmuVariableFvbRuntimeDxe: Add support for PcdSecureBootEnable
When PcdSecureBootEnable is true, the authenticated variable
FV is created.  Otherwise the standard FV is created.

Signed-off-by: lgrosenb
Reviewed-by: jljusten
Reviewed-by: mdkinney

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13092 6f19259b-4bc3-4df7-8a09-765794883524
2012-03-09 17:38:35 +00:00
jljusten e313026824 OvmfPkg EmuVariableFvb: Use 64-bit NV storage PCD
Change from using PcdFlashNvStorageVariableBase to
PcdFlashNvStorageVariableBase64.

This will make sure the EMU Variable FVB will
function in systems with more than 4GB of memory.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11252 6f19259b-4bc3-4df7-8a09-765794883524
2011-01-16 03:32:47 +00:00
jljusten 949b0f3b27 OvmfPkg EMU FVB: Convert to FVB2 protocol
Convert from using EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL
to EFI_FIRMWARE_VOLUME_BLOCK2_PROTOCOL.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11240 6f19259b-4bc3-4df7-8a09-765794883524
2011-01-09 03:50:58 +00:00
hhtian 56d7640a53 Update the copyright notice format
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10439 6f19259b-4bc3-4df7-8a09-765794883524
2010-04-28 12:43:04 +00:00
lgao4 7b202cb0f9 1. Correct File header to ## @file
2. Remove unnecessary .common] postfix on section.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10051 6f19259b-4bc3-4df7-8a09-765794883524
2010-02-23 23:58:38 +00:00
mdkinney 29a3f13989 Remove unnecessary use of FixedPcdxxx() functions and [FixedPcd] INF sections. These should only be used for PCDs that are used to pre-init global variables, pre-init global structures, or size arrays.
Do some minor clean ups to INF files
 


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9870 6f19259b-4bc3-4df7-8a09-765794883524
2010-01-30 00:10:44 +00:00
jljusten 670d495b19 Add EmuVariableFvbRuntimeDxe driver.
This driver implements a firmware volume block protocol instance
which is stored in system memory.

The MdeModulePkg/Universal/Variable/RuntimeDxe and
MdeModulePkg/Universal/FaultTolerantWriteDxe drivers make use of
this FVB instance to provide variable services.

This driver links to a PlatformFvb library to allow for
platform specific processing to take place when data is written
to the FVB.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9315 6f19259b-4bc3-4df7-8a09-765794883524
2009-09-26 07:15:45 +00:00