mb/prodrive/atlas: Add support to read from EC EMI
[coreboot.git] / src / mainboard / prodrive / atlas / ec.h
blobbad990434011b3b2ef4d2be6cf9dd0ab221e3c97
1 /* SPDX-License-Identifier: GPL-2.0-only */
3 #ifndef MICROCHIP_MEC152X_EC_H
4 #define MICROCHIP_MEC152X_EC_H
6 /*
7 * Used references: MEC152x datasheet (Microchip document DS00003427C)
8 */
10 #include <types.h>
12 /* TABLE 3-1: BASE ADDRESS */
13 #define LDN_ESPI_IO_COMPONENT 0xd
15 /* TABLE 9-6: ESPI I/O BASE ADDRESS REGISTER DEFAULT VALUES */
16 #define EMI_0_IOBASE_INDEX 0x68
17 #define EMI_1_IOBASE_INDEX 0x6c
19 void ec_espi_io_program_iobase(const u16 port, const u8 iobase_index, const u16 base);
21 void ec_emi_read(u8 *dest, const u16 base, const u8 region, const u16 offset, const u16 length);
23 #endif /* MICROCHIP_MEC152X_EC_H */