VirtualBox

Ignore:
Timestamp:
Aug 12, 2020 4:09:12 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
139865
Message:

Devices/EFI: Merge edk-stable202005 and make it build, bugref:4643

Location:
trunk/src/VBox/Devices/EFI/FirmwareNew
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/EFI/FirmwareNew

  • trunk/src/VBox/Devices/EFI/FirmwareNew/OvmfPkg/SmmAccess/SmramInternal.c

    r80721 r85718  
    2222UINT16 mQ35TsegMbytes;
    2323
     24//
     25// The value of PcdQ35SmramAtDefaultSmbase is saved into this variable at
     26// module startup.
     27//
     28STATIC BOOLEAN mQ35SmramAtDefaultSmbase;
     29
    2430/**
    2531  Save PcdQ35TsegMbytes into mQ35TsegMbytes.
     
    3137{
    3238  mQ35TsegMbytes = PcdGet16 (PcdQ35TsegMbytes);
     39}
     40
     41/**
     42  Save PcdQ35SmramAtDefaultSmbase into mQ35SmramAtDefaultSmbase.
     43**/
     44VOID
     45InitQ35SmramAtDefaultSmbase (
     46  VOID
     47  )
     48{
     49  mQ35SmramAtDefaultSmbase = PcdGetBool (PcdQ35SmramAtDefaultSmbase);
    3350}
    3451
     
    125142  PciOr8 (DRAMC_REGISTER_Q35 (MCH_ESMRAMC), MCH_ESMRAMC_T_EN);
    126143  PciOr8 (DRAMC_REGISTER_Q35 (MCH_SMRAM),   MCH_SMRAM_D_LCK);
     144
     145  //
     146  // Close & lock the SMRAM at the default SMBASE, if it exists.
     147  //
     148  if (mQ35SmramAtDefaultSmbase) {
     149    PciWrite8 (DRAMC_REGISTER_Q35 (MCH_DEFAULT_SMBASE_CTL),
     150      MCH_DEFAULT_SMBASE_LCK);
     151  }
    127152
    128153  GetStates (LockState, OpenState);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette