Update NetLibGetMacAddress() to handle the case correctly when SNP is absent.
authorFu Siyuan <siyuan.fu@intel.com>
Wed, 27 Nov 2013 08:57:11 +0000 (08:57 +0000)
committersfu5 <sfu5@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 27 Nov 2013 08:57:11 +0000 (08:57 +0000)
Signed-off-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Ni, Ruiyu <ruiyu.ni@intel.com>
Reviewed-by: Jin, Eric <eric.jin@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14904 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Library/DxeNetLib/DxeNetLib.c

index cfda3962bb82a3d072c90476937455869820ee1b..467b82280eead55a16472111888457c69145649b 100644 (file)
@@ -2250,7 +2250,7 @@ NetLibGetMacAddress (
     // Try to get SNP mode from MNP\r
     //\r
     Status = Mnp->GetModeData (Mnp, NULL, &SnpModeData);\r
-    if (EFI_ERROR (Status)) {\r
+    if (EFI_ERROR (Status) && (Status != EFI_NOT_STARTED)) {\r
       MnpSb->DestroyChild (MnpSb, MnpChildHandle);\r
       return Status;\r
     }\r