|
TT Zephyr Platforms 19.5.0-rc1
Tenstorrent Firmware
|
#include <stdint.h>Go to the source code of this file.
Data Structures | |
| struct | SmbusCmdDef |
Typedefs | |
| typedef int32_t(* | SmbusRcvHandler) (const uint8_t *data, uint8_t size) |
| Definition of a SMBUS receive handler. | |
| typedef int32_t(* | SmbusSendHandler) (uint8_t *data, uint8_t *size) |
| Definition of a SMBUS send handler. | |
Enumerations | |
| enum | SmbusTransType { kSmbusTransWriteByte , kSmbusTransReadByte , kSmbusTransWriteWord , kSmbusTransReadWord , kSmbusTransBlockWrite , kSmbusTransBlockRead , kSmbusTransBlockWriteBlockRead } |
| A list of supported SMBUS transaction types. More... | |
Functions | |
| int32_t | smbus_target_register_cmd (const struct device *dev, uint8_t cmd_id, const SmbusCmdDef *smbus_cmd) |
| Register the given command to the SMBUS target implementation. | |
Definition of a SMBUS receive handler.
This function is invoked when the SMBUS target has data from the I2C controller to relay to the application. SMBUS receive handlers shall return 0 on success, and any other value on failure.
Definition of a SMBUS send handler.
This function is invoked when the SMBUS target requests data from the application to send to the I2C controller. SMBUS send handlers shall return 0 on success, and any other value on failure.
| enum SmbusTransType |
| int32_t smbus_target_register_cmd | ( | const struct device * | dev, |
| uint8_t | cmd_id, | ||
| const SmbusCmdDef * | smbus_cmd ) |
Register the given command to the SMBUS target implementation.
| dev | The device to register the command for. |
| cmd_id | The command ID to register the handler for. |
| smbus_cmd | Pointer to the smbus command to register. The memory must have persistent storage for the duration of the time the target remains registered to the I2C. |