diff mbox series

[2/6] serial: 8250_bcm2835aux: Suppress clk_get error on -EPROBE_DEFER

Message ID deafc13cdfd7a31c6a81b0db95adcd3599accc26.1579175223.git.lukas@wunner.de
State New
Headers show
Series Raspberry Pi auxiliary UART fixes & cleanups | expand

Commit Message

Lukas Wunner Jan. 16, 2020, 12:14 p.m. UTC
From: Phil Elwell <phil@raspberrypi.org>

Suppress a gratuitous error message if devm_clk_get() returns
-EPROBE_DEFER.

Signed-off-by: Phil Elwell <phil@raspberrypi.org>
[lukas: extend commit message]
Signed-off-by: Lukas Wunner <lukas@wunner.de>
---
 drivers/tty/serial/8250/8250_bcm2835aux.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/tty/serial/8250/8250_bcm2835aux.c b/drivers/tty/serial/8250/8250_bcm2835aux.c
index 4997c519ebb3..33da68341c3a 100644
--- a/drivers/tty/serial/8250/8250_bcm2835aux.c
+++ b/drivers/tty/serial/8250/8250_bcm2835aux.c
@@ -50,7 +50,8 @@  static int bcm2835aux_serial_probe(struct platform_device *pdev)
 	data->clk = devm_clk_get(&pdev->dev, NULL);
 	ret = PTR_ERR_OR_ZERO(data->clk);
 	if (ret) {
-		dev_err(&pdev->dev, "could not get clk: %d\n", ret);
+		if (ret != -EPROBE_DEFER)
+			dev_err(&pdev->dev, "could not get clk: %d\n", ret);
 		return ret;
 	}