Merge "msm_geni_serial_console: Make early console depend on kernel console"

This commit is contained in:
qctecmdr 2020-04-13 10:50:16 -07:00 • committed by Gerrit - the friendly Code Review server
commit 0f55bd9fca
3 changed files with 17 additions and 7 deletions

View file

@ -977,11 +977,18 @@ config SERIAL_MSM_GENI
hardware.
The driver supports console and High speed UART functions.
config SERIAL_MSM_GENI_EARLY_CONSOLE
bool "MSM on-chip GENI HW based early console support"
help
Serial early console driver for Qualcomm Technologies Inc's GENI
based QUP hardware.
config SERIAL_MSM_GENI_CONSOLE
bool "MSM on-chip GENI HW based console support"
depends on SERIAL_MSM_GENI=y
tristate "MSM on-chip GENI HW based console support"
depends on SERIAL_MSM_GENI
select SERIAL_CORE_CONSOLE
select SERIAL_EARLYCON
select SERIAL_MSM_GENI_EARLY_CONSOLE
help
Serial console driver for Qualcomm Technologies Inc's GENI based
QUP hardware.

View file

@ -56,7 +56,7 @@ obj-$(CONFIG_SERIAL_ATMEL) += atmel_serial.o
obj-$(CONFIG_SERIAL_UARTLITE) += uartlite.o
obj-$(CONFIG_SERIAL_MSM) += msm_serial.o
obj-$(CONFIG_SERIAL_MSM_GENI) += msm_geni_serial.o
obj-$(CONFIG_SERIAL_MSM_GENI_CONSOLE) += msm_geni_serial_console.o
obj-$(CONFIG_SERIAL_MSM_GENI_EARLY_CONSOLE) += msm_geni_serial_console.o
obj-$(CONFIG_SERIAL_KS8695) += serial_ks8695.o
obj-$(CONFIG_SERIAL_OMAP) += omap-serial.o
obj-$(CONFIG_SERIAL_ALTERA_UART) += altera_uart.o

View file

@ -709,7 +709,8 @@ static void msm_geni_serial_poll_put_char(struct uart_port *uport,
}
#endif
#if defined(CONFIG_SERIAL_MSM_GENI_CONSOLE) || defined(CONFIG_CONSOLE_POLL)
#if IS_ENABLED(CONFIG_SERIAL_MSM_GENI_CONSOLE) || \
IS_ENABLED(CONFIG_CONSOLE_POLL)
static void msm_geni_serial_wr_char(struct uart_port *uport, int ch)
{
geni_write_reg_nolog(ch, uport->membase, SE_GENI_TX_FIFOn);
@ -2212,8 +2213,9 @@ static ssize_t ver_info_show(struct device *dev,
}
static DEVICE_ATTR_RO(ver_info);
#if defined(CONFIG_SERIAL_MSM_GENI_CONSOLE) || defined(CONFIG_CONSOLE_POLL)
static int msm_geni_console_setup(struct console *co, char *options)
#if IS_ENABLED(CONFIG_SERIAL_MSM_GENI_CONSOLE) || \
IS_ENABLED(CONFIG_CONSOLE_POLL)
static int __init msm_geni_console_setup(struct console *co, char *options)
{
struct uart_port *uport;
struct msm_geni_serial_port *dev_port;
@ -2406,7 +2408,8 @@ static const struct uart_ops msm_geni_serial_pops = {
};
static const struct of_device_id msm_geni_device_tbl[] = {
#if defined(CONFIG_SERIAL_MSM_GENI_CONSOLE) || defined(CONFIG_CONSOLE_POLL)
#if IS_ENABLED(CONFIG_SERIAL_MSM_GENI_CONSOLE) || \
IS_ENABLED(CONFIG_CONSOLE_POLL)
{ .compatible = "qcom,msm-geni-console",
.data = (void *)&msm_geni_console_driver},
#endif