public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Wolfram Sang <wsa@the-dreams.de>
To: Simon Horman <horms+renesas@verge.net.au>
Cc: Wolfram Sang <wsa+renesas@sang-engineering.com>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	Magnus Damm <magnus.damm@gmail.com>,
	linux-mmc@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
	Dirk Behme <dirk.behme@de.bosch.com>,
	Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>,
	Ai Kyuse <ai.kyuse.uw@renesas.com>
Subject: Re: [PATCH mmc/next v2 3/4] mmc: renesas-sdhi: add support for R-Car Gen3 SDHI DMAC
Date: Sat, 17 Jun 2017 17:00:56 +0200	[thread overview]
Message-ID: <20170617150055.eeholgustydof3w5@ninjato> (raw)
In-Reply-To: <1497607134-10241-4-git-send-email-horms+renesas@verge.net.au>

[-- Attachment #1: Type: text/plain, Size: 1387 bytes --]

On Fri, Jun 16, 2017 at 11:58:53AM +0200, Simon Horman wrote:
> Add a new variant of the SDHI driver to support R-Car Gen3 with DMA via
> on-chip bus mastering.  Since the DMAC is in a part of the SDHI module it
> is not suitable to be used via DMA Engine.
> 
> Clearing of DM_CM_INFO1 after DMA thanks to Dirk Behme
> 
> Cc: Dirk Behme <dirk.behme@de.bosch.com>
> Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
> Signed-off-by: Ai Kyuse <ai.kyuse.uw@renesas.com>

Your Sob is missing!

> + * - Since this SDHI DMAC register set has actual 32-bit and "bus_shift" is 2,
> + *   this driver cannot use original sd_ctrl_{write,read}32 functions.

Easier to understand, I'd think, would be:

Since the SDHI DMAC register set has not 16 but 32-bit width, we need a
custom accessor.

> +	ret = dma_map_sg(&host->pdev->dev, sg, host->sg_len, dir);
> +	if (ret < 0) {
> +		dev_err(&host->pdev->dev, "%s: dma_map_sg failed\n", __func__);

__func__?

> +	/* start the DMAC */

Not very useful comment in my book, but no strong opinion.

> +	renesas_sdhi_internal_dmac_dm_write(host, DM_CM_DTRAN_CTRL,
> +					    DTRAN_CTRL_DM_START);
> +}
> +	dma_unmap_sg(&host->pdev->dev, host->sg_ptr, host->sg_len, dir);
> +
> +	spin_unlock_irq(&host->lock);
> +
> +	spin_lock_irq(&host->lock);

Just keep the lock?

Rest looks good so far...


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2017-06-17 15:00 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-16  9:58 [PATCH mmc/next v2 0/4] mmc: renesas_sdhi: add support for R-Car Gen3 SDHI DMAC Simon Horman
2017-06-16  9:58 ` [PATCH mmc/next v2 1/4] mmc: tmio, renesas-sdhi: add max_{segs,blk_count} to tmio_mmc_data Simon Horman
2017-06-17 15:01   ` Wolfram Sang
2017-06-16  9:58 ` [PATCH mmc/next v2 2/4] mmc: tmio, renesas-sdhi: add complete to DMA ops Simon Horman
2017-06-17 15:01   ` Wolfram Sang
2017-06-19 11:58     ` Simon Horman
2017-06-16  9:58 ` [PATCH mmc/next v2 3/4] mmc: renesas-sdhi: add support for R-Car Gen3 SDHI DMAC Simon Horman
2017-06-17 15:00   ` Wolfram Sang [this message]
2017-06-21  9:10     ` Simon Horman
2017-06-17 20:55   ` Simon Horman
2017-06-21  9:01     ` Simon Horman
2017-06-16  9:58 ` [PATCH mmc/next v2 4/4] mmc: renesas-sdhi: remove gen3 support from SYS-DMAC driver Simon Horman
2017-06-17 15:01   ` Wolfram Sang
2017-06-17 15:03 ` [PATCH mmc/next v2 0/4] mmc: renesas_sdhi: add support for R-Car Gen3 SDHI DMAC Wolfram Sang
2017-06-19 11:59   ` 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=20170617150055.eeholgustydof3w5@ninjato \
    --to=wsa@the-dreams.de \
    --cc=ai.kyuse.uw@renesas.com \
    --cc=dirk.behme@de.bosch.com \
    --cc=horms+renesas@verge.net.au \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=ulf.hansson@linaro.org \
    --cc=wsa+renesas@sang-engineering.com \
    --cc=yoshihiro.shimoda.uh@renesas.com \
    /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