]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg: SNP should check Cdb.StatCode with PXE_STATCODE_SUCCESS.
authorFu Siyuan <siyuan.fu@intel.com>
Fri, 5 Feb 2016 02:18:25 +0000 (10:18 +0800)
committerFu Siyuan <siyuan.fu@intel.com>
Wed, 17 Feb 2016 00:51:03 +0000 (08:51 +0800)
This patch fixes a bug in SNP driver that the Cdb.StatCode should be check with
PXE_STATCODE_SUCCESS instead of EFI_SUCCESS.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>
Reviewed-by: Ye Ting <ting.ye@intel.com>
MdeModulePkg/Universal/Network/SnpDxe/Get_status.c
MdeModulePkg/Universal/Network/SnpDxe/Receive_filters.c

index 4da07b503f00b55620ab99ef8fbfd5464f78c7ea..edbc0f2374994c73d3562439b896ee869a6b6178 100644 (file)
@@ -80,7 +80,7 @@ PxeGetStatus (
 \r
   (*Snp->IssueUndi32Command) ((UINT64)(UINTN) &Snp->Cdb);\r
 \r
-  if (Snp->Cdb.StatCode != EFI_SUCCESS) {\r
+  if (Snp->Cdb.StatCode != PXE_STATCODE_SUCCESS) {\r
     DEBUG (\r
       (EFI_D_NET,\r
       "\nSnp->undi.get_status()  %xh:%xh\n",\r
index bb98f4c8a79b32a1bb4535bb13095e2b7bd83f96..c37018c8263fb55094e445e1a5765e41f8171c63 100644 (file)
@@ -2,7 +2,7 @@
     Implementation of managing the multicast receive filters of a network\r
     interface.\r
 \r
-Copyright (c) 2004 - 2007, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials are licensed and made available under the \r
 terms and conditions of the BSD License which accompanies this distribution. The \r
 full text of the license may be found at \r
@@ -83,7 +83,7 @@ PxeRecvFilterEnable (
 \r
   (*Snp->IssueUndi32Command) ((UINT64)(UINTN) &Snp->Cdb);\r
 \r
-  if (Snp->Cdb.StatCode != EFI_SUCCESS) {\r
+  if (Snp->Cdb.StatCode != PXE_STATCODE_SUCCESS) {\r
     //\r
     // UNDI command failed.  Return UNDI status to caller.\r
     //\r
@@ -171,7 +171,7 @@ PxeRecvFilterDisable (
 \r
   (*Snp->IssueUndi32Command) ((UINT64)(UINTN) &Snp->Cdb);\r
 \r
-  if (Snp->Cdb.StatCode != EFI_SUCCESS) {\r
+  if (Snp->Cdb.StatCode != PXE_STATCODE_SUCCESS) {\r
     //\r
     // UNDI command failed.  Return UNDI status to caller.\r
     //\r
@@ -223,7 +223,7 @@ PxeRecvFilterRead (
 \r
   (*Snp->IssueUndi32Command) ((UINT64)(UINTN) &Snp->Cdb);\r
 \r
-  if (Snp->Cdb.StatCode != EFI_SUCCESS) {\r
+  if (Snp->Cdb.StatCode != PXE_STATCODE_SUCCESS) {\r
     //\r
     // UNDI command failed.  Return UNDI status to caller.\r
     //\r