zephyr/drivers/serial/Kconfig.xen
Dmytro Firsov ac0f731b2e xen: add Kconfig option for Zephyr on Dom0less setups
Dom0less is Xen mode without privileged domain. All guests are created
according to hypervisor device tree configuration on boot. Thus, there
is no Dom0 with console daemon, that usually manages console output
from domains.

Zephyr OS contains 2 serial drivers related to Xen hypervisor: regular
with console shared page and consoleio-based. The first one is for
setups with console daemon and usually was used for Zephyr DomU guests.
The second one previously was used only for Zephyr Dom0 and had
corresponding Kconfig options. But consoleio is also used as interface
for DomU output on Dom0less setups and should be configurable without
XEN_DOM0 option.

Add corresponding XEN_DOM0LESS config to Xen Kconfig files and proper
dependencies in serial drivers.

Signed-off-by: Dmytro Firsov <dmytro_firsov@epam.com>
Co-authored-by: Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>
2023-09-18 10:43:45 +01:00

45 lines
1.4 KiB
Plaintext

# Xen hypervisor console via UART setup
#
# Copyright (c) 2021-2023 EPAM Systems
# SPDX-License-Identifier: Apache-2.0
#
config UART_XEN_HVC
bool "Xen hypervisor DomU console UART driver"
default y
depends on DT_HAS_XEN_HVC_UART_ENABLED
select SERIAL_HAS_DRIVER
select SERIAL_SUPPORT_INTERRUPT
depends on XEN && !XEN_DOM0 && !XEN_DOM0LESS
help
Enable Xen ring buffer based hypervisor console driver. Used
for Zephyr as unprivileged domain.
config UART_XEN_HVC_CONSOLEIO
bool "Xen hypervisor consoleio UART driver"
select SERIAL_HAS_DRIVER
depends on XEN_DOM0 || XEN_DOM0LESS
default y
help
Enable Xen hypervisor console driver. Used for Zephyr as
privileged domain (Dom0) or for Zephyr DomU in Dom0less
configuration. Dom0less configuration does not have
privileged domain. Thus, there is no console daemon and Xen
manages all domain outputs through the consoleio interface.
config XEN_HVC_INIT_PRIORITY
int "Xen hypervisor console init priority"
depends on UART_XEN_HVC || UART_XEN_HVC_CONSOLEIO
default 55
help
Set init priority for Xen HVC, should be inited before UART
console driver (HVC gets inited on PRE_KERNEL_1 stage).
config XEN_EARLY_CONSOLEIO
bool "Early printk/stdout through console_io Xen interface"
depends on UART_XEN_HVC
help
Enable setting of console_io symbol hook for stdout and printk.
Log output will become available on PRE_KERNEL_1 stage. Requires
Xen, compiled with CONFIG_DEBUG flag.