]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Universal/Network/SnpDxe/Get_status.c
BaseTools:Change the path of the file that Binary Cache
[mirror_edk2.git] / MdeModulePkg / Universal / Network / SnpDxe / Get_status.c
index 4da07b503f00b55620ab99ef8fbfd5464f78c7ea..be6608a0b33a2f965cdf43f3a31eab3cb5e724ad 100644 (file)
@@ -3,13 +3,7 @@
   buffer status from a network interface.\r
 \r
 Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials are licensed\r
-and made available under the terms and conditions of the BSD License which\r
-accompanies this distribution. The full text of the license may be found at\r
-http://opensource.org/licenses/bsd-license.php\r
-\r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+SPDX-License-Identifier: BSD-2-Clause-Patent\r
 \r
 **/\r
 \r
@@ -18,24 +12,25 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 /**\r
   Call undi to get the status of the interrupts, get the list of recycled transmit\r
   buffers that completed transmitting. The recycled transmit buffer address will\r
-  be saved into Snp->RecycledTxBuf.\r
+  be saved into Snp->RecycledTxBuf. This function will also update the MediaPresent\r
+  field of EFI_SIMPLE_NETWORK_MODE if UNDI support it.\r
 \r
-  @param  Snp                     Pointer to snp driver structure.\r
-  @param  InterruptStatusPtr      A non null pointer to contain the interrupt\r
-                                  status.\r
-  @param  GetTransmittedBuf       Set to TRUE to retrieve the recycled transmit\r
-                                  buffer address.\r
+  @param[in]   Snp                     Pointer to snp driver structure.\r
+  @param[out]  InterruptStatusPtr      A non null pointer to contain the interrupt\r
+                                       status.\r
+  @param[in]   GetTransmittedBuf       Set to TRUE to retrieve the recycled transmit\r
+                                       buffer address.\r
 \r
-  @retval EFI_SUCCESS         The status of the network interface was retrieved.\r
-  @retval EFI_DEVICE_ERROR    The command could not be sent to the network\r
-                              interface.\r
+  @retval      EFI_SUCCESS             The status of the network interface was retrieved.\r
+  @retval      EFI_DEVICE_ERROR        The command could not be sent to the network\r
+                                       interface.\r
 \r
 **/\r
 EFI_STATUS\r
 PxeGetStatus (\r
-  SNP_DRIVER *Snp,\r
-  UINT32     *InterruptStatusPtr,\r
-  BOOLEAN    GetTransmittedBuf\r
+  IN     SNP_DRIVER *Snp,\r
+     OUT UINT32     *InterruptStatusPtr,\r
+  IN     BOOLEAN    GetTransmittedBuf\r
   )\r
 {\r
   PXE_DB_GET_STATUS *Db;\r
@@ -80,7 +75,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