Skip to contentSkip to conversation

media: rcar_drif: Do not print error in case of EPROBE_DEFER for dma channel

PATCH New Peter Ujfalusi 1 participant 1 message Feb 26, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 media: rcar_drif: Do not print error in case of EPROBE_DEFER for dma channel

If the dma channel request error code is EPROBE_DEFER there is no need to print error message.

---
Hi Hans,

the patch updates the v1 "media: rcar_drif: Use dma_request_chan() instead dma_request_slave_channel()" which got applied to the v3 state.

I have not added the fixes line, but if you think the hash is not going to change, you can copy this line:

Fixes 1b5482e0d268 ("media: rcar_drif: Use dma_request_chan() instead dma_request_slave_channel()")

Regards,
Peter

 drivers/media/platform/rcar_drif.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/media/platform/rcar_drif.c +5 -1
index 02ee0e2a09e9..3d2451ac347d 100644
@@ -277,8 +277,12 @@ static int rcar_drif_alloc_dmachannels(struct rcar_drif_sdr *sdr)
 
 		ch->dmach = dma_request_chan(&ch->pdev->dev, "rx");
 		if (IS_ERR(ch->dmach)) {
-			rdrif_err(sdr, "ch%u: dma channel req failed\n", i);
 			ret = PTR_ERR(ch->dmach);
+			if (ret != -EPROBE_DEFER)
+				rdrif_err(sdr,
+					  "ch%u: dma channel req failed: %pe\n",
+					  i, ch->dmach);
+			ch->dmach = NULL;
 			goto dmach_error;
 		}
 
Signature · 4 lines
Peter

Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki