|
Zephyr API Documentation 4.5.99
A Scalable Open Source RTOS
|
Microchip eSPI Driver Header. More...
Go to the source code of this file.
Functions | |
| int | mchp_xec_espi_sram_bar_get (const struct device *dev, uint8_t id, uint8_t **buf, size_t *size) |
| Get the EC buffer backing an eSPI SRAM BAR. | |
Microchip eSPI Driver Header.
This header provides conditional inclusion of Microchip eSPI controller extension to types from espi.h
| int mchp_xec_espi_sram_bar_get | ( | const struct device * | dev, |
| uint8_t | id, | ||
| uint8_t ** | buf, | ||
| size_t * | size ) |
Get the EC buffer backing an eSPI SRAM BAR.
The driver allocates the EC SRAM region of each SRAM BAR enabled in the "microchip,xec-espi-sram-bar" devicetree node. Host memory cycles to the BAR host address read and write this buffer.
| dev | Pointer to the eSPI device |
| id | SRAM BAR index (0 or 1) |
| buf | Pointer to store the EC buffer address |
| size | Pointer to store the buffer size in bytes |
| 0 | success |
| -EINVAL | if dev, buf or size is NULL |
| -ENODEV | if SRAM BAR id is not enabled in devicetree |