From 513c9f8744d40e2a75966f244a5cc3771be426b2 Mon Sep 17 00:00:00 2001 From: Conghui Chen Date: Mon, 29 Apr 2019 14:07:55 +0800 Subject: [PATCH] HV: vuart: move the vuart code to dm directory As there is a requirement for conmunication between VMs on uart port, but for Pre-launched VM, the only way is to create vuart for each VM and connect them at hypervisor side. So, the vuart code should be moved from /debug to /dm so that they can also be used in release version. For the console related code, as no need to support in release version, so leave them at debug directory. Tracked-On: #2987 Signed-off-by: Conghui Chen Acked-by: Eddie Dong --- hypervisor/Makefile | 1 + hypervisor/{debug => dm}/vuart.c | 0 hypervisor/include/{debug => dm}/vuart.h | 0 hypervisor/release/vuart.c | 23 ----------------------- 4 files changed, 1 insertion(+), 23 deletions(-) rename hypervisor/{debug => dm}/vuart.c (100%) rename hypervisor/include/{debug => dm}/vuart.h (100%) delete mode 100644 hypervisor/release/vuart.c diff --git a/hypervisor/Makefile b/hypervisor/Makefile index 7d603991d..fb054ba8a 100644 --- a/hypervisor/Makefile +++ b/hypervisor/Makefile @@ -225,6 +225,7 @@ C_SRCS += hw/pci.c C_SRCS += dm/vpic.c C_SRCS += dm/vrtc.c C_SRCS += dm/vioapic.c +C_SRCS += dm/vuart.c C_SRCS += dm/io_req.c C_SRCS += dm/vpci/vdev.c C_SRCS += dm/vpci/vpci.c diff --git a/hypervisor/debug/vuart.c b/hypervisor/dm/vuart.c similarity index 100% rename from hypervisor/debug/vuart.c rename to hypervisor/dm/vuart.c diff --git a/hypervisor/include/debug/vuart.h b/hypervisor/include/dm/vuart.h similarity index 100% rename from hypervisor/include/debug/vuart.h rename to hypervisor/include/dm/vuart.h diff --git a/hypervisor/release/vuart.c b/hypervisor/release/vuart.c deleted file mode 100644 index f35a090f1..000000000 --- a/hypervisor/release/vuart.c +++ /dev/null @@ -1,23 +0,0 @@ -/* - * Copyright (C) 2018 Intel Corporation. All rights reserved. - * - * SPDX-License-Identifier: BSD-3-Clause - */ - -#include -#include - -void vuart_init(__unused struct acrn_vm *vm, __unused struct vuart_config *vu_config) {} -void vuart_deinit(__unused struct acrn_vm *vm) {} -struct acrn_vuart *vuart_console_active(void) -{ - return NULL; -} - -void vuart_console_tx_chars(__unused struct acrn_vuart *vu) {} -void vuart_console_rx_chars(__unused struct acrn_vuart *vu) {} - -bool is_vuart_intx(__unused struct acrn_vm *vm, __unused uint32_t intx_pin) -{ - return false; -}