Skip to content

Commit 1c7d2f6

Browse files
JasonChenCJNanlinXie
authored andcommitted
vuart: change irq from 4 to 6
irq 4 is sharing with idma, after change vuart to level trigger, the idma driver could handle this irq 4 and send out EOI, which cause the irq storm. move vuart irq to a not used 6. Tracked-On: #1476 Signed-off-by: Jason Chen CJ <jason.cj.chen@intel.com>
1 parent 6485666 commit 1c7d2f6

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

hypervisor/arch/x86/assign.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ is_entry_active(struct ptdev_remapping_info *entry)
4545

4646
static bool ptdev_hv_owned_intx(struct vm *vm, union source_id *virt_sid)
4747
{
48-
/* vm0 pin 4 (uart) is owned by hypervisor under debug version */
49-
if (is_vm0(vm) && (virt_sid->intx_id.pin == 4U)) {
48+
/* vm0 vuart pin is owned by hypervisor under debug version */
49+
if (is_vm0(vm) && (virt_sid->intx_id.pin == COM1_IRQ)) {
5050
return true;
5151
} else {
5252
return false;

hypervisor/debug/vuart.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
#include "uart16550.h"
3434

3535
#define COM1_BASE 0x3F8U
36-
#define COM1_IRQ 4U
3736

3837
#ifndef CONFIG_PARTITION_MODE
3938
static char vuart_rx_buf[RX_BUF_SIZE];

hypervisor/include/debug/vuart.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,13 @@ struct acrn_vuart {
6969
extern int8_t vuart_vmid;
7070
#endif
7171
#ifdef HV_DEBUG
72+
#define COM1_IRQ 6U
7273
void vuart_init(struct vm *vm);
7374
struct acrn_vuart *vuart_console_active(void);
7475
void vuart_console_tx_chars(struct acrn_vuart *vu);
7576
void vuart_console_rx_chars(struct acrn_vuart *vu);
7677
#else
78+
#define COM1_IRQ 0xFFU
7779
static inline void vuart_init(__unused struct vm *vm)
7880
{
7981
}

0 commit comments

Comments
 (0)