Commit Graph

14342 Commits

Author SHA1 Message Date
Laszlo Ersek 0e8a31f5c9 OvmfPkg: PlatformPei: lifecycle fixes for the LockBox area
If (mBootMode == BOOT_ON_S3_RESUME) -- that is, we are resuming --, then
the patch has no observable effect.

If (mBootMode != BOOT_ON_S3_RESUME && mS3Supported) -- that is, we are
booting or rebooting, and S3 is supported), then the patch has no
observable effect either.

If (mBootMode != BOOT_ON_S3_RESUME && !mS3Supported) -- that is, we are
booting or rebooting, and S3 is unsupported), then the patch effects the
following two fixes:

- The LockBox storage is reserved from DXE (but not the OS). Drivers in
  DXE may save data in the LockBox regardless of S3 support, potentially
  corrupting any overlapping allocations. Make sure there's no overlap.

- The LockBox storage is cleared. A LockBox inherited across a non-resume
  reboot, populated with well-known GUIDs, breaks drivers that want to
  save entries with those GUIDs.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Matt Fleming <matt.fleming@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15418 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-31 20:35:50 +00:00
Dong Guo cbbac2e1ef Remove unused [PcdsDynamic, PcdsDynamicEx] section.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dong Guo <guo.dong@intel.com>
Reviewed-by: Fan, Jeff <jeff.fan@intel.com>
Reviewed-by: Ni, Ruiyu <ruiyu.ni@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15416 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-31 01:54:51 +00:00
Eric Dong 7a1f792dcf Check the input file pointer before use it.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Guo, Dong <guo.dong@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15412 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-28 05:51:51 +00:00
Ruiyu Ni c4571f0479 Add check to avoid null pointer deference.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15410 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-28 02:50:47 +00:00
Star Zeng 3a4b498ee1 SecurityPkg Variable: Add NULL pointer check.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Guo Dong <guo.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15409 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-28 02:47:46 +00:00
Elvin Li 4c7e997ef1 Add NULL pointer check in I2chost.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Elvin Li <elvin.li@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15408 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-28 02:34:31 +00:00
Elvin Li 4b0786b4fa Add ASSERT to check if NewVariable is NULL.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Elvin Li <elvin.li@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15407 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-28 02:13:41 +00:00
Chris Phillips d6e88a6c60 ShellPkg: Fix file system change issue that results in ASSERT
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chris Phillips <chrisp@hp.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15406 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-27 18:21:43 +00:00
Dong Guo 2bc363714e Remove hide TPM support.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dong Guo <guo.dong@intel.com>
Reviewed-by: Yao Jiewen <jiewen.yao@intel.com>
Reviewed-by: Ni, Ruiyu <ruiyu.ni@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15405 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-27 11:03:04 +00:00
Dong Guo 9a12e5825a Calculate enough space for 2 variables (public key and variable data) instead of directly setting them 1 by 1.
Fixed a bug in public key reclaim().

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dong Guo <guo.dong@intel.com>
Reviewed-by: Yao Jiewen <jiewen.yao@intel.com>
Reviewed-by: Zeng, Star <star.zeng@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15404 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-27 10:54:23 +00:00
Eric Dong 2c775600d5 Update code logic, remove ASSERT and use error handling.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15403 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-27 07:08:15 +00:00
Jeff Fan 3bf04a71bf Not to copy mailbox into new space when debug agent initialization for S3 Boot Script.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15402 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-27 06:02:54 +00:00
Gao, Liming 90651f7773 Remove RT attribute for variable PlatDriOver.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gao, Liming <liming.gao@intel.com>
Reviewed-by: Yao, Jiewen <jiewen.yao@intel.com>
Reviewed-by: Zeng, Star <star.zeng@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15401 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-27 05:11:02 +00:00
Olivier Martin 44372159a2 ArmPkg/ArmCpuLib: Added A57 Errata 806969
This rare errata only affects r0p0

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15400 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:35:17 +00:00
Olivier Martin 19dc108b65 ArmPkg/ArmLib: Correct Error Handling in AArch64
There are several instances of asserts which do not also handle
the error condition in Release builds.
Because these functions are called in different location of the
code and their parameters might change during the execution, it
is safer to handle the error.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15399 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:34:32 +00:00
Olivier Martin cf02da5203 ArmPkg/ArmCortexA5xLib: Fixed setting of SMP bit
On CortexA5x the SMP bit is BIT6 of CPUECTLR_EL1 register.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15398 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:33:51 +00:00
Olivier Martin 47d183db53 ArmPkg/ArmCortexA5x: Declared the helper functions to access the CPU Extended Control Register
This register is A5x specific. It is the reason why the code moved from ArmLib
to ArmCpuLib/ArmCortexA5xLib.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15397 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:32:48 +00:00
Olivier Martin 52d44f77c2 ArmPkg/ArmLib: Added helper functions for accessing CPU ACTLR
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15396 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:31:01 +00:00
Olivier Martin b7dd4dbd26 ArmPkg/Chipset: Added ARMv8 CPU's PartNum
PartNum is the field of MIDR that returns the CPU name.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15395 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:29:31 +00:00
Olivier Martin ffcf178215 ArmPlatformPkg/ArmVExpressPkg: Add processor identifiers for Cortex A12/A7
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15394 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 19:28:35 +00:00
Gao, Liming 9f25f7ddd0 Add check to make sure the data be valid.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gao, Liming <liming.gao@intel.com>
Reviewed-by: Zeng, Star <star.zeng@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15393 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 09:27:01 +00:00
Star Zeng f85acc224c PerfomancePkg Dp: Add missing EFIAPI for PrintToken().
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15392 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 07:08:12 +00:00
Ruiyu Ni be9198c96d Remove RT attribute for variable LegacyDevOrder
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15391 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-26 04:23:48 +00:00
Harry Liebel d276ac10f1 ArmPkg/SemihostFs: Various fixes for the file system
- Fix file deletion from the shell.
- Fix file creation using the shell editor.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Harry Liebel <Harry.Liebel@arm.com>
Reviewed-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15390 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-25 11:04:41 +00:00
Harry Liebel 228fdff4be ArmPkg/SemihostLib: Made arguments 'native' size
The arguments passed to the semi-hosing backend should
be of 'native' size to match register widths.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Harry Liebel <Harry.Liebel@arm.com>
Reviewed-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15389 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-25 11:03:54 +00:00
Star Zeng b2bd493edb MdeModulePkg/SecurityPkg Variable: Calculate enough space for PlatformLang and Lang variables and use PcdUefiVariableDefaultLangDeprecate to turn off auto update between PlatformLang and Lang variables.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Guo Dong <guo.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15388 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-25 06:56:55 +00:00
Eric Dong a8d8d43051 Support load 64 bit image from 32 bit core.
Add more enhancement to check invalid PE format.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Jiewen, Yao <jiewen.yao@intel.com>
Reviewed-by: Liming, Gao <liming.gao@intel.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15387 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-25 05:04:21 +00:00
Ruiyu Ni 5070befc3b Report the setting variable failure to platform through the status code when core cannot handle the error.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Elvin Li <elvin.li@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15386 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-25 03:54:34 +00:00
Ruiyu Ni 69fc8f080e Report the setting variable failure to platform through the status code when core cannot handle the error.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15385 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-25 02:38:54 +00:00
Olivier Martin 5456c26c2f ArmPkg/CompilerIntrinsicsLib: Added memset() to AArch64
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15384 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:30:48 +00:00
Olivier Martin 785e3cf681 EmbeddedPkg: Added Isp1761UsbDxe to EmbeddedPkg.dsc
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15383 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:29:50 +00:00
Olivier Martin 5ee57c2d7d ArmPkg/ArmLib: Removed unused AArch64 files
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15382 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:29:03 +00:00
Olivier Martin 647517279d ArmPkg/ArmLib: Renamed Cp15CacheInfo into ArmCacheInfo
CTR (Cache Type Register) has the same format on ARMv7 and AArch64.
Renaming Cp15CacheInfo() into ArmCacheInfo() makes this function
architecture independent.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15381 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:26:22 +00:00
Olivier Martin d9bd3f11cb ArmPkg/ArmLib: Removed unused ArmSwitchProcessorMode & ArmProcessorMode functions
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15380 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:25:44 +00:00
Olivier Martin 0676fadd05 ArmPkg: Removed unused header files from source files
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15379 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:25:01 +00:00
Olivier Martin c32aaba962 ArmPkg: Fix typo in comment and trailing spaces
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15378 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-24 15:24:23 +00:00
Dong Guo 2001537d53 Comment PwdCredential driver.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dong Guo <guo.dong@intel.com>
Reviewed-by: Yao Jiewen <jiewen.yao@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15376 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-23 23:47:18 +00:00
Laszlo Ersek ddb2c493f7 OvmfPkg: PlatformDxe: connect RouteConfig() to platform data
Establish the full stack of conversions when modifying the platform
configuration:

       ConfigResp            -- form engine / HII communication
            |
     [ConfigToBlock]
            |
            v
     MAIN_FORM_STATE         -- binary representation of form/widget state
            |
[FormStateToPlatformConfig]
            |
            v
     PLATFORM_CONFIG         -- accessible to DXE and UEFI drivers
            |
   [PlatformConfigSave]
            |
            v
  UEFI non-volatile variable -- accessible to external utilities

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15375 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:14:09 +00:00
Laszlo Ersek cbd08bcc17 OvmfPkg: PlatformDxe: connect ExtractConfig() to platform data
Establish the full stack of conversions in retrieving the platform
configuration:

    MultiConfigAltResp       -- form engine / HII communication
            ^
            |
     [BlockToConfig]
            |
     MAIN_FORM_STATE         -- binary representation of form/widget state
            ^
            |
[PlatformConfigToFormState]
            |
     PLATFORM_CONFIG         -- accessible to DXE and UEFI drivers
            ^
            |
   [PlatformConfigLoad]
            |
  UEFI non-volatile variable -- accessible to external utilities

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15374 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:14:03 +00:00
Laszlo Ersek 1df57ba3e6 OvmfPkg: PlatformDxe: add save and discard buttons to the form
The RouteConfig() function is also called now as expected.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15373 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:57 +00:00
Laszlo Ersek da07afaf59 OvmfPkg: PlatformDxe: get available resolutions from GOP
Generate the options for the drop-down list from the GOP resolutions.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15372 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:50 +00:00
Laszlo Ersek 9c08bbe59c OvmfPkg: QemuVideoDxe: serialize Start() against callbacks
If Start() succeeds, the callback is only executed when the setup is
complete (on the stack of RestoreTPL()), rather than on the stack of
InstallMultipleProtocolInterfaces(), when the driver setup may yet be
theoretically incomplete.

If Start() fails, the protocol interface will have been uninstalled
(rolled back) by the time the callback runs (again, on the stack of
RestoreTPL()). Since protocol notification callbacks begin with locating
the protocol interface in question, such attempts to locate will fail
immediately and save some work in the callback.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15371 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:44 +00:00
Jordan Justen bc4c536628 OvmfPkg/PlatformDxe: Silence warning seen with GCC48 IA32
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15370 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:38 +00:00
Laszlo Ersek 92e745505c OvmfPkg: PlatformDxe: add form widgets for video modes
In this patch we populate the form with the two widgets related to video
resolution:
- A read-only string field displaying the preference for the next boot.
- A drop-down list offering choices for changing the setting. This list is
  implemented with dynamically generated IFR opcodes.

(In general, the current preference may be missing, or it may be invalid
for the available video RAM size. The list of possible new settings is
filtered with the video RAM size.)

Because the form now becomes able to receive input, we must also implement
ExtractConfig(). This function tells the HII engine about the state of the
widgets.

For now we set up both widgets with static data only:
- The current preference always says "Unset". The driver code is still
  isolated from the backend (the UEFI variable store).
- The list of possible resolutions offers 800x600 only. We don't
  interrogate the GOP yet.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15369 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:31 +00:00
Laszlo Ersek 276a7ea147 OvmfPkg: PlatformDxe: introduce state for the main form
We'll need a C language (ie. structure) representation for the state of
the visual elements on the form. We choose the Buffer Storage kind (see
29.2.5.6 "Storage" in UEFI 2.4A), because it's easy to work with.

Note that the structure added in this patch has nothing to do with UEFI
non-volatile variables.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15368 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:24 +00:00
Laszlo Ersek 877a4dbb02 OvmfPkg: PlatformDxe: add an empty HII form
... which opens from the Device Manager window.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15367 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:18 +00:00
Laszlo Ersek bdaf30e4e6 OvmfPkg: PlatformDxe: set preferred video resolution from platform config
The GraphicsConsoleDxe driver (in MdeModulePkg/Universal/Console)
determines the preferred video resolution from the dynamic PCDs
- gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution
- gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution

Setting the graphics resolution during boot is useful when the guest OS
(for lack of a dedicated display driver) continues to work with the
original GOP resolution and framebuffer.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15366 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:09 +00:00
Laszlo Ersek 5267c89b4d OvmfPkg: PlatformDxe: utility functions for saving / loading configuration
The two functions introduced here allow the saving and loading of platform
configuration to/from the non-volatile variable store.

The PLATFORM_CONFIG structure and the two functions that take it / return
it are generally meant for any DXE or UEFI driver that needs to access
platform configuration. For now we keep this small "library" internal to
PlatformDxe.

The PLATFORM_CONFIG wire format is intended only to grow over time (as
long as the variable GUID remains unchanged). At the introduction of new
fields, new feature flags must be added, and recognized in
PlatformConfigLoad().

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15365 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:13:02 +00:00
Laszlo Ersek d945a8ba5b OvmfPkg: introduce empty PlatformDxe
This DXE driver will load/save persistent values for OVMF's config knobs,
plus expose those knobs via HII.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15364 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:12:55 +00:00
Laszlo Ersek 732295d149 OvmfPkg: introduce gOvmfPlatformConfigGuid
This GUID should become a new "namespace" for UEFI variables that are
specific to OVMF configuration (as opposed to standard UEFI global
variables). We'll also use it as the GUID of the related HII form-set (ie.
the interactive user interface).

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15363 6f19259b-4bc3-4df7-8a09-765794883524
2014-03-22 07:12:46 +00:00