Skip to content

Commit 88a208a

Browse files
committed
Set 8250.nr_uarts when running x86 kernels
1 parent 9e9109e commit 88a208a

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

Makefile

+4-1
Original file line numberDiff line numberDiff line change
@@ -392,7 +392,10 @@ endif
392392

393393
ifeq ($(ARCH),x86_64)
394394
QEMU_BIN := qemu-system-x86_64
395-
QEMU_KERNEL_CMDLINE += console=ttyS0 kpti no5lvl
395+
396+
# 8250.nr_uarts=1 is needed because some Android kernels set
397+
# `CONFIG_SERIAL_8250_RUNTIME_UARTS` to zero
398+
QEMU_KERNEL_CMDLINE += console=ttyS0 kpti no5lvl 8250.nr_uarts=1
396399

397400
QEMU_ARGS += -cpu kvm64,+smep,+smap
398401

config/config.fragment

+5
Original file line numberDiff line numberDiff line change
@@ -92,3 +92,8 @@ CONFIG_TRACING=y
9292

9393
# Allow lvl5 paging
9494
CONFIG_X86_5LEVEL=y
95+
96+
# Some ACK kernels set this to zero. Technically we don't need it because we
97+
# also set it in the kernel command line, but it helps if someone wants to use
98+
# our prebuilt kernels and run them manually
99+
CONFIG_SERIAL_8250_RUNTIME_UARTS=4

0 commit comments

Comments
 (0)