OpenCore
1.0.4
OpenCore Bootloader
|
#include "DataHub.h"
Go to the source code of this file.
Functions | |
EFI_STATUS EFIAPI | DataHubLogData (IN EFI_DATA_HUB_PROTOCOL *This, IN EFI_GUID *DataRecordGuid, IN EFI_GUID *ProducerName, IN UINT64 DataRecordClass, IN VOID *RawData, IN UINT32 RawDataSize) |
EFI_DATA_RECORD_HEADER * | GetNextDataRecord (IN LIST_ENTRY *Head, IN UINT64 ClassFilter, IN OUT UINT64 *PtrCurrentMTC) |
DATA_HUB_FILTER_DRIVER * | FindFilterDriverByEvent (IN LIST_ENTRY *Head, IN EFI_EVENT Event) |
EFI_STATUS EFIAPI | DataHubGetNextRecord (IN EFI_DATA_HUB_PROTOCOL *This, IN OUT UINT64 *MonotonicCount, IN EFI_EVENT *FilterDriverEvent, OPTIONAL OUT EFI_DATA_RECORD_HEADER **Record) |
EFI_STATUS EFIAPI | DataHubRegisterFilterDriver (IN EFI_DATA_HUB_PROTOCOL *This, IN EFI_EVENT FilterEvent, IN EFI_TPL FilterTpl, IN UINT64 FilterClass, IN EFI_GUID *FilterDataRecordGuid OPTIONAL) |
EFI_STATUS EFIAPI | DataHubUnregisterFilterDriver (IN EFI_DATA_HUB_PROTOCOL *This, IN EFI_EVENT FilterEvent) |
EFI_DATA_HUB_PROTOCOL * | DataHubInstall (VOID) |
Variables | |
DATA_HUB_INSTANCE | mPrivateData |
This code produces the Data Hub protocol. It preloads the data hub with status information copied in from PEI HOBs.
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file DataHub.c.
EFI_STATUS EFIAPI DataHubGetNextRecord | ( | IN EFI_DATA_HUB_PROTOCOL * | This, |
IN OUT UINT64 * | MonotonicCount, | ||
IN EFI_EVENT * | FilterDriverEvent, | ||
OPTIONAL OUT EFI_DATA_RECORD_HEADER ** | Record ) |
Get a previously logged data record and the MonotonicCount for the next available Record. This allows all records or all records later than a give MonotonicCount to be returned. If an optional FilterDriverEvent is passed in with a MonotonicCout of zero return the first record not yet read by the filter driver. If FilterDriverEvent is NULL and MonotonicCount is zero return the first data record.
This | Pointer to the EFI_DATA_HUB_PROTOCOL instance. |
MonotonicCount | Specifies the Record to return. On input, zero means return the first record. On output, contains the next record to available. Zero indicates no more records. |
FilterDriverEvent | If FilterDriverEvent is not passed in a MonotonicCount of zero, it means to return the first data record. If FilterDriverEvent is passed in, then a MonotonicCount of zero means to return the first data not yet read by FilterDriverEvent. |
Record | Returns a dynamically allocated memory buffer with a data record that matches MonotonicCount. |
EFI_SUCCESS | Data was returned in Record. |
EFI_INVALID_PARAMETER | FilterDriverEvent was passed in but does not exist. |
EFI_NOT_FOUND | MonotonicCount does not match any data record in the system. If a MonotonicCount of zero was passed in, then no data records exist in the system. |
EFI_OUT_OF_RESOURCES | Record was not returned due to lack of system resources. |
EFI_DATA_HUB_PROTOCOL * DataHubInstall | ( | VOID | ) |
EFI_STATUS EFIAPI DataHubLogData | ( | IN EFI_DATA_HUB_PROTOCOL * | This, |
IN EFI_GUID * | DataRecordGuid, | ||
IN EFI_GUID * | ProducerName, | ||
IN UINT64 | DataRecordClass, | ||
IN VOID * | RawData, | ||
IN UINT32 | RawDataSize ) |
Log data record into the data logging hub
This | Protocol instance structure |
DataRecordGuid | GUID that defines record contents |
ProducerName | GUID that defines the name of the producer of the data |
DataRecordClass | Class that defines generic record type |
RawData | Data Log record as defined by DataRecordGuid |
RawDataSize | Size of Data Log data in bytes |
EFI_SUCCESS | If data was logged |
EFI_OUT_OF_RESOURCES | If data was not logged due to lack of system resources. |
EFI_STATUS EFIAPI DataHubRegisterFilterDriver | ( | IN EFI_DATA_HUB_PROTOCOL * | This, |
IN EFI_EVENT | FilterEvent, | ||
IN EFI_TPL | FilterTpl, | ||
IN UINT64 | FilterClass, | ||
IN EFI_GUID *FilterDataRecordGuid | OPTIONAL ) |
This function registers the data hub filter driver that is represented by FilterEvent. Only one instance of each FilterEvent can be registered. After the FilterEvent is registered, it will be signaled so it can sync with data records that have been recorded prior to the FilterEvent being registered.
This | Pointer to The EFI_DATA_HUB_PROTOCOL instance. |
FilterEvent | The EFI_EVENT to signal whenever data that matches FilterClass is logged in the system. |
FilterTpl | The maximum EFI_TPL at which FilterEvent can be signaled. It is strongly recommended that you use the lowest EFI_TPL possible. |
FilterClass | FilterEvent will be signaled whenever a bit in EFI_DATA_RECORD_HEADER.DataRecordClass is also set in FilterClass. If FilterClass is zero, no class-based filtering will be performed. |
FilterDataRecordGuid | FilterEvent will be signaled whenever FilterDataRecordGuid matches EFI_DATA_RECORD_HEADER.DataRecordGuid. If FilterDataRecordGuid is NULL, then no GUID-based filtering will be performed. |
EFI_SUCCESS | The filter driver event was registered. |
EFI_ALREADY_STARTED | FilterEvent was previously registered and cannot be registered again. |
EFI_OUT_OF_RESOURCES | The filter driver event was not registered due to lack of system resources. |
EFI_STATUS EFIAPI DataHubUnregisterFilterDriver | ( | IN EFI_DATA_HUB_PROTOCOL * | This, |
IN EFI_EVENT | FilterEvent ) |
Remove a Filter Driver, so it no longer gets called when data information is logged.
This | Protocol instance structure |
FilterEvent | Event that represents a filter driver that is to be Unregistered. |
EFI_SUCCESS | If FilterEvent was unregistered |
EFI_NOT_FOUND | If FilterEvent does not exist |
DATA_HUB_FILTER_DRIVER * FindFilterDriverByEvent | ( | IN LIST_ENTRY * | Head, |
IN EFI_EVENT | Event ) |
Search the Head list for a EFI_DATA_HUB_FILTER_DRIVER member that represents Event and return it.
Head | Pointer to head of dual linked list of EFI_DATA_HUB_FILTER_DRIVER structures. |
Event | Event to be search for in the Head list. |
EFI_DATA_HUB_FILTER_DRIVER | Returned if Event stored in the Head doubly linked list. |
NULL | If Event is not in the list |
EFI_DATA_RECORD_HEADER * GetNextDataRecord | ( | IN LIST_ENTRY * | Head, |
IN UINT64 | ClassFilter, | ||
IN OUT UINT64 * | PtrCurrentMTC ) |
Search the Head doubly linked list for the passed in MTC. Return the matching element in Head and the MTC on the next entry.
Head | Head of Data Log linked list. |
ClassFilter | Only match the MTC if it is in the same Class as the ClassFilter. |
PtrCurrentMTC | On IN contians MTC to search for. On OUT contians next MTC in the data log list or zero if at end of the list. |
EFI_DATA_LOG_ENTRY | Return pointer to data log data from Head list. |
NULL | If no data record exists. |
DATA_HUB_INSTANCE mPrivateData |