Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1280023
| From | Tony Lindgren <tony@atomide.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel |
| Date | 2015-11-30 17:00 +0100 |
| Message-ID | <qAz1U-5xV-11@gated-at.bofh.it> (permalink) |
| References | <qAx05-4hY-3@gated-at.bofh.it> <qAx9L-4lF-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi,
* Peter Ujfalusi <peter.ujfalusi@ti.com> [151130 05:49]:
>
> For each dmaengine driver an array of DMA device, slave and the parameter
> for the filter function needs to be added:
>
> static struct dma_filter_map da830_edma_map[] = {
> DMA_FILTER_ENTRY("davinci-mcasp.0", "rx", EDMA_CTLR_CHAN(0, 0)),
> DMA_FILTER_ENTRY("davinci-mcasp.0", "tx", EDMA_CTLR_CHAN(0, 1)),
> DMA_FILTER_ENTRY("davinci-mcasp.1", "rx", EDMA_CTLR_CHAN(0, 2)),
> DMA_FILTER_ENTRY("davinci-mcasp.1", "tx", EDMA_CTLR_CHAN(0, 3)),
> DMA_FILTER_ENTRY("davinci-mcasp.2", "rx", EDMA_CTLR_CHAN(0, 4)),
> DMA_FILTER_ENTRY("davinci-mcasp.2", "tx", EDMA_CTLR_CHAN(0, 5)),
> DMA_FILTER_ENTRY("spi_davinci.0", "rx", EDMA_CTLR_CHAN(0, 14)),
> DMA_FILTER_ENTRY("spi_davinci.0", "tx", EDMA_CTLR_CHAN(0, 15)),
> DMA_FILTER_ENTRY("da830-mmc.0", "rx", EDMA_CTLR_CHAN(0, 16)),
> DMA_FILTER_ENTRY("da830-mmc.0", "tx", EDMA_CTLR_CHAN(0, 17)),
> DMA_FILTER_ENTRY("spi_davinci.1", "rx", EDMA_CTLR_CHAN(0, 18)),
> DMA_FILTER_ENTRY("spi_davinci.1", "tx", EDMA_CTLR_CHAN(0, 19)),
> };
FYI, if the EDMA_CTRL_CHAN above is just the evtmux registers, those
can be handled with the pinctrl framework. It seems that would allow
leaving out some of the built-in look up data, and have the mux parts
handled by a proper device driver. Below is a sample from the dm81xx
platform for reference.
SoC dtsi file:
evtmux: pinmux@f90 {
compatible = "pinctrl-single";
reg = <0xf90 0x40>;
#address-cells = <1>;
#size-cells = <0>;
pinctrl-single,register-width = <8>;
pinctrl-single,function-mask = <0x1f>;
};
Board specific dts file:
&evtmux {
sd2_edma_pins: pinmux_sd2_edma_pins {
pinctrl-single,pins = <
8 1 /* use SDTXEVT1 for EDMA instead of MCASP0TX */
9 2 /* use SDRXEVT1 for EDMA instead of MCASP0RX */
>;
};
};
Dynamic muxing of these channels can be done too using the pinctrl
framework named modes, but probably is not a good idea in the case of
SD card and MaASP in case something goes wrong :)
Regards,
Tony
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-11-30 15:00 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Arnd Bergmann <arnd@arndb.de> - 2015-11-30 15:20 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-12-01 10:50 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Andy Shevchenko <andy.shevchenko@gmail.com> - 2015-11-30 16:00 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-12-01 11:00 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Andy Shevchenko <andy.shevchenko@gmail.com> - 2015-12-01 11:10 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Tony Lindgren <tony@atomide.com> - 2015-11-30 17:00 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-12-01 09:20 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Tony Lindgren <tony@atomide.com> - 2015-12-01 18:10 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Peter Ujfalusi <peter.ujfalusi@ti.com> - 2015-12-02 11:10 +0100
Re: [RFC v02 03/15] dmaengine: core: Introduce new, universal API to request a channel Tony Lindgren <tony@atomide.com> - 2015-12-02 16:10 +0100
csiph-web