public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: Dandan Bi <dandan.bi@intel.com>
To: edk2-devel@lists.01.org
Cc: Dmitry Antipov <dmanti@microsoft.com>,
	Michael D Kinney <michael.d.kinney@intel.com>,
	Liming Gao <liming.gao@intel.com>,
	Star Zeng <star.zeng@intel.com>
Subject: [patch 1/2] MdeModulePkg: Add definition of Boot Performance Table protocol
Date: Mon, 30 Jul 2018 15:00:15 +0800	[thread overview]
Message-ID: <20180730070016.10396-2-dandan.bi@intel.com> (raw)
In-Reply-To: <20180730070016.10396-1-dandan.bi@intel.com>

Add an internal protocol to get the boot performance data,
which is used by driver FirmwarePerformanceDxe to get the
performance data from performance library (DxeCorePerformanceLib).

Cc: Dmitry Antipov <dmanti@microsoft.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
---
 .../Include/Guid/FirmwareBootPerformanceTable.h    | 47 ++++++++++++++++++++++
 MdeModulePkg/MdeModulePkg.dec                      |  4 ++
 2 files changed, 51 insertions(+)
 create mode 100644 MdeModulePkg/Include/Guid/FirmwareBootPerformanceTable.h

diff --git a/MdeModulePkg/Include/Guid/FirmwareBootPerformanceTable.h b/MdeModulePkg/Include/Guid/FirmwareBootPerformanceTable.h
new file mode 100644
index 0000000000..61a21445c7
--- /dev/null
+++ b/MdeModulePkg/Include/Guid/FirmwareBootPerformanceTable.h
@@ -0,0 +1,47 @@
+/** @file
+
+Firmware Boot Performance Table Protocol.
+
+Copyright (c) 2018, Intel Corporation. All rights reserved.<BR>
+This program and the accompanying materials are licensed and made available under
+the terms and conditions of the BSD License that accompanies this distribution.
+The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php.
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+**/
+
+#ifndef _FIRMWARE_BOOT_PERFORMANCE_TABLE_H_
+#define _FIRMWARE_BOOT_PERFORMANCE_TABLE_H_
+
+//
+// GUID for get firmware boot performance table Protocol
+//
+#define FIRMWARE_BOOT_PERFORMANCE_TABLE_PROTOCOL_GUID \
+  { 0xffc182cf, 0xb0da, 0x4e81, {0xaf, 0xf8, 0x45, 0x0d, 0xab, 0x6d, 0xc9, 0xa7 } }
+
+typedef struct _EDKII_FIRMWARE_BOOT_PERFORMANCE_TABLE_PROTOCOL EDKII_FIRMWARE_BOOT_PERFORMANCE_TABLE_PROTOCOL;
+
+/**
+  Get the address of the Firmware Boot Performance Table.
+
+  @param BootPerformanceTable   - Pointer to the address of firmware boot performance table.
+
+  @retval EFI_SUCCESS           - Successfully created performance record.
+  @retval EFI_OUT_OF_RESOURCES  - Ran out of space to store the records.
+**/
+typedef
+EFI_STATUS
+(EFIAPI *GET_FIRMWARE_BOOT_PERFORMANCE_TABLE)(
+  OUT VOID                   **BootPerformanceTable
+  );
+
+struct _EDKII_FIRMWARE_BOOT_PERFORMANCE_TABLE_PROTOCOL {
+  GET_FIRMWARE_BOOT_PERFORMANCE_TABLE GetFirmwareBootPerformanceTable;
+};
+
+extern EFI_GUID gEdkiiFirmwareBootPerformanceTableProtocolGuid;
+
+#endif // _FIRMWARE_BOOT_PERFORMANCE_TABLE_H_
diff --git a/MdeModulePkg/MdeModulePkg.dec b/MdeModulePkg/MdeModulePkg.dec
index 3db97f536e..5faebe5457 100644
--- a/MdeModulePkg/MdeModulePkg.dec
+++ b/MdeModulePkg/MdeModulePkg.dec
@@ -263,10 +263,14 @@
   #  Include/Guid/PerformanceMeasurement.h
   gEdkiiPerformanceMeasurementProtocolGuid      = { 0xc85d06be, 0x5f75, 0x48ce, { 0xa8, 0x0f, 0x12, 0x36, 0xba, 0x3b, 0x87, 0xb1 } }
   gEdkiiSmmPerformanceMeasurementProtocolGuid   = { 0xd56b6d73, 0x1a7b, 0x4015, { 0x9b, 0xb4, 0x7b, 0x07, 0x17, 0x29, 0xed, 0x24 } }
   gEdkiiPerformanceMeasurementPpiGuid           = { 0x0eca9ae3, 0xa792, 0x418c, { 0xbd, 0x36, 0X6c, 0x2e, 0xca, 0x5c, 0x59, 0xfc } }
 
+  ## Protocol to get firmware boot performance table.
+  #  Include/Guid/FirmwareBootPerformanceTable.h
+  gEdkiiFirmwareBootPerformanceTableProtocolGuid = { 0xffc182cf, 0xb0da, 0x4e81, { 0xaf, 0xf8, 0x45, 0x0d, 0xab, 0x6d, 0xc9, 0xa7 } }
+
   ## Guid is defined for CRC32 encapsulation scheme.
   #  Include/Guid/Crc32GuidedSectionExtraction.h
   gEfiCrc32GuidedSectionExtractionGuid = { 0xFC1BCDB0, 0x7D31, 0x49aa, {0x93, 0x6A, 0xA4, 0x60, 0x0D, 0x9D, 0xD0, 0x83 } }
 
   ## Include/Guid/StatusCodeCallbackGuid.h
-- 
2.14.3.windows.1



  reply	other threads:[~2018-07-30  7:01 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-30  7:00 [patch 0/2] Enahnce Perf data transfer between Dxe Perf Lib and driver Dandan Bi
2018-07-30  7:00 ` Dandan Bi [this message]
2018-07-30  7:00 ` [patch 2/2] MdeModulePkg: Implement/use Boot Performance Table protocol Dandan Bi
2018-08-03  9:39 ` [patch 0/2] Enahnce Perf data transfer between Dxe Perf Lib and driver Gao, Liming

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180730070016.10396-2-dandan.bi@intel.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox