From 5cc41f2a6b6aeca1500fe9f55af5858d1c7e4e38 Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Mon, 11 May 2020 12:11:27 -0700 Subject: espi: Add support for debug helper to print slave capabilities This change adds a Kconfig option to enable eSPI debugging that pulls in a helper function to print slave capabilities. BUG=b:153675913 Signed-off-by: Furquan Shaikh Change-Id: I8ff250fe85dfa9370bf93ce3c7e2de5c069bf9e9 Reviewed-on: https://review.coreboot.org/c/coreboot/+/41254 Tested-by: build bot (Jenkins) Reviewed-by: Raul Rangel Reviewed-by: Aaron Durbin --- src/include/espi.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/include/espi.h') diff --git a/src/include/espi.h b/src/include/espi.h index f0ae37383a..7503af79ec 100644 --- a/src/include/espi.h +++ b/src/include/espi.h @@ -229,6 +229,12 @@ #define ESPI_VW_SIGNAL_HIGH(x) (ESPI_VW_VALID(x) | ESPI_VW_VALUE(1, x)) #define ESPI_VW_SIGNAL_LOW(x) (ESPI_VW_VALID(x) | ESPI_VW_VALUE(0, x)) +#if CONFIG(ESPI_DEBUG) +void espi_show_slave_general_configuration(uint32_t config); +#else +static void espi_show_slave_general_configuration(uint32_t config) {} +#endif + static inline bool espi_slave_supports_quad_io(uint32_t gen_caps) { uint32_t mode = gen_caps & ESPI_SLAVE_IO_MODE_SUPP_MASK; -- cgit v1.2.3