]> git.proxmox.com Git - mirror_edk2.git/blobdiff - ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/LibSmbiosView.h
Refine comments and two code style.
[mirror_edk2.git] / ShellPkg / Library / UefiShellDebug1CommandsLib / SmbiosView / LibSmbiosView.h
index 7ef341b0d688aeffadff163dd36bb723f3eda985..5a9b2ad626a88ff41780bc2c93a7c024ebb7e958 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   API for SMBIOS Plug and Play functions, access to SMBIOS table and structures.\r
 \r
-  Copyright (c) 2005 - 2010, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2005 - 2011, Intel Corporation. All rights reserved.<BR>\r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
   which accompanies this distribution.  The full text of the license may be found at\r
@@ -12,8 +12,8 @@
 \r
 **/\r
 \r
-#ifndef _LIB_SMBIOS_VIEW_H\r
-#define _LIB_SMBIOS_VIEW_H\r
+#ifndef _LIB_SMBIOS_VIEW_H_\r
+#define _LIB_SMBIOS_VIEW_H_\r
 \r
 #include "LibSmbios.h"\r
 \r
 #define EFI_SMBIOSERR_TYPE_UNKNOWN      EFI_SMBIOSERR (3)\r
 #define EFI_SMBIOSERR_UNSUPPORTED       EFI_SMBIOSERR (4)\r
 \r
+/**\r
+  Init the SMBIOS VIEW API's environment.\r
+\r
+  @retval EFI_SUCCESS  Successful to init the SMBIOS VIEW Lib.\r
+**/\r
 EFI_STATUS\r
 LibSmbiosInit (\r
   VOID\r
   );\r
 \r
+/**\r
+  Cleanup the Smbios information.\r
+**/\r
 VOID\r
 LibSmbiosCleanup (\r
   VOID\r
   );\r
 \r
-VOID\r
-LibSmbiosGetEPS (\r
-  SMBIOS_STRUCTURE_TABLE **pEntryPointStructure\r
-  );\r
+/**\r
+  Get the entry point structure for the table.\r
 \r
+  @param[out] EntryPointStructure  The pointer to populate.\r
+**/\r
 VOID\r
-LibSmbiosGetStructHead (\r
-  SMBIOS_STRUCTURE_POINTER *pHead\r
+LibSmbiosGetEPS (\r
+  OUT SMBIOS_STRUCTURE_TABLE **EntryPointStructure\r
   );\r
 \r
-EFI_STATUS\r
-LibGetSmbiosInfo (\r
-  OUT CHAR8   *dmiBIOSRevision,\r
-  OUT UINT16  *NumStructures,\r
-  OUT UINT16  *StructureSize,\r
-  OUT UINT32  *dmiStorageBase,\r
-  OUT UINT16  *dmiStorageSize\r
-  );\r
+/**\r
+    Get SMBIOS structure given the Handle,copy data to the Buffer,\r
+    Handle is changed to the next handle or 0xFFFF when the end is\r
+    reached or the handle is not found.\r
 \r
-/*++\r
-  Description:\r
-    Get SMBIOS Information.\r
+    @param[in, out] Handle     0xFFFF: get the first structure\r
+                               Others: get a structure according to this value.\r
+    @param[in, out] Buffer     The pointer to the caller's memory buffer.\r
+    @param[out] Length         Length of return buffer in bytes.\r
 \r
-  Arguments:\r
-    dmiBIOSRevision   - Revision of the SMBIOS Extensions.\r
-    NumStructures     - Max. Number of Structures the BIOS will return.\r
-    StructureSize     - Size of largest SMBIOS Structure.\r
-    dmiStorageBase    - 32-bit physical base address for memory mapped SMBIOS data.\r
-    dmiStorageSize    - Size of the memory-mapped SMBIOS data.\r
+    @retval DMI_SUCCESS   Buffer contains the required structure data\r
+                          Handle is updated with next structure handle or\r
+                          0xFFFF(end-of-list).\r
 \r
-  Returns:\r
-    DMI_SUCCESS                 - successful.\r
-    DMI_FUNCTION_NOT_SUPPORTED  - Does not support SMBIOS calling interface capability.\r
+    @retval DMI_INVALID_HANDLE  Buffer not contain the requiring structure data.\r
+                                Handle is updated with next structure handle or\r
+                                0xFFFF(end-of-list).\r
 **/\r
 EFI_STATUS\r
 LibGetSmbiosStructure (\r
@@ -90,20 +92,12 @@ LibGetSmbiosStructure (
   OUT UINT16      *Length\r
   );\r
 \r
-/*++\r
-  Description:\r
-    Get SMBIOS structure given the Handle,copy data to the Buffer,Handle is then the next.\r
-\r
-  Arguments:\r
-    Handle:         - 0x0: get the first structure\r
-                    - Others: get a certain structure according to this value.\r
-    Buffter:        - contains the pointer to the caller's memory buffer.\r
+/**\r
+  Get a string from the smbios information.\r
 \r
-  Returns:\r
-    DMI_SUCCESS         - Buffer contains the required structure data\r
-                        - Handle is updated with next structure handle or 0xFFFF(end-of-list).\r
-    DMI_INVALID_HANDLE  - Buffer not contain the requiring structure data\r
-                        - Handle is updated with next structure handle or 0xFFFF(end-of-list).\r
+  @param[in] Smbios         The pointer to the smbios information.\r
+  @param[in] StringNumber   The index to the string to get.\r
+  @param[out] Buffer        The buffer to fill with the string when retrieved.\r
 **/\r
 VOID\r
 SmbiosGetPendingString (\r
@@ -112,9 +106,17 @@ SmbiosGetPendingString (
   OUT CHAR8                         *Buffer\r
   );\r
 \r
+/**\r
+  Check the structure to see if it is legal.\r
+\r
+  @param[in] Smbios    - Pointer to the structure that will be checked.\r
+\r
+  @retval DMI_SUCCESS           Structure data is legal.\r
+  @retval DMI_BAD_PARAMETER     Structure data contains bad parameter.\r
+**/\r
 EFI_STATUS\r
 SmbiosCheckStructure (\r
-  IN  SMBIOS_STRUCTURE_POINTER      *Smbios\r
+  IN  SMBIOS_STRUCTURE_POINTER *Smbios\r
   );\r
 \r
 #endif\r