]> git.proxmox.com Git - mirror_edk2.git/blobdiff - RedfishPkg/Library/PlatformHostInterfaceLibNull/PlatformHostInterfaceLibNull.c
RedfishPkg/PlatformHostInterfaceLib: Platform NULL lib
[mirror_edk2.git] / RedfishPkg / Library / PlatformHostInterfaceLibNull / PlatformHostInterfaceLibNull.c
diff --git a/RedfishPkg/Library/PlatformHostInterfaceLibNull/PlatformHostInterfaceLibNull.c b/RedfishPkg/Library/PlatformHostInterfaceLibNull/PlatformHostInterfaceLibNull.c
new file mode 100644 (file)
index 0000000..5c93a00
--- /dev/null
@@ -0,0 +1,52 @@
+/** @file\r
+  NULL instace of RedfishPlatformHostInterfaceLib\r
+\r
+  (C) Copyright 2020 Hewlett Packard Enterprise Development LP<BR>\r
+\r
+  SPDX-License-Identifier: BSD-2-Clause-Patent\r
+\r
+**/\r
+#include <Uefi.h>\r
+#include <Library/BaseLib.h>\r
+#include <Library/RedfishHostInterfaceLib.h>\r
+#include <Library/UefiLib.h>\r
+\r
+/**\r
+  Get platform Redfish host interface device descriptor.\r
+\r
+  @param[in] DeviceType         Pointer to retrieve device type.\r
+  @param[out] DeviceDescriptor  Pointer to retrieve REDFISH_INTERFACE_DATA, caller has to free\r
+                                this memory using FreePool().\r
+\r
+  @retval EFI_NOT_FOUND   No Redfish host interface descriptor provided on this platform.\r
+\r
+**/\r
+EFI_STATUS\r
+RedfishPlatformHostInterfaceDeviceDescriptor (\r
+  IN UINT8 *DeviceType,\r
+  OUT REDFISH_INTERFACE_DATA  **DeviceDescriptor\r
+)\r
+{\r
+  return EFI_NOT_FOUND;\r
+}\r
+/**\r
+  Get platform Redfish host interface protocol data.\r
+  Caller should pass NULL in ProtocolRecord to retrive the first protocol record.\r
+  Then continuously pass previous ProtocolRecord for retrieving the next ProtocolRecord.\r
+\r
+  @param[in, out] ProtocolRecord  Pointer to retrieve the first or the next protocol record.\r
+                                  caller has to free the new protocol record returned from\r
+                                  this function using FreePool().\r
+  @param[in] IndexOfProtocolData  The index of protocol data.\r
+\r
+  @retval EFI_NOT_FOUND   No more protocol records.\r
+\r
+**/\r
+EFI_STATUS\r
+RedfishPlatformHostInterfaceProtocolData (\r
+  IN OUT MC_HOST_INTERFACE_PROTOCOL_RECORD **ProtocolRecord,\r
+  IN UINT8  IndexOfProtocolData\r
+)\r
+{\r
+  return EFI_NOT_FOUND;\r
+}\r