Commit 3d7514da authored by Frieder Schrempf's avatar Frieder Schrempf Committed by Greg Kroah-Hartman

serial: 8250: Don't check for mctrl_gpio_init() returning -ENOSYS

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: default avatarFrieder Schrempf <frieder.schrempf@kontron.de>
Acked-by: default avatarUwe Kleine-Knig <u.kleine-koenig@pengutronix.de>
Link: https://lore.kernel.org/r/20190802100349.8659-4-frieder.schrempf@kontron.deSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e55a0973
......@@ -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;
}
} else {
uart->gpios = gpios;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment