diff mbox series

media: stm32-dcmi: don't print an error on probe deferral

Message ID 1602086530-24646-1-git-send-email-hugues.fruchet@st.com (mailing list archive)
State New, archived
Headers show
Series media: stm32-dcmi: don't print an error on probe deferral | expand

Commit Message

Hugues FRUCHET Oct. 7, 2020, 4:02 p.m. UTC
From: Etienne Carriere <etienne.carriere@st.com>

Change stm32-dcmi driver to not print an error message when the
device probe operation is deferred.

Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
Acked-by: Hugues Fruchet <hugues.fruchet@st.com>
Tested-by: Alexandre TORGUE <alexandre.torgue@st.com>
---
 drivers/media/platform/stm32/stm32-dcmi.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/media/platform/stm32/stm32-dcmi.c b/drivers/media/platform/stm32/stm32-dcmi.c
index fd1c41c..720534e 100644
--- a/drivers/media/platform/stm32/stm32-dcmi.c
+++ b/drivers/media/platform/stm32/stm32-dcmi.c
@@ -1851,7 +1851,9 @@  static int dcmi_probe(struct platform_device *pdev)
 
 	dcmi->rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL);
 	if (IS_ERR(dcmi->rstc)) {
-		dev_err(&pdev->dev, "Could not get reset control\n");
+		if (PTR_ERR(dcmi->rstc) != -EPROBE_DEFER)
+			dev_err(&pdev->dev, "Could not get reset control\n");
+
 		return PTR_ERR(dcmi->rstc);
 	}