* [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks
2014-06-02 13:40 [PATCH 0/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
@ 2014-06-02 13:40 ` Geert Uytterhoeven
2014-06-02 18:13 ` Sergei Shtylyov
2014-06-02 13:40 ` [PATCH 2/4] ARM: shmobile: r8a7791: Add SYS-DMAC support Geert Uytterhoeven
` (3 subsequent siblings)
4 siblings, 1 reply; 9+ messages in thread
From: Geert Uytterhoeven @ 2014-06-02 13:40 UTC (permalink / raw)
To: linux-arm-kernel
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
arch/arm/mach-shmobile/clock-r8a7791.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-shmobile/clock-r8a7791.c b/arch/arm/mach-shmobile/clock-r8a7791.c
index e2fdfcc14436..b0b2294513e2 100644
--- a/arch/arm/mach-shmobile/clock-r8a7791.c
+++ b/arch/arm/mach-shmobile/clock-r8a7791.c
@@ -178,7 +178,7 @@ enum {
MSTP719, MSTP718, MSTP715, MSTP714,
MSTP522,
MSTP314, MSTP312, MSTP311,
- MSTP216, MSTP207, MSTP206,
+ MSTP219, MSTP218, MSTP216, MSTP207, MSTP206,
MSTP204, MSTP203, MSTP202,
MSTP124,
MSTP_NR
@@ -215,6 +215,8 @@ static struct clk mstp_clks[MSTP_NR] = {
[MSTP312] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD1], SMSTPCR3, 12, MSTPSR3, 0), /* SDHI1 */
[MSTP311] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD2], SMSTPCR3, 11, MSTPSR3, 0), /* SDHI2 */
[MSTP216] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 16, MSTPSR2, 0), /* SCIFB2 */
+ [MSTP219] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 19, MSTPSR2, 0), /* SYS-DMAC0 */
+ [MSTP218] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 18, MSTPSR2, 0), /* SYS-DMAC1 */
[MSTP207] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 7, MSTPSR2, 0), /* SCIFB1 */
[MSTP206] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 6, MSTPSR2, 0), /* SCIFB0 */
[MSTP204] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 4, MSTPSR2, 0), /* SCIFA0 */
@@ -267,6 +269,8 @@ static struct clk_lookup lookups[] = {
CLKDEV_ICK_ID("fck", "sh-cmt-48-gen2.0", &mstp_clks[MSTP124]),
CLKDEV_DEV_ID("qspi.0", &mstp_clks[MSTP917]),
CLKDEV_DEV_ID("rcar_thermal", &mstp_clks[MSTP522]),
+ CLKDEV_DEV_ID("sh-dma-engine.0", &mstp_clks[MSTP219]),
+ CLKDEV_DEV_ID("sh-dma-engine.1", &mstp_clks[MSTP218]),
CLKDEV_DEV_ID("i2c-rcar_gen2.0", &mstp_clks[MSTP931]),
CLKDEV_DEV_ID("i2c-rcar_gen2.1", &mstp_clks[MSTP930]),
CLKDEV_DEV_ID("i2c-rcar_gen2.2", &mstp_clks[MSTP929]),
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks
2014-06-02 13:40 ` [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks Geert Uytterhoeven
@ 2014-06-02 18:13 ` Sergei Shtylyov
2014-06-03 7:04 ` Geert Uytterhoeven
0 siblings, 1 reply; 9+ messages in thread
From: Sergei Shtylyov @ 2014-06-02 18:13 UTC (permalink / raw)
To: linux-arm-kernel
Hello.
On 06/02/2014 05:40 PM, Geert Uytterhoeven wrote:
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
> ---
> arch/arm/mach-shmobile/clock-r8a7791.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
> diff --git a/arch/arm/mach-shmobile/clock-r8a7791.c b/arch/arm/mach-shmobile/clock-r8a7791.c
> index e2fdfcc14436..b0b2294513e2 100644
> --- a/arch/arm/mach-shmobile/clock-r8a7791.c
> +++ b/arch/arm/mach-shmobile/clock-r8a7791.c
> @@ -178,7 +178,7 @@ enum {
> MSTP719, MSTP718, MSTP715, MSTP714,
> MSTP522,
> MSTP314, MSTP312, MSTP311,
> - MSTP216, MSTP207, MSTP206,
> + MSTP219, MSTP218, MSTP216, MSTP207, MSTP206,
I'd put the latter two on a separate line or on the same line with the
following three.
> MSTP204, MSTP203, MSTP202,
> MSTP124,
> MSTP_NR
> @@ -215,6 +215,8 @@ static struct clk mstp_clks[MSTP_NR] = {
> [MSTP312] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD1], SMSTPCR3, 12, MSTPSR3, 0), /* SDHI1 */
> [MSTP311] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD2], SMSTPCR3, 11, MSTPSR3, 0), /* SDHI2 */
> [MSTP216] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 16, MSTPSR2, 0), /* SCIFB2 */
> + [MSTP219] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 19, MSTPSR2, 0), /* SYS-DMAC0 */
> + [MSTP218] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 18, MSTPSR2, 0), /* SYS-DMAC1 */
I think these 2 clocks should precede SCIFB2 clock.
> [MSTP207] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 7, MSTPSR2, 0), /* SCIFB1 */
> [MSTP206] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 6, MSTPSR2, 0), /* SCIFB0 */
> [MSTP204] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 4, MSTPSR2, 0), /* SCIFA0 */
WBR, Sergei
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks
2014-06-02 18:13 ` Sergei Shtylyov
@ 2014-06-03 7:04 ` Geert Uytterhoeven
2014-06-03 23:26 ` Simon Horman
0 siblings, 1 reply; 9+ messages in thread
From: Geert Uytterhoeven @ 2014-06-03 7:04 UTC (permalink / raw)
To: linux-arm-kernel
Hi Sergei,
On Mon, Jun 2, 2014 at 8:13 PM, Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
>> diff --git a/arch/arm/mach-shmobile/clock-r8a7791.c
>> b/arch/arm/mach-shmobile/clock-r8a7791.c
>> index e2fdfcc14436..b0b2294513e2 100644
>> --- a/arch/arm/mach-shmobile/clock-r8a7791.c
>> +++ b/arch/arm/mach-shmobile/clock-r8a7791.c
>> @@ -178,7 +178,7 @@ enum {
>> MSTP719, MSTP718, MSTP715, MSTP714,
>> MSTP522,
>> MSTP314, MSTP312, MSTP311,
>> - MSTP216, MSTP207, MSTP206,
>> + MSTP219, MSTP218, MSTP216, MSTP207, MSTP206,
>
> I'd put the latter two on a separate line or on the same line with the
> following three.
>
>> MSTP204, MSTP203, MSTP202,
>> MSTP124,
>> MSTP_NR
>> @@ -215,6 +215,8 @@ static struct clk mstp_clks[MSTP_NR] = {
>> [MSTP312] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD1], SMSTPCR3, 12,
>> MSTPSR3, 0), /* SDHI1 */
>> [MSTP311] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD2], SMSTPCR3, 11,
>> MSTPSR3, 0), /* SDHI2 */
>> [MSTP216] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 16, MSTPSR2, 0),
>> /* SCIFB2 */
>> + [MSTP219] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 19, MSTPSR2, 0),
>> /* SYS-DMAC0 */
>> + [MSTP218] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 18, MSTPSR2, 0),
>> /* SYS-DMAC1 */
>
> I think these 2 clocks should precede SCIFB2 clock.
>
>> [MSTP207] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 7, MSTPSR2, 0),
>> /* SCIFB1 */
>> [MSTP206] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 6, MSTPSR2, 0),
>> /* SCIFB0 */
>> [MSTP204] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 4, MSTPSR2, 0),
>> /* SCIFA0 */
My local patches still have the MSIOF entries as well. Unfortunately MSTP
values are not always contiguous (MSIOF, SYS-DMAC, and SCIF are mixed).
So this is the end result of rebasing that on top of Simon's current tree.
Anyway, I think the legacy series is mostly posted for reference, as I'm
under the impression Simon will no longer apply patches adding features
to the legacy code. Simon, is that correct?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks
2014-06-03 7:04 ` Geert Uytterhoeven
@ 2014-06-03 23:26 ` Simon Horman
0 siblings, 0 replies; 9+ messages in thread
From: Simon Horman @ 2014-06-03 23:26 UTC (permalink / raw)
To: linux-arm-kernel
On Tue, Jun 03, 2014 at 09:04:01AM +0200, Geert Uytterhoeven wrote:
> Hi Sergei,
>
> On Mon, Jun 2, 2014 at 8:13 PM, Sergei Shtylyov
> <sergei.shtylyov@cogentembedded.com> wrote:
> >> diff --git a/arch/arm/mach-shmobile/clock-r8a7791.c
> >> b/arch/arm/mach-shmobile/clock-r8a7791.c
> >> index e2fdfcc14436..b0b2294513e2 100644
> >> --- a/arch/arm/mach-shmobile/clock-r8a7791.c
> >> +++ b/arch/arm/mach-shmobile/clock-r8a7791.c
> >> @@ -178,7 +178,7 @@ enum {
> >> MSTP719, MSTP718, MSTP715, MSTP714,
> >> MSTP522,
> >> MSTP314, MSTP312, MSTP311,
> >> - MSTP216, MSTP207, MSTP206,
> >> + MSTP219, MSTP218, MSTP216, MSTP207, MSTP206,
> >
> > I'd put the latter two on a separate line or on the same line with the
> > following three.
> >
> >> MSTP204, MSTP203, MSTP202,
> >> MSTP124,
> >> MSTP_NR
> >> @@ -215,6 +215,8 @@ static struct clk mstp_clks[MSTP_NR] = {
> >> [MSTP312] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD1], SMSTPCR3, 12,
> >> MSTPSR3, 0), /* SDHI1 */
> >> [MSTP311] = SH_CLK_MSTP32_STS(&div6_clks[DIV6_SD2], SMSTPCR3, 11,
> >> MSTPSR3, 0), /* SDHI2 */
> >> [MSTP216] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 16, MSTPSR2, 0),
> >> /* SCIFB2 */
> >> + [MSTP219] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 19, MSTPSR2, 0),
> >> /* SYS-DMAC0 */
> >> + [MSTP218] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 18, MSTPSR2, 0),
> >> /* SYS-DMAC1 */
> >
> > I think these 2 clocks should precede SCIFB2 clock.
> >
> >> [MSTP207] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 7, MSTPSR2, 0),
> >> /* SCIFB1 */
> >> [MSTP206] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 6, MSTPSR2, 0),
> >> /* SCIFB0 */
> >> [MSTP204] = SH_CLK_MSTP32_STS(&mp_clk, SMSTPCR2, 4, MSTPSR2, 0),
> >> /* SCIFA0 */
>
> My local patches still have the MSIOF entries as well. Unfortunately MSTP
> values are not always contiguous (MSIOF, SYS-DMAC, and SCIF are mixed).
> So this is the end result of rebasing that on top of Simon's current tree.
>
> Anyway, I think the legacy series is mostly posted for reference, as I'm
> under the impression Simon will no longer apply patches adding features
> to the legacy code. Simon, is that correct?
Yes, that is correct.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 2/4] ARM: shmobile: r8a7791: Add SYS-DMAC support
2014-06-02 13:40 [PATCH 0/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
2014-06-02 13:40 ` [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks Geert Uytterhoeven
@ 2014-06-02 13:40 ` Geert Uytterhoeven
2014-06-02 13:40 ` [PATCH 3/4] ARM: shmobile: r8a7791: Add QSPI DMA support Geert Uytterhoeven
` (2 subsequent siblings)
4 siblings, 0 replies; 9+ messages in thread
From: Geert Uytterhoeven @ 2014-06-02 13:40 UTC (permalink / raw)
To: linux-arm-kernel
From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
This patch enables SYS-DMAC0 (= Low), it doesn't support
SYS-DMAC1 (= HI) today.
Because, SYS-DMAC HI/Low interrupt mapping is not
good match to SH-DMAC driver.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
[Geert: Rebased]
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
arch/arm/mach-shmobile/include/mach/r8a7791.h | 5 ++
arch/arm/mach-shmobile/setup-r8a7791.c | 81 +++++++++++++++++++++++++++
2 files changed, 86 insertions(+)
diff --git a/arch/arm/mach-shmobile/include/mach/r8a7791.h b/arch/arm/mach-shmobile/include/mach/r8a7791.h
index 86eae7bceb6f..533999916e73 100644
--- a/arch/arm/mach-shmobile/include/mach/r8a7791.h
+++ b/arch/arm/mach-shmobile/include/mach/r8a7791.h
@@ -1,6 +1,11 @@
#ifndef __ASM_R8A7791_H__
#define __ASM_R8A7791_H__
+/* DMA slave IDs */
+enum {
+ RCAR_DMA_SLAVE_INVALID,
+};
+
void r8a7791_add_standard_devices(void);
void r8a7791_add_dt_devices(void);
void r8a7791_clock_init(void);
diff --git a/arch/arm/mach-shmobile/setup-r8a7791.c b/arch/arm/mach-shmobile/setup-r8a7791.c
index 04a96ddb3224..77e1bc2b2870 100644
--- a/arch/arm/mach-shmobile/setup-r8a7791.c
+++ b/arch/arm/mach-shmobile/setup-r8a7791.c
@@ -25,13 +25,93 @@
#include <linux/platform_data/gpio-rcar.h>
#include <linux/platform_data/irq-renesas-irqc.h>
#include <linux/serial_sci.h>
+#include <linux/sh_dma.h>
#include <linux/sh_timer.h>
#include <mach/common.h>
+#include <mach/dma-register.h>
#include <mach/irqs.h>
#include <mach/r8a7791.h>
#include <mach/rcar-gen2.h>
#include <asm/mach/arch.h>
+#define DMAE_CHANNEL(a, b) \
+{ \
+ .offset = (a) - 0x20, \
+ .dmars = (a) - 0x20 + 0x40, \
+ .chclr_bit = (b), \
+ .chclr_offset = 0x80 - 0x20, \
+}
+
+/* Sys-DMAC */
+#define SYS_DMAC_SLAVE(_id, _bit, _addr, toffset, roffset, t, r)\
+{ \
+ .slave_id = SYS_DMAC_SLAVE_## _id ##_TX, \
+ .addr = _addr + toffset, \
+ .chcr = CHCR_TX(XMIT_SZ_## _bit ##BIT), \
+ .mid_rid = t, \
+}, { \
+ .slave_id = SYS_DMAC_SLAVE_## _id ##_RX, \
+ .addr = _addr + roffset, \
+ .chcr = CHCR_RX(XMIT_SZ_## _bit ##BIT), \
+ .mid_rid = r, \
+}
+
+static const struct sh_dmae_slave_config r8a7791_sys_dmac_slaves[] = {
+};
+
+static const struct sh_dmae_channel r8a7791_sys_dmac_channels[] = {
+ DMAE_CHANNEL(0x8000, 0),
+ DMAE_CHANNEL(0x8080, 1),
+ DMAE_CHANNEL(0x8100, 2),
+ DMAE_CHANNEL(0x8180, 3),
+ DMAE_CHANNEL(0x8200, 4),
+ DMAE_CHANNEL(0x8280, 5),
+ DMAE_CHANNEL(0x8300, 6),
+ DMAE_CHANNEL(0x8380, 7),
+ DMAE_CHANNEL(0x8400, 8),
+ DMAE_CHANNEL(0x8480, 9),
+ DMAE_CHANNEL(0x8500, 10),
+ DMAE_CHANNEL(0x8580, 11),
+ DMAE_CHANNEL(0x8600, 12),
+ DMAE_CHANNEL(0x8680, 13),
+ DMAE_CHANNEL(0x8700, 14),
+};
+
+static struct sh_dmae_pdata r8a7791_sys_dmac_platform_data = {
+ .slave = r8a7791_sys_dmac_slaves,
+ .slave_num = ARRAY_SIZE(r8a7791_sys_dmac_slaves),
+ .channel = r8a7791_sys_dmac_channels,
+ .channel_num = ARRAY_SIZE(r8a7791_sys_dmac_channels),
+ .ts_low_shift = TS_LOW_SHIFT,
+ .ts_low_mask = TS_LOW_BIT << TS_LOW_SHIFT,
+ .ts_high_shift = TS_HI_SHIFT,
+ .ts_high_mask = TS_HI_BIT << TS_HI_SHIFT,
+ .ts_shift = dma_ts_shift,
+ .ts_shift_num = ARRAY_SIZE(dma_ts_shift),
+ .dmaor_init = DMAOR_DME,
+ .chclr_present = 1,
+ .chclr_bitwise = 1,
+};
+
+static struct resource r8a7791_sys_dmac_resources[] = {
+ /* Channel registers and DMAOR for low */
+ DEFINE_RES_MEM(0xe6700020, 0x8763 - 0x20),
+ DEFINE_RES_IRQ(gic_spi(197)),
+ DEFINE_RES_NAMED(gic_spi(200), 15, NULL, IORESOURCE_IRQ),
+
+ /*
+ * HI is not supported
+ * since IRQ has strange mapping
+ */
+};
+
+#define r8a7791_register_sys_dmac(id) \
+ platform_device_register_resndata( \
+ &platform_bus, "sh-dma-engine", id, \
+ &r8a7791_sys_dmac_resources[id * 3], 3, \
+ &r8a7791_sys_dmac_platform_data, \
+ sizeof(r8a7791_sys_dmac_platform_data))
+
static const struct resource pfc_resources[] __initconst = {
DEFINE_RES_MEM(0xe6060000, 0x250),
};
@@ -205,6 +285,7 @@ void __init r8a7791_add_standard_devices(void)
r8a7791_add_dt_devices();
r8a7791_register_irqc(0);
r8a7791_register_thermal();
+ r8a7791_register_sys_dmac(0);
}
#ifdef CONFIG_USE_OF
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 3/4] ARM: shmobile: r8a7791: Add QSPI DMA support
2014-06-02 13:40 [PATCH 0/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
2014-06-02 13:40 ` [PATCH 1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks Geert Uytterhoeven
2014-06-02 13:40 ` [PATCH 2/4] ARM: shmobile: r8a7791: Add SYS-DMAC support Geert Uytterhoeven
@ 2014-06-02 13:40 ` Geert Uytterhoeven
2014-06-02 13:40 ` [PATCH 4/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
2014-06-03 4:29 ` [PATCH 0/4] " Khiem Nguyen
4 siblings, 0 replies; 9+ messages in thread
From: Geert Uytterhoeven @ 2014-06-02 13:40 UTC (permalink / raw)
To: linux-arm-kernel
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
arch/arm/mach-shmobile/include/mach/r8a7791.h | 2 ++
arch/arm/mach-shmobile/setup-r8a7791.c | 1 +
2 files changed, 3 insertions(+)
diff --git a/arch/arm/mach-shmobile/include/mach/r8a7791.h b/arch/arm/mach-shmobile/include/mach/r8a7791.h
index 533999916e73..c4582df76139 100644
--- a/arch/arm/mach-shmobile/include/mach/r8a7791.h
+++ b/arch/arm/mach-shmobile/include/mach/r8a7791.h
@@ -4,6 +4,8 @@
/* DMA slave IDs */
enum {
RCAR_DMA_SLAVE_INVALID,
+ SYS_DMAC_SLAVE_QSPI_TX,
+ SYS_DMAC_SLAVE_QSPI_RX,
};
void r8a7791_add_standard_devices(void);
diff --git a/arch/arm/mach-shmobile/setup-r8a7791.c b/arch/arm/mach-shmobile/setup-r8a7791.c
index 77e1bc2b2870..8dbdb17ffe51 100644
--- a/arch/arm/mach-shmobile/setup-r8a7791.c
+++ b/arch/arm/mach-shmobile/setup-r8a7791.c
@@ -57,6 +57,7 @@
}
static const struct sh_dmae_slave_config r8a7791_sys_dmac_slaves[] = {
+ SYS_DMAC_SLAVE(QSPI, 8, 0xe6b10000, 0x04, 0x04, 0x17, 0x18),
};
static const struct sh_dmae_channel r8a7791_sys_dmac_channels[] = {
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 4/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI
2014-06-02 13:40 [PATCH 0/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
` (2 preceding siblings ...)
2014-06-02 13:40 ` [PATCH 3/4] ARM: shmobile: r8a7791: Add QSPI DMA support Geert Uytterhoeven
@ 2014-06-02 13:40 ` Geert Uytterhoeven
2014-06-03 4:29 ` [PATCH 0/4] " Khiem Nguyen
4 siblings, 0 replies; 9+ messages in thread
From: Geert Uytterhoeven @ 2014-06-02 13:40 UTC (permalink / raw)
To: linux-arm-kernel
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
arch/arm/mach-shmobile/board-koelsch.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm/mach-shmobile/board-koelsch.c b/arch/arm/mach-shmobile/board-koelsch.c
index c6c68892caa3..171ce3ea162a 100644
--- a/arch/arm/mach-shmobile/board-koelsch.c
+++ b/arch/arm/mach-shmobile/board-koelsch.c
@@ -182,6 +182,8 @@ static const struct resource qspi_resources[] __initconst = {
static const struct rspi_plat_data qspi_pdata __initconst = {
.num_chipselect = 1,
+ .dma_tx_id = SYS_DMAC_SLAVE_QSPI_TX,
+ .dma_rx_id = SYS_DMAC_SLAVE_QSPI_RX,
};
/* SPI Flash memory (Spansion S25FL512SAGMFIG11 64 MiB) */
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 0/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI
2014-06-02 13:40 [PATCH 0/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
` (3 preceding siblings ...)
2014-06-02 13:40 ` [PATCH 4/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI Geert Uytterhoeven
@ 2014-06-03 4:29 ` Khiem Nguyen
4 siblings, 0 replies; 9+ messages in thread
From: Khiem Nguyen @ 2014-06-03 4:29 UTC (permalink / raw)
To: linux-arm-kernel
Hi Geert,
Thanks for the patch.
It seems that patch 1 and patch 2 are to support DMA in general,
while patch 3 and patch 4 are to support DMA for QSPI.
So, I think it should be separated into 2 patch series.
How do you think about it ?
Best regards,
KHIEM Nguyen
On 6/2/2014 10:40 PM, Geert Uytterhoeven wrote:
> This patch series enables DMA support for QSPI on r8a7791/koelsch legacy.
> It's independent from the series "ARM: shmobile: koelsch reference: Enable
> DMA for QSPI".
>
> [2/4] was written by Morimoto-san for LTSI 3.10, and forward ported by me.
>
> This was tested on r8a7791/koelsch.
>
> Performance figures for reading from a QSPI FLASH driven at 24.375 MHz are:
> - Single: 1.1 Mbps PIO, 23 Mbps DMA
> - Dual : 12.7 Mbps PIO, 48 Mbps DMA
> - Quad : 13 Mbps PIO, 70 Mbps DMA
>
> Thanks for your comments!
>
> [1/4] ARM: shmobile: r8a7791: Add SYS-DMAC clocks
> [2/4] ARM: shmobile: r8a7791: Add SYS-DMAC support
> [3/4] ARM: shmobile: r8a7791: Add QSPI DMA support
> [4/4] ARM: shmobile: koelsch legacy: Enable DMA for QSPI
>
> arch/arm/mach-shmobile/board-koelsch.c | 2 +
> arch/arm/mach-shmobile/clock-r8a7791.c | 6 +-
> arch/arm/mach-shmobile/include/mach/r8a7791.h | 7 +++
> arch/arm/mach-shmobile/setup-r8a7791.c | 82 +++++++++++++++++++++++++++
> 4 files changed, 96 insertions(+), 1 deletion(-)
>
> Gr{oetje,eeting}s,
>
> Geert
>
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
>
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
> -- Linus Torvalds
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 9+ messages in thread