kernel: make tty count for 8250 configurable
The number of serial interfaces for the chip 8250 can be configured at build time. This is currently not configurable and is always set to 16 interfaces. This is too little for some small embedded devices and too much for others (x86_64). Therefore, this commit creates the possibility to set this at compile time. Signed-off-by: Florian Eckert <fe@dev.tdt.de> Link: https://github.com/openwrt/openwrt/pull/19217 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This commit is contained in:
parent
1c6cb6d5be
commit
b93bb3dc62
1 changed files with 25 additions and 2 deletions
|
@ -566,8 +566,6 @@ define KernelPackage/serial-8250
|
|||
DEPENDS:=@!TARGET_uml
|
||||
KCONFIG:= CONFIG_SERIAL_8250 \
|
||||
CONFIG_SERIAL_8250_PCI \
|
||||
CONFIG_SERIAL_8250_NR_UARTS=16 \
|
||||
CONFIG_SERIAL_8250_RUNTIME_UARTS=16 \
|
||||
CONFIG_SERIAL_8250_EXTENDED=y \
|
||||
CONFIG_SERIAL_8250_MANY_PORTS=y \
|
||||
CONFIG_SERIAL_8250_SHARE_IRQ=y \
|
||||
|
@ -585,6 +583,31 @@ define KernelPackage/serial-8250/description
|
|||
Kernel module for 8250 UART based serial ports
|
||||
endef
|
||||
|
||||
define KernelPackage/serial-8250/config
|
||||
menu "Configuration"
|
||||
depends on PACKAGE_kmod-serial-8250
|
||||
|
||||
config KERNEL_SERIAL_8250_NR_UARTS
|
||||
int "Maximum number of 8250/16550 serial ports"
|
||||
default "16"
|
||||
help
|
||||
Set this to the number of serial ports you want the driver
|
||||
to support. This includes any ports discovered via ACPI or
|
||||
PCI enumeration and any ports that may be added at run-time
|
||||
via hot-plug, or any ISA multi-port serial cards.
|
||||
|
||||
config KERNEL_SERIAL_8250_RUNTIME_UARTS
|
||||
int "Number of 8250/16550 serial ports to register at runtime"
|
||||
range 0 KERNEL_SERIAL_8250_NR_UARTS
|
||||
default "16"
|
||||
help
|
||||
Set this to the maximum number of serial ports you want
|
||||
the kernel to register at boot time. This can be overridden
|
||||
with the module parameter "nr_uarts", or boot-time parameter
|
||||
8250.nr_uarts
|
||||
endmenu
|
||||
endef
|
||||
|
||||
$(eval $(call KernelPackage,serial-8250))
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue