mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-06 17:18:32 +00:00
![]() FreeBSD detects serial ports twice: First, very early in the boot process, in order to obtain a usable console; and second, during the device probe/attach process. When a UART is discovered during device probing, FreeBSD attempts to determine whether it is a device which was already being used as a console; without this, the console doesn't work in userland. Unfortunately it's possible for a UART to be mapped to a different location in memory when it is discovered on a bus than it has when it is announced via the ACPI SPCR table; this breaks the matching process, which relies on comparing bus addresses. To address this, we introduce a concept of "unique" serial devices, i.e. devices which are guaranteed to be present *only once* on any system. If we discover one of these during device probing, we can match it to a same-PCI-vendor-and-device-numbers console which was announced via the ACPI SPCR table, regardless of the differing bus addresses. At present, the only unique serial device is the "Amazon PCI serial device" (vendor 0x1d0f, device 0x8250) found in some EC2 instances. This unbreaks the serial console on those systems. Reviewed by: imp MFC after: 3 days Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D34703 |
||
---|---|---|
.. | ||
uart.h | ||
uart_bus.h | ||
uart_bus_acpi.c | ||
uart_bus_fdt.c | ||
uart_bus_isa.c | ||
uart_bus_pci.c | ||
uart_bus_puc.c | ||
uart_bus_scc.c | ||
uart_core.c | ||
uart_cpu.h | ||
uart_cpu_acpi.c | ||
uart_cpu_acpi.h | ||
uart_cpu_arm64.c | ||
uart_cpu_fdt.c | ||
uart_cpu_fdt.h | ||
uart_cpu_powerpc.c | ||
uart_cpu_x86.c | ||
uart_dbg.c | ||
uart_dev_imx.c | ||
uart_dev_imx.h | ||
uart_dev_lowrisc.c | ||
uart_dev_lowrisc.h | ||
uart_dev_msm.c | ||
uart_dev_msm.h | ||
uart_dev_mu.c | ||
uart_dev_mvebu.c | ||
uart_dev_ns8250.c | ||
uart_dev_ns8250.h | ||
uart_dev_pl011.c | ||
uart_dev_quicc.c | ||
uart_dev_snps.c | ||
uart_dev_ti8250.c | ||
uart_dev_z8530.c | ||
uart_if.m | ||
uart_ppstypes.h | ||
uart_subr.c | ||
uart_tty.c |