Even when deferring, we would like to know what caused it.
Update dev_warn to dev_err because if the DMA init fails,
the probe is stopped.
Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
err_dma_out:
dma_release_channel(dd->src.chan);
err_dma_in:
- dev_warn(dd->dev, "no DMA channel available\n");
+ dev_err(dd->dev, "no DMA channel available\n");
return ret;
}
{
dd->dma_lch_in.chan = dma_request_chan(dd->dev, "tx");
if (IS_ERR(dd->dma_lch_in.chan)) {
- int ret = PTR_ERR(dd->dma_lch_in.chan);
-
- if (ret != -EPROBE_DEFER)
- dev_warn(dd->dev, "no DMA channel available\n");
- return ret;
+ dev_err(dd->dev, "DMA channel is not available\n");
+ return PTR_ERR(dd->dma_lch_in.chan);
}
dd->dma_lch_in.dma_conf.dst_addr = dd->phys_base +
err_dma_out:
dma_release_channel(dd->dma_lch_in.chan);
err_dma_in:
- if (ret != -EPROBE_DEFER)
- dev_warn(dd->dev, "no DMA channel available\n");
+ dev_err(dd->dev, "no DMA channel available\n");
return ret;
}