libpayload: configs: Add new config.featuretest to broaden CI
[coreboot.git] / src / mainboard / lenovo / s230u / ec.h
blob7ef06e2f8cf8a7fefb446fde0b1e37f78c618285
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 #ifndef _MAINBOARD_LENOVO_S230U_EC_H
4 #define _MAINBOARD_LENOVO_S230U_EC_H
6 void lenovo_s230u_ec_init(void);
8 #define ECMM(x) (*((volatile u8 *)(uintptr_t)(CONFIG_EC_BASE_ADDRESS + x)))
9 #define ec_mm_read(addr) (ECMM(0x100 + addr))
10 #define ec_mm_write(addr, data) (ECMM(0x100 + addr) = data)
11 #define ec_mm_set_bit(addr, bit) (ECMM(0x100 + addr) |= 1 << bit)
12 #define ec_mm_clr_bit(addr, bit) (ECMM(0x100 + addr) &= ~(1 << bit))
14 #endif /* _MAINBOARD_LENOVO_S230U_EC_H */