[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZMLcefaxpRVgkPyd@surfacebook>
Date: Fri, 28 Jul 2023 00:07:05 +0300
From: andy.shevchenko@...il.com
To: Minjie Du <duminjie@...o.com>
Cc: Vladimir Oltean <olteanv@...il.com>,
Mark Brown <broonie@...nel.org>,
Richard Cochran <richardcochran@...il.com>,
"open list:FREESCALE DSPI DRIVER" <linux-spi@...r.kernel.org>,
open list <linux-kernel@...r.kernel.org>,
"open list:PTP HARDWARE CLOCK SUPPORT" <netdev@...r.kernel.org>,
opensource.kernel@...o.com
Subject: Re: [PATCH v2] spi: fsl-dspi: Use dev_err_probe() in
dspi_request_dma()
Tue, Jul 25, 2023 at 11:50:37AM +0800, Minjie Du kirjoitti:
> It is possible for dma_request_chan() to return EPROBE_DEFER, which means
> dev is not ready yet.
> At this point dev_err() will have no output.
...
> if (IS_ERR(dma->chan_tx)) {
> - dev_err(dev, "tx dma channel not available\n");
> ret = PTR_ERR(dma->chan_tx);
> + dev_err_probe(dev, ret, "tx dma channel not available\n");
It can be even simpler
ret = dev_err_probe(dev, PTR_ERR(dma->chan_tx), "tx dma channel not available\n");
> goto err_tx_channel;
> }
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists