Skip to content

Commit

Permalink
spi: spi-cadence-quadspi: Return EPROBE_DEFER on dma failure
Browse files Browse the repository at this point in the history
Depending on the probing order of dma vs ospi, dma failure is seen when
ospi controller probes first and checks for available dma channel and
fails. This patch fixes it by sending EPROBE_DEFER, which helps acquire
dma channel after the dma controller probes.

Signed-off-by: Prasanth Babu Mantena <p-mantena@ti.com>
Signed-off-by: Santhosh Kumar K <s-k6@ti.com>
  • Loading branch information
p-mantena authored and Santhosh Kumar K committed Oct 23, 2024
1 parent d5b2382 commit 72f43f1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/spi/spi-cadence-quadspi.c
Original file line number Diff line number Diff line change
Expand Up @@ -2455,7 +2455,7 @@ static int cqspi_request_mmap_dma(struct cqspi_st *cqspi)

cqspi->rx_chan = dma_request_chan_by_mask(&mask);
if (IS_ERR(cqspi->rx_chan)) {
int ret = PTR_ERR(cqspi->rx_chan);
int ret = (-EPROBE_DEFER);

cqspi->rx_chan = NULL;
return dev_err_probe(&cqspi->pdev->dev, ret, "No Rx DMA available\n");
Expand Down

0 comments on commit 72f43f1

Please sign in to comment.