From 276fa2ff1ce6724d3fb0e3d90582f1960239748f Mon Sep 17 00:00:00 2001 From: Xiang Xiao Date: Fri, 7 May 2021 05:09:33 -0700 Subject: [PATCH] drivers/serial: Change the default value of SERIAL_NPOLLWAITERS to 4 since the console is normally opened three time as stdin, stdout and stderr and remove the dependence on STANDARD_SERIAL because other type of serial drivers also support the poll through the same codebase. Signed-off-by: Xiang Xiao Change-Id: Ie68322c4647cc838b295491329969869d6ba310b --- drivers/serial/Kconfig | 5 ++--- include/nuttx/serial/serial.h | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/serial/Kconfig b/drivers/serial/Kconfig index 2dd39d73816..df266481ba3 100644 --- a/drivers/serial/Kconfig +++ b/drivers/serial/Kconfig @@ -91,11 +91,10 @@ config STANDARD_SERIAL config SERIAL_NPOLLWAITERS int "Number of poll threads" - default 2 - depends on STANDARD_SERIAL + default 4 ---help--- Maximum number of threads than can be waiting for POLL events. - Default: 2 + Default: 4 config SERIAL_IFLOWCONTROL bool diff --git a/include/nuttx/serial/serial.h b/include/nuttx/serial/serial.h index c258f189a1a..5d2435df4c8 100644 --- a/include/nuttx/serial/serial.h +++ b/include/nuttx/serial/serial.h @@ -45,7 +45,7 @@ /* Maximum number of threads than can be waiting for POLL events */ #ifndef CONFIG_SERIAL_NPOLLWAITERS -# define CONFIG_SERIAL_NPOLLWAITERS 2 +# define CONFIG_SERIAL_NPOLLWAITERS 4 #endif /* RX flow control */