From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: "Måns Rullgård" <mans@mansr.com>
Cc: Tejun Heo <tj@kernel.org>,
linux-ide@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
Benjamin Herrenschmidt <benh@kernel.crashing.org>,
rsarmah@amcc.com, Alexey Brodkin <Alexey.Brodkin@synopsys.com>
Subject: Re: [PATCH v1 1/2] sata_dwc_460ex: move to generic DMA driver
Date: Mon, 23 Nov 2015 12:10:41 +0200 [thread overview]
Message-ID: <1448273441.31665.186.camel@linux.intel.com> (raw)
In-Reply-To: <yw1xwptab2zs.fsf@unicorn.mansr.com>
On Sun, 2015-11-22 at 13:03 +0000, Måns Rullgård wrote:
> Andy Shevchenko <andriy.shevchenko@linux.intel.com> writes:
>
> > The SATA implementation based on two actually different devices,
> > i.e. SATA and
> > DMA controllers.
> >
> > For Synopsys DesignWare DMA we have already a generic
> > implementation of the
> > driver. Thus, the patch converts the code to use DMAEngine
> > framework and
> > dw_dmac driver.
> >
> > In future it will be better to split the devices inside DTS as well
> > like it's
> > done on other platforms.
> > @@ -1721,16 +1227,16 @@ static int sata_dwc_probe(struct
> > platform_device *ofdev)
> > idr, ver[0], ver[1], ver[2]);
> >
> > /* Get SATA DMA interrupt number */
> > - irq = irq_of_parse_and_map(np, 1);
> > - if (irq == NO_IRQ) {
> > + hsdev->dma->irq = irq_of_parse_and_map(np, 1);
>
> This doesn't look like it has been more than compile-tested.
Yes, that's true, my question [1] was a crying in the wilderness.
> Nothing
> ever allocates hsdev->dma, so it can't possibly work.
You are right.
>
> Also, has anyone given any thought to getting rid of the dependency
> on
> the DW DMA controller?
How? Before it was even more harder link to it (embedded routines).
On the other hand you may introduce dma_ops and use them like it's
done, for example, in spi-dw*.c
> Presumably support for old device trees would
> need to be retained for compatibility. Maybe checking for a "dmas"
> property and falling back on the current behaviour if it's missing.
I didn't get how DT is related to DW or any other DMAC used with this
SATA controller.
> My
> goal is to get this driver working with another chip using the same
> SATA
> controller but a different DMA engine.
It would be nice to eventually bring this working with generic DMA
Engine API. Please, keep me in Cc list regarding this driver.
[1] https://lkml.org/lkml/2014/12/12/547
--
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy
next prev parent reply other threads:[~2015-11-23 10:10 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-03 20:41 [PATCH v1 0/2] sata_dwc_460ex: move to generic DMA driver Andy Shevchenko
2015-03-03 20:41 ` [PATCH v1 1/2] " Andy Shevchenko
2015-11-22 13:03 ` Måns Rullgård
2015-11-22 13:03 ` Måns Rullgård
2015-11-23 10:10 ` Andy Shevchenko [this message]
2015-11-23 11:58 ` Måns Rullgård
2015-11-23 11:58 ` Måns Rullgård
2015-03-03 20:41 ` [PATCH v1 2/2] sata_dwc_460ex: re-use hsdev->dev instead of dwc_dev Andy Shevchenko
2015-03-24 17:51 ` Tejun Heo
2015-03-24 17:51 ` Tejun Heo
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=1448273441.31665.186.camel@linux.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=Alexey.Brodkin@synopsys.com \
--cc=benh@kernel.crashing.org \
--cc=linux-ide@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mans@mansr.com \
--cc=rsarmah@amcc.com \
--cc=tj@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.