xref: /aosp_15_r20/external/coreboot/src/include/console/qemu_debugcon.h (revision b9411a12aaaa7e1e6a6fb7c5e057f44ee179a49c)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 
3 #ifndef _QEMU_DEBUGCON_H_
4 #define _QEMU_DEBUGCON_H_
5 
6 #include <stdint.h>
7 
8 void qemu_debugcon_init(void);
9 void qemu_debugcon_tx_byte(unsigned char data);
10 
11 #if CONFIG(CONSOLE_QEMU_DEBUGCON) && \
12 	(ENV_SEPARATE_ROMSTAGE || ENV_RAMSTAGE || ENV_POSTCAR || ENV_BOOTBLOCK)
__qemu_debugcon_init(void)13 static inline void __qemu_debugcon_init(void)	{ qemu_debugcon_init(); }
__qemu_debugcon_tx_byte(u8 data)14 static inline void __qemu_debugcon_tx_byte(u8 data)
15 {
16 	qemu_debugcon_tx_byte(data);
17 }
18 #else
__qemu_debugcon_init(void)19 static inline void __qemu_debugcon_init(void)	{}
__qemu_debugcon_tx_byte(u8 data)20 static inline void __qemu_debugcon_tx_byte(u8 data)	{}
21 #endif
22 
23 #endif
24