mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-24 21:54:34 -04:00
serial: msm_geni_serial: Use IS_ENABLED() instead of ifdef CONFIG
The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Change-Id: I20ba557462b3080483e60ffd68a2e50d79468135 Signed-off-by: Mukesh Kumar Savaliya <msavaliy@codeaurora.org>
This commit is contained in:
parent
154c4ef97c
commit
59431dbdaa
1 changed files with 7 additions and 4 deletions
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Reference in a new issue