From: Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
To: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
nicolas.ferre-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org
Subject: Re: [PATCH] i2c: at91: introduce probe deferring
Date: Fri, 21 Nov 2014 08:02:21 +0100 [thread overview]
Message-ID: <20141121070221.GE1480@katana> (raw)
In-Reply-To: <20141119101403.GE3639@ldesroches-Latitude-E6320>
[-- Attachment #1: Type: text/plain, Size: 2543 bytes --]
On Wed, Nov 19, 2014 at 11:14:03AM +0100, Ludovic Desroches wrote:
> On Wed, Nov 19, 2014 at 10:47:15AM +0100, Arnd Bergmann wrote:
> > On Wednesday 19 November 2014 10:16:47 Wolfram Sang wrote:
> > > On Fri, Nov 14, 2014 at 02:47:59PM +0100, Ludovic Desroches wrote:
> > > > Return probe defer if requesting a dma channel without a dma controller probed.
> > > >
> > > > Signed-off-by: Ludovic Desroches <ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
> > > > ---
> > > > drivers/i2c/busses/i2c-at91.c | 22 ++++++++++++++++------
> > > > 1 file changed, 16 insertions(+), 6 deletions(-)
> > > >
> > > > diff --git a/drivers/i2c/busses/i2c-at91.c b/drivers/i2c/busses/i2c-at91.c
> > > > index 77fb647..df3f4c4 100644
> > > > --- a/drivers/i2c/busses/i2c-at91.c
> > > > +++ b/drivers/i2c/busses/i2c-at91.c
> > > > @@ -679,14 +679,21 @@ static int at91_twi_configure_dma(struct at91_twi_dev *dev, u32 phy_addr)
> > > > dma_cap_zero(mask);
> > > > dma_cap_set(DMA_SLAVE, mask);
> > > >
> > > > - dma->chan_tx = dma_request_slave_channel_compat(mask, filter, pdata,
> > > > - dev->dev, "tx");
> > > > - if (!dma->chan_tx) {
> > > > + dma->chan_tx = dma_request_slave_channel_reason(dev->dev, "tx");
> > >
> > > Will it cause regressions if you drop the compat-version of requesting
> > > a channel?
> >
> > I got curious about this, since the patch looks obviously wrong, but
> > actually it's ok. However the entire DMA support for non-DT platforms
> > can be dropped in this driver, see patch below
> >
> > > > + if (IS_ERR(dma->chan_tx)) {
> > > > + ret = PTR_ERR(dma->chan_tx);
> > > > + if (ret == -EPROBE_DEFER) {
> > > > + dev_warn(dev->dev, "no DMA channel available at the moment\n");
> > >
> > > I'd say drop this warning. The core usually prints when deferred probing
> > > takes place.
> >
> > Definitely yes.
> >
> > Arnd
> > 8<---
> > [PATCH] i2c: at91: remove legacy DMA supoprt
> >
> > Since at91sam9g45 is now DT-only, all DMA capable users of this driver are
> > using the DT case, and the legacy support can be removed. While at it, fix
> > the deferred probe case.
> >
> > Signed-off-by: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>
Thanks for this cleanup, yet I'd really appreciate a build test at
least.
> Acked-by: Ludovic Desroches <ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
From you, I had even hoped for a quick runtime test. Would that be
possible for future patches?
Thanks,
Wolfram
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2014-11-21 7:02 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-14 13:47 [PATCH] i2c: at91: introduce probe deferring Ludovic Desroches
[not found] ` <1415972879-26509-1-git-send-email-ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
2014-11-19 9:16 ` Wolfram Sang
2014-11-19 9:47 ` Arnd Bergmann
2014-11-19 10:14 ` Ludovic Desroches
2014-11-21 7:02 ` Wolfram Sang [this message]
2014-11-19 9:55 ` Ludovic Desroches
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141121070221.GE1480@katana \
--to=wsa-z923lk4zbo2bacvfa/9k2g@public.gmane.org \
--cc=arnd-r2nGTMty4D4@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org \
--cc=nicolas.ferre-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).