summaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/omap-serial.c
diff options
context:
space:
mode:
authorMichael Grzeschik <m.grzeschik@pengutronix.de>2014-02-13 10:52:03 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-02-13 09:57:33 -0800
commita64c1a1c755674399da3689499b3f64c2a538120 (patch)
tree2a60a02f001446d14ef8b0ad70fa093a3a4a0dc4 /drivers/tty/serial/omap-serial.c
parent13b949f03e642c5df36ebf5b4770d75f8c4a6b09 (diff)
downloadop-kernel-dev-a64c1a1c755674399da3689499b3f64c2a538120.zip
op-kernel-dev-a64c1a1c755674399da3689499b3f64c2a538120.tar.gz
serial: omap: fix rs485 probe on defered pinctrl
If the gpio is not yet available we better also defer the probing in the rs485 case. Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/omap-serial.c')
-rw-r--r--drivers/tty/serial/omap-serial.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c
index 2051581..77f0351 100644
--- a/drivers/tty/serial/omap-serial.c
+++ b/drivers/tty/serial/omap-serial.c
@@ -1601,8 +1601,11 @@ static int serial_omap_probe_rs485(struct uart_omap_port *up,
flags & SER_RS485_RTS_AFTER_SEND);
if (ret < 0)
return ret;
- } else
+ } else if (up->rts_gpio == -EPROBE_DEFER) {
+ return -EPROBE_DEFER;
+ } else {
up->rts_gpio = -EINVAL;
+ }
if (of_property_read_u32_array(np, "rs485-rts-delay",
rs485_delay, 2) == 0) {
OpenPOWER on IntegriCloud