Skip to content

Commit e9ce6ae

Browse files
ambarusherbertx
authored andcommitted
crypto: atmel-{sha,tdes} - Print warn message even when deferring
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 <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
1 parent 827a98d commit e9ce6ae

File tree

3 files changed

+4
-8
lines changed

3 files changed

+4
-8
lines changed

drivers/crypto/atmel-aes.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2292,7 +2292,7 @@ static int atmel_aes_dma_init(struct atmel_aes_dev *dd)
22922292
err_dma_out:
22932293
dma_release_channel(dd->src.chan);
22942294
err_dma_in:
2295-
dev_warn(dd->dev, "no DMA channel available\n");
2295+
dev_err(dd->dev, "no DMA channel available\n");
22962296
return ret;
22972297
}
22982298

drivers/crypto/atmel-sha.c

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2485,11 +2485,8 @@ static int atmel_sha_dma_init(struct atmel_sha_dev *dd)
24852485
{
24862486
dd->dma_lch_in.chan = dma_request_chan(dd->dev, "tx");
24872487
if (IS_ERR(dd->dma_lch_in.chan)) {
2488-
int ret = PTR_ERR(dd->dma_lch_in.chan);
2489-
2490-
if (ret != -EPROBE_DEFER)
2491-
dev_warn(dd->dev, "no DMA channel available\n");
2492-
return ret;
2488+
dev_err(dd->dev, "DMA channel is not available\n");
2489+
return PTR_ERR(dd->dma_lch_in.chan);
24932490
}
24942491

24952492
dd->dma_lch_in.dma_conf.dst_addr = dd->phys_base +

drivers/crypto/atmel-tdes.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -783,8 +783,7 @@ static int atmel_tdes_dma_init(struct atmel_tdes_dev *dd)
783783
err_dma_out:
784784
dma_release_channel(dd->dma_lch_in.chan);
785785
err_dma_in:
786-
if (ret != -EPROBE_DEFER)
787-
dev_warn(dd->dev, "no DMA channel available\n");
786+
dev_err(dd->dev, "no DMA channel available\n");
788787
return ret;
789788
}
790789

0 commit comments

Comments
 (0)