[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190802100349.8659-4-frieder.schrempf@kontron.de>
Date: Fri, 2 Aug 2019 10:04:11 +0000
From: Schrempf Frieder <frieder.schrempf@...tron.de>
To: "u.kleine-koenig@...gutronix.de" <u.kleine-koenig@...gutronix.de>,
"shawnguo@...nel.org" <shawnguo@...nel.org>,
"s.hauer@...gutronix.de" <s.hauer@...gutronix.de>,
"kernel@...gutronix.de" <kernel@...gutronix.de>,
"festevam@...il.com" <festevam@...il.com>,
"linux-imx@....com" <linux-imx@....com>
CC: "linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"geert+renesas@...der.be" <geert+renesas@...der.be>,
Schrempf Frieder <frieder.schrempf@...tron.de>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jiri Slaby <jslaby@...e.com>,
"linux-serial@...r.kernel.org" <linux-serial@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: [PATCH v3 4/4] serial: 8250: Don't check for mctrl_gpio_init()
returning -ENOSYS
From: Frieder Schrempf <frieder.schrempf@...tron.de>
Now that the mctrl_gpio code returns NULL instead of ERR_PTR(-ENOSYS)
if CONFIG_GPIOLIB is disabled, we can safely remove this check.
Signed-off-by: Frieder Schrempf <frieder.schrempf@...tron.de>
---
Changes in v3
=============
* Adjust the commit message and subject line
Changes in v2
=============
* Add a patch for the 8250 driver
---
drivers/tty/serial/8250/8250_core.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index df3bcc0b2d74..e682390ce0de 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1026,10 +1026,8 @@ int serial8250_register_8250_port(struct uart_8250_port *up)
if (!has_acpi_companion(uart->port.dev)) {
gpios = mctrl_gpio_init(&uart->port, 0);
if (IS_ERR(gpios)) {
- if (PTR_ERR(gpios) != -ENOSYS) {
- ret = PTR_ERR(gpios);
- goto out_unlock;
- }
+ ret = PTR_ERR(gpios);
+ goto out_unlock;
} else {
uart->gpios = gpios;
}
--
2.17.1
Powered by blists - more mailing lists