Sync patches r14454, r14455, r14456, r14457, r14458, and r14462 from main trunk.
1. MdeModulePkg: Variable drivers robustly handle crashes during Reclaim().
2. SecurityPkg: Variable drivers robustly handle crashes during Reclaim().
3. Nt32Pkg: Use FaultTolerantWritePei driver.
4. EmulatorPkg: Use FaultTolerantWritePei driver.
5. OvmfPkg EmuVariableFvbRuntimeDxe: Let FaultTolerantWriteDxe to init working block header.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15341 6f19259b-4bc3-4df7-8a09-765794883524
Sync patches r15136 and r15137 from main trunk.
1. DxeCore is designed to trust input data, so add comments to reminder caller to do check to follow PI specification when necessary.
   Since LBA_CACHE is DxeCore implementation specific, DxeCore will check it here.
2. CapsulePei coalesce need add more sanity check for each Capsule Fragment.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15342 6f19259b-4bc3-4df7-8a09-765794883524
Sync patch r15233 from main trunk.
Add more check for PE COFF SizeOfHeader field.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15343 6f19259b-4bc3-4df7-8a09-765794883524
Sync patches r15321, r15329, r15334 and r15339 from main trunk.
1. Remove unused variable attribute flag.
2. Fix the return status when physical presence variable and MemoryOverwriteRequestControl variable are corrupt.
3. Add comments for PcdHideTpmSupport.
4. Fix the return value bug when updating public key database variable failure.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15344 6f19259b-4bc3-4df7-8a09-765794883524
Sync patch r15328 from main trunk.
Remove ASSERT when failed to Get/Set "AttemptOrder" and "ClientId" variable.
Removes RT attribute for "AttemptOrder?" variable.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15345 6f19259b-4bc3-4df7-8a09-765794883524
Sync patches r15330, r15331 and r15336 from main trunk.
1. Remove ASSERT check for SetVariable in FirmwarePerformanceDataTableDxe.
2. Add comments to describe PlatformDriOverrideDxe is used for test purpose.
3. Remove ASSERT when SetVariable for ConOutDev/ConInDev/ErrOutDev variables failed.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15346 6f19259b-4bc3-4df7-8a09-765794883524
Sync patches r15333 and r15337 from main trunk.
1. Do not reset system when the MemoryTypeInformation variable cannot be written.
   Remove the RT attribute for the MemoryTypeInformation variable because it's not necessary.
2. IntelFrameworkModulePkg AcpiS3SaveDxe: Remove ASSERT, add lock and remove RT for AcpiGlobalVariable variable.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15347 6f19259b-4bc3-4df7-8a09-765794883524
Sync patch r15338 from main trunk.
Did proper error handling when SetVariable failed, and put RTC write operation at the behind of SetVariable, if SetVariable failed, RTC content could not be changed.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15348 6f19259b-4bc3-4df7-8a09-765794883524
Sync patch r15340 from main trunk.
MdeModulePkg/SecurityPkg Variable: Return error status to avoid inconsistency between PlatformLang and Lang.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2010.SR1@15349 6f19259b-4bc3-4df7-8a09-765794883524