summaryrefslogtreecommitdiff
path: root/EdkModulePkg
diff options
context:
space:
mode:
Diffstat (limited to 'EdkModulePkg')
-rw-r--r--EdkModulePkg/Universal/Network/PxeBc/Dxe/pxe_bc_dhcp.c2
-rw-r--r--EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.c9
2 files changed, 9 insertions, 2 deletions
diff --git a/EdkModulePkg/Universal/Network/PxeBc/Dxe/pxe_bc_dhcp.c b/EdkModulePkg/Universal/Network/PxeBc/Dxe/pxe_bc_dhcp.c
index 101c030bc8..2e22fc5a35 100644
--- a/EdkModulePkg/Universal/Network/PxeBc/Dxe/pxe_bc_dhcp.c
+++ b/EdkModulePkg/Universal/Network/PxeBc/Dxe/pxe_bc_dhcp.c
@@ -621,8 +621,6 @@ AddRouters (
DHCP_RECEIVE_BUFFER *RxBufPtr
)
{
- Ip4AddRouter (Private, &RxBufPtr->u.Dhcpv4.giaddr);
-
Ip4AddRouterList (
Private,
(DHCPV4_OP_IP_LIST *) RxBufPtr->OpAdds.PktOptAdds[OP_ROUTER_LIST_IX - 1]
diff --git a/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.c b/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.c
index e224558651..589217a992 100644
--- a/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.c
+++ b/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.c
@@ -1403,6 +1403,15 @@ Returns:
sizeof (UINT32),
(UINT8 *) &VariableStoreEntry.Length
);
+ //
+ // As Variables are stored in NV storage, which are slow devices,such as flash.
+ // Variable operation may skip checking variable program result to improve performance,
+ // We can assume Variable program is OK through some check point.
+ // Variable Store Size Setting should be the first Variable write operation,
+ // We can assume all Read/Write is OK if we can set Variable store size successfully.
+ // If write fail, we will assert here
+ //
+ ASSERT(VariableStoreHeader->Size == VariableStoreEntry.Length);
if (EFI_ERROR (Status)) {
return Status;