From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2 1/2] ARM: shmobile: r8a7778: add HPB-DMAC support
Date: Mon, 29 Jul 2013 22:46:23 +0000 [thread overview]
Message-ID: <51F6F0BF.2030004@cogentembedded.com> (raw)
In-Reply-To: <87a9lacd6o.wl%kuninori.morimoto.gx@renesas.com>
Hello.
On 07/26/2013 05:39 AM, Kuninori Morimoto wrote:
>>> +static const struct hpb_dmae_slave_config hpb_dmae_slaves[] = {
>>> + {
>>> + .id = HPBDMA_SLAVE_SDHI0_TX,
>>> + .addr = 0xffe4c000 + 0x30,
>>> + .dcr = DCR_SPDS_16BIT | DCR_DMDL | DCR_DPDS_16BIT,
>>> + .rstr = ASYNCRSTR_ASRST21 | ASYNCRSTR_ASRST22 |
>>> + ASYNCRSTR_ASRST23,
>>> + .mdr = ASYNCMDR_ASMD21_SINGLE,
>>> + .mdm = ASYNCMDR_ASMD21_MASK,
>>> + .port = 0x0D0C,
>>> + .flags = HPB_DMAE_SET_ASYNC_RESET | HPB_DMAE_SET_ASYNC_MODE,
>>> + .dma_ch = 21,
>>> + }, {
>>> + .id = HPBDMA_SLAVE_SDHI0_RX,
>>> + .addr = 0xffe4c000 + 0x30,
>>> + .dcr = DCR_SMDL | DCR_SPDS_16BIT | DCR_DPDS_16BIT,
>>> + .rstr = ASYNCRSTR_ASRST21 | ASYNCRSTR_ASRST22 |
>>> + ASYNCRSTR_ASRST23,
>>> + .mdr = ASYNCMDR_ASMD22_SINGLE,
>>> + .mdm = ASYNCMDR_ASMD22_MASK,
>>> + .port = 0x0D0C,
>>> + .flags = HPB_DMAE_SET_ASYNC_RESET | HPB_DMAE_SET_ASYNC_MODE,
>>> + .dma_ch = 22,
>>> + },
> I'm not sure detail of SDHI, but TX and RX are using same .port = 0x0D0C.
It's not one port, it's a pair of ports, source and destination.
> Is this correct ?
> And what is 0x0C port ?
SDHI0 if you look into the table 16.7 of the R-Car M1A manual 1.00 for the
channels 21 thru 23.
> My datasheet doens't have it on Ch21 - Ch23
Maybe you're looking at the wrong table or an obsolete manual?
>>> +static const struct hpb_dmae_channel hpb_dmae_channels[] = {
>>> + /* ch. 21 SD0 */
>>> + HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_TX),
>>> + /* ch. 22 SD0 */
>>> + HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_RX),
>>> +};
>>> +
>>> +static struct hpb_dmae_pdata dma_platform_data __initdata = {
>>> + .slaves = hpb_dmae_slaves,
>>> + .num_slaves = ARRAY_SIZE(hpb_dmae_slaves),
>>> + .channels = hpb_dmae_channels,
>>> + .num_channels = ARRAY_SIZE(hpb_dmae_channels),
>>> + .ts_shift = {
>>> + [XMIT_SZ_8BIT] = 0,
>>> + [XMIT_SZ_16BIT] = 1,
>>> + [XMIT_SZ_32BIT] = 2,
>>> + },
>>> + .num_hw_channels = 39,
>>> +};
> This is not a big deal, but according to .num_hw_channels,
> we will have max 39 channels (or more over).
> I want 1 line for 1 channels on hpb_dmae_channels.
> like this
> static const struct hpb_dmae_channel hpb_dmae_channels[] = {
> HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_TX), /* ch21 */
> HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_RX), /* ch22 */
> }
OK, done.
> Best regards
> ---
> Kuninori Morimoto
WBR, Sergei
WARNING: multiple messages have this Message-ID (diff)
From: sergei.shtylyov@cogentembedded.com (Sergei Shtylyov)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 1/2] ARM: shmobile: r8a7778: add HPB-DMAC support
Date: Tue, 30 Jul 2013 02:46:23 +0400 [thread overview]
Message-ID: <51F6F0BF.2030004@cogentembedded.com> (raw)
In-Reply-To: <87a9lacd6o.wl%kuninori.morimoto.gx@renesas.com>
Hello.
On 07/26/2013 05:39 AM, Kuninori Morimoto wrote:
>>> +static const struct hpb_dmae_slave_config hpb_dmae_slaves[] = {
>>> + {
>>> + .id = HPBDMA_SLAVE_SDHI0_TX,
>>> + .addr = 0xffe4c000 + 0x30,
>>> + .dcr = DCR_SPDS_16BIT | DCR_DMDL | DCR_DPDS_16BIT,
>>> + .rstr = ASYNCRSTR_ASRST21 | ASYNCRSTR_ASRST22 |
>>> + ASYNCRSTR_ASRST23,
>>> + .mdr = ASYNCMDR_ASMD21_SINGLE,
>>> + .mdm = ASYNCMDR_ASMD21_MASK,
>>> + .port = 0x0D0C,
>>> + .flags = HPB_DMAE_SET_ASYNC_RESET | HPB_DMAE_SET_ASYNC_MODE,
>>> + .dma_ch = 21,
>>> + }, {
>>> + .id = HPBDMA_SLAVE_SDHI0_RX,
>>> + .addr = 0xffe4c000 + 0x30,
>>> + .dcr = DCR_SMDL | DCR_SPDS_16BIT | DCR_DPDS_16BIT,
>>> + .rstr = ASYNCRSTR_ASRST21 | ASYNCRSTR_ASRST22 |
>>> + ASYNCRSTR_ASRST23,
>>> + .mdr = ASYNCMDR_ASMD22_SINGLE,
>>> + .mdm = ASYNCMDR_ASMD22_MASK,
>>> + .port = 0x0D0C,
>>> + .flags = HPB_DMAE_SET_ASYNC_RESET | HPB_DMAE_SET_ASYNC_MODE,
>>> + .dma_ch = 22,
>>> + },
> I'm not sure detail of SDHI, but TX and RX are using same .port = 0x0D0C.
It's not one port, it's a pair of ports, source and destination.
> Is this correct ?
> And what is 0x0C port ?
SDHI0 if you look into the table 16.7 of the R-Car M1A manual 1.00 for the
channels 21 thru 23.
> My datasheet doens't have it on Ch21 - Ch23
Maybe you're looking at the wrong table or an obsolete manual?
>>> +static const struct hpb_dmae_channel hpb_dmae_channels[] = {
>>> + /* ch. 21 SD0 */
>>> + HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_TX),
>>> + /* ch. 22 SD0 */
>>> + HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_RX),
>>> +};
>>> +
>>> +static struct hpb_dmae_pdata dma_platform_data __initdata = {
>>> + .slaves = hpb_dmae_slaves,
>>> + .num_slaves = ARRAY_SIZE(hpb_dmae_slaves),
>>> + .channels = hpb_dmae_channels,
>>> + .num_channels = ARRAY_SIZE(hpb_dmae_channels),
>>> + .ts_shift = {
>>> + [XMIT_SZ_8BIT] = 0,
>>> + [XMIT_SZ_16BIT] = 1,
>>> + [XMIT_SZ_32BIT] = 2,
>>> + },
>>> + .num_hw_channels = 39,
>>> +};
> This is not a big deal, but according to .num_hw_channels,
> we will have max 39 channels (or more over).
> I want 1 line for 1 channels on hpb_dmae_channels.
> like this
> static const struct hpb_dmae_channel hpb_dmae_channels[] = {
> HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_TX), /* ch21 */
> HPB_DMAE_CHANNEL(0x7e, HPBDMA_SLAVE_SDHI0_RX), /* ch22 */
> }
OK, done.
> Best regards
> ---
> Kuninori Morimoto
WBR, Sergei
next prev parent reply other threads:[~2013-07-29 22:46 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-22 22:18 [PATCH v2 0/2] R8A7778/BOCK-W: HPB-DMAC support for SDHI0 Sergei Shtylyov
2013-07-22 22:18 ` Sergei Shtylyov
2013-07-22 22:22 ` [PATCH v2 1/2] ARM: shmobile: r8a7778: add HPB-DMAC support Sergei Shtylyov
2013-07-22 22:22 ` Sergei Shtylyov
2013-07-26 0:10 ` Simon Horman
2013-07-26 0:10 ` Simon Horman
2013-07-26 1:39 ` Kuninori Morimoto
2013-07-26 1:39 ` Kuninori Morimoto
2013-07-29 22:46 ` Sergei Shtylyov [this message]
2013-07-29 22:46 ` Sergei Shtylyov
2013-07-30 0:30 ` Kuninori Morimoto
2013-07-30 0:30 ` Kuninori Morimoto
2013-07-22 22:23 ` [PATCH v2 2/2] ARM: shmobile: BOCK-W: enable DMA for SDHI0 Sergei Shtylyov
2013-07-22 22:23 ` Sergei Shtylyov
2013-07-23 1:11 ` Simon Horman
2013-07-23 1:11 ` Simon Horman
2013-07-23 1:58 ` Simon Horman
2013-07-23 1:58 ` Simon Horman
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=51F6F0BF.2030004@cogentembedded.com \
--to=sergei.shtylyov@cogentembedded.com \
--cc=linux-arm-kernel@lists.infradead.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.