TianoCore EDK2 master
Loading...
Searching...
No Matches
I2cEnumerate.h File Reference
#include <Pi/PiI2c.h>

Go to the source code of this file.

Data Structures

struct  _EFI_I2C_ENUMERATE_PROTOCOL
 

Macros

#define EFI_I2C_ENUMERATE_PROTOCOL_GUID   { 0xda8cd7c4, 0x1c00, 0x49e2, { 0x80, 0x3e, 0x52, 0x14, 0xe7, 0x01, 0x89, 0x4c }}
 

Typedefs

typedef struct _EFI_I2C_ENUMERATE_PROTOCOL EFI_I2C_ENUMERATE_PROTOCOL
 
typedef EFI_STATUS(EFIAPI * EFI_I2C_ENUMERATE_PROTOCOL_ENUMERATE) (IN CONST EFI_I2C_ENUMERATE_PROTOCOL *This, IN OUT CONST EFI_I2C_DEVICE **Device)
 
typedef EFI_STATUS(EFIAPI * EFI_I2C_ENUMERATE_PROTOCOL_GET_BUS_FREQUENCY) (IN CONST EFI_I2C_ENUMERATE_PROTOCOL *This, IN UINTN I2cBusConfiguration, OUT UINTN *BusClockHertz)
 

Variables

EFI_GUID gEfiI2cEnumerateProtocolGuid
 

Detailed Description

I2C Device Enumerate Protocol as defined in the PI 1.3 specification.

This protocol supports the enumerations of device on the I2C bus.

Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Revision Reference:
This protocol is from PI Version 1.3.

Definition in file I2cEnumerate.h.

Macro Definition Documentation

◆ EFI_I2C_ENUMERATE_PROTOCOL_GUID

#define EFI_I2C_ENUMERATE_PROTOCOL_GUID   { 0xda8cd7c4, 0x1c00, 0x49e2, { 0x80, 0x3e, 0x52, 0x14, 0xe7, 0x01, 0x89, 0x4c }}

Definition at line 19 of file I2cEnumerate.h.

Typedef Documentation

◆ EFI_I2C_ENUMERATE_PROTOCOL

Definition at line 21 of file I2cEnumerate.h.

◆ EFI_I2C_ENUMERATE_PROTOCOL_ENUMERATE

typedef EFI_STATUS(EFIAPI * EFI_I2C_ENUMERATE_PROTOCOL_ENUMERATE) (IN CONST EFI_I2C_ENUMERATE_PROTOCOL *This, IN OUT CONST EFI_I2C_DEVICE **Device)

Enumerate the I2C devices

This function enables the caller to traverse the set of I2C devices on an I2C bus.

Parameters
[in]ThisThe platform data for the next device on the I2C bus was returned successfully.
[in,out]DevicePointer to a buffer containing an EFI_I2C_DEVICE structure. Enumeration is started by setting the initial EFI_I2C_DEVICE structure pointer to NULL. The buffer receives an EFI_I2C_DEVICE structure pointer to the next I2C device.
Return values
EFI_SUCCESSThe platform data for the next device on the I2C bus was returned successfully.
EFI_INVALID_PARAMETERDevice is NULL
EFI_NO_MAPPING*Device does not point to a valid EFI_I2C_DEVICE structure returned in a previous call Enumerate().

Definition at line 47 of file I2cEnumerate.h.

◆ EFI_I2C_ENUMERATE_PROTOCOL_GET_BUS_FREQUENCY

typedef EFI_STATUS(EFIAPI * EFI_I2C_ENUMERATE_PROTOCOL_GET_BUS_FREQUENCY) (IN CONST EFI_I2C_ENUMERATE_PROTOCOL *This, IN UINTN I2cBusConfiguration, OUT UINTN *BusClockHertz)

Get the requested I2C bus frequency for a specified bus configuration.

This function returns the requested I2C bus clock frequency for the I2cBusConfiguration. This routine is provided for diagnostic purposes and is meant to be called after calling Enumerate to get the I2cBusConfiguration value.

Parameters
[in]ThisPointer to an EFI_I2C_ENUMERATE_PROTOCOL structure.
[in]I2cBusConfigurationI2C bus configuration to access the I2C device
[out]*BusClockHertzPointer to a buffer to receive the I2C bus clock frequency in Hertz
Return values
EFI_SUCCESSThe I2C bus frequency was returned successfully.
EFI_INVALID_PARAMETERBusClockHertz was NULL
EFI_NO_MAPPINGInvalid I2cBusConfiguration value

Definition at line 75 of file I2cEnumerate.h.

Variable Documentation

◆ gEfiI2cEnumerateProtocolGuid

EFI_GUID gEfiI2cEnumerateProtocolGuid
extern

Reference to variable defined in the .DEC file