* [RFC PATCH 1/6] mmc: tmio: make tmio_mmc_request function more readable
2017-05-01 9:03 [RFC PATCH 0/6] tmio/sdhi: add cmd23 support Wolfram Sang
@ 2017-05-01 9:03 ` Wolfram Sang
2017-05-02 10:18 ` Geert Uytterhoeven
2017-05-01 9:03 ` [RFC PATCH 2/6] mmc: tmio: refactor handling mrq Wolfram Sang
` (4 subsequent siblings)
5 siblings, 1 reply; 12+ messages in thread
From: Wolfram Sang @ 2017-05-01 9:03 UTC (permalink / raw)
To: linux-mmc; +Cc: linux-renesas-soc, Wolfram Sang
This part confused me and I had to read it twice until I got it. Let's
follow the standard pattern to bail out if something is wrong and keep
in the body of the function when everything is as expected.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/mmc/host/tmio_mmc_pio.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index a2d92f10501bdd..ba1a233f97f03c 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -889,11 +889,12 @@ static void tmio_mmc_request(struct mmc_host *mmc, struct mmc_request *mrq)
}
ret = tmio_mmc_start_command(host, mrq->cmd);
- if (!ret) {
- schedule_delayed_work(&host->delayed_reset_work,
- msecs_to_jiffies(CMDREQ_TIMEOUT));
- return;
- }
+ if (ret)
+ goto fail;
+
+ schedule_delayed_work(&host->delayed_reset_work,
+ msecs_to_jiffies(CMDREQ_TIMEOUT));
+ return;
fail:
host->force_pio = false;
--
2.11.0
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [RFC PATCH 1/6] mmc: tmio: make tmio_mmc_request function more readable
2017-05-01 9:03 ` [RFC PATCH 1/6] mmc: tmio: make tmio_mmc_request function more readable Wolfram Sang
@ 2017-05-02 10:18 ` Geert Uytterhoeven
0 siblings, 0 replies; 12+ messages in thread
From: Geert Uytterhoeven @ 2017-05-02 10:18 UTC (permalink / raw)
To: Wolfram Sang; +Cc: Linux MMC List, Linux-Renesas
On Mon, May 1, 2017 at 11:03 AM, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
> This part confused me and I had to read it twice until I got it. Let's
> follow the standard pattern to bail out if something is wrong and keep
> in the body of the function when everything is as expected.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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] 12+ messages in thread
* [RFC PATCH 2/6] mmc: tmio: refactor handling mrq
2017-05-01 9:03 [RFC PATCH 0/6] tmio/sdhi: add cmd23 support Wolfram Sang
2017-05-01 9:03 ` [RFC PATCH 1/6] mmc: tmio: make tmio_mmc_request function more readable Wolfram Sang
@ 2017-05-01 9:03 ` Wolfram Sang
2017-05-02 10:18 ` Geert Uytterhoeven
2017-05-01 9:03 ` [RFC PATCH 3/6] mmc: tmio: remove outdated comment Wolfram Sang
` (3 subsequent siblings)
5 siblings, 1 reply; 12+ messages in thread
From: Wolfram Sang @ 2017-05-01 9:03 UTC (permalink / raw)
To: linux-mmc; +Cc: linux-renesas-soc, Wolfram Sang
Split handling mrq into a seperate function. We need to call it from
another place soon.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/mmc/host/tmio_mmc_pio.c | 46 +++++++++++++++++++++++------------------
1 file changed, 26 insertions(+), 20 deletions(-)
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index ba1a233f97f03c..9d86e3ac626444 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -857,12 +857,36 @@ static int tmio_mmc_execute_tuning(struct mmc_host *mmc, u32 opcode)
return ret;
}
+static void tmio_process_mrq(struct tmio_mmc_host *host, struct mmc_request *mrq)
+{
+ int ret;
+
+ if (mrq->data) {
+ ret = tmio_mmc_start_data(host, mrq->data);
+ if (ret)
+ goto fail;
+ }
+
+ ret = tmio_mmc_start_command(host, mrq->cmd);
+ if (ret)
+ goto fail;
+
+ schedule_delayed_work(&host->delayed_reset_work,
+ msecs_to_jiffies(CMDREQ_TIMEOUT));
+ return;
+
+fail:
+ host->force_pio = false;
+ host->mrq = NULL;
+ mrq->cmd->error = ret;
+ mmc_request_done(host->mmc, mrq);
+}
+
/* Process requests from the MMC layer */
static void tmio_mmc_request(struct mmc_host *mmc, struct mmc_request *mrq)
{
struct tmio_mmc_host *host = mmc_priv(mmc);
unsigned long flags;
- int ret;
spin_lock_irqsave(&host->lock, flags);
@@ -882,25 +906,7 @@ static void tmio_mmc_request(struct mmc_host *mmc, struct mmc_request *mrq)
spin_unlock_irqrestore(&host->lock, flags);
- if (mrq->data) {
- ret = tmio_mmc_start_data(host, mrq->data);
- if (ret)
- goto fail;
- }
-
- ret = tmio_mmc_start_command(host, mrq->cmd);
- if (ret)
- goto fail;
-
- schedule_delayed_work(&host->delayed_reset_work,
- msecs_to_jiffies(CMDREQ_TIMEOUT));
- return;
-
-fail:
- host->force_pio = false;
- host->mrq = NULL;
- mrq->cmd->error = ret;
- mmc_request_done(mmc, mrq);
+ tmio_process_mrq(host, mrq);
}
static int tmio_mmc_clk_enable(struct tmio_mmc_host *host)
--
2.11.0
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [RFC PATCH 2/6] mmc: tmio: refactor handling mrq
2017-05-01 9:03 ` [RFC PATCH 2/6] mmc: tmio: refactor handling mrq Wolfram Sang
@ 2017-05-02 10:18 ` Geert Uytterhoeven
0 siblings, 0 replies; 12+ messages in thread
From: Geert Uytterhoeven @ 2017-05-02 10:18 UTC (permalink / raw)
To: Wolfram Sang; +Cc: Linux MMC List, Linux-Renesas
On Mon, May 1, 2017 at 11:03 AM, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
> Split handling mrq into a seperate function. We need to call it from
> another place soon.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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] 12+ messages in thread
* [RFC PATCH 3/6] mmc: tmio: remove outdated comment
2017-05-01 9:03 [RFC PATCH 0/6] tmio/sdhi: add cmd23 support Wolfram Sang
2017-05-01 9:03 ` [RFC PATCH 1/6] mmc: tmio: make tmio_mmc_request function more readable Wolfram Sang
2017-05-01 9:03 ` [RFC PATCH 2/6] mmc: tmio: refactor handling mrq Wolfram Sang
@ 2017-05-01 9:03 ` Wolfram Sang
2017-05-02 10:21 ` Geert Uytterhoeven
2017-05-01 9:03 ` [RFC PATCH 4/6] mmc: tmio: move finish_request function further down Wolfram Sang
` (2 subsequent siblings)
5 siblings, 1 reply; 12+ messages in thread
From: Wolfram Sang @ 2017-05-01 9:03 UTC (permalink / raw)
To: linux-mmc; +Cc: linux-renesas-soc, Wolfram Sang
The obviously wrong comment was added in 2011 with commit df3ef2d3c92c0a
("mmc: protect the tmio_mmc driver against a theoretical race") but
already obsoleted half a year later with commit b9269fdd4f61aa ("mmc:
tmio: fix recursive spinlock, don't schedule with interrupts disabled").
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/mmc/host/tmio_mmc_pio.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index 9d86e3ac626444..36539950347fbc 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -279,7 +279,6 @@ static void tmio_mmc_reset_work(struct work_struct *work)
mmc_request_done(host->mmc, mrq);
}
-/* called with host->lock held, interrupts disabled */
static void tmio_mmc_finish_request(struct tmio_mmc_host *host)
{
struct mmc_request *mrq;
--
2.11.0
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [RFC PATCH 3/6] mmc: tmio: remove outdated comment
2017-05-01 9:03 ` [RFC PATCH 3/6] mmc: tmio: remove outdated comment Wolfram Sang
@ 2017-05-02 10:21 ` Geert Uytterhoeven
0 siblings, 0 replies; 12+ messages in thread
From: Geert Uytterhoeven @ 2017-05-02 10:21 UTC (permalink / raw)
To: Wolfram Sang; +Cc: Linux MMC List, Linux-Renesas
On Mon, May 1, 2017 at 11:03 AM, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
> The obviously wrong comment was added in 2011 with commit df3ef2d3c92c0a
> ("mmc: protect the tmio_mmc driver against a theoretical race") but
> already obsoleted half a year later with commit b9269fdd4f61aa ("mmc:
> tmio: fix recursive spinlock, don't schedule with interrupts disabled").
Fixes: b9269fdd4f61aa ("mmc: tmio: fix recursive spinlock, don't
schedule with interrupts disabled")
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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] 12+ messages in thread
* [RFC PATCH 4/6] mmc: tmio: move finish_request function further down
2017-05-01 9:03 [RFC PATCH 0/6] tmio/sdhi: add cmd23 support Wolfram Sang
` (2 preceding siblings ...)
2017-05-01 9:03 ` [RFC PATCH 3/6] mmc: tmio: remove outdated comment Wolfram Sang
@ 2017-05-01 9:03 ` Wolfram Sang
2017-05-02 10:21 ` Geert Uytterhoeven
2017-05-01 9:03 ` [RFC PATCH 5/6] mmc: tmio: add CMD23 support Wolfram Sang
2017-05-01 9:03 ` [RFC PATCH 6/6] mmc: sdhi: add CMD23 support to R-Car Gen2 & Gen3 Wolfram Sang
5 siblings, 1 reply; 12+ messages in thread
From: Wolfram Sang @ 2017-05-01 9:03 UTC (permalink / raw)
To: linux-mmc; +Cc: linux-renesas-soc, Wolfram Sang
Plain code move with no changes. Needed for refactoring. Also, looks
nicer if request and finish_request are next to each other.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/mmc/host/tmio_mmc_pio.c | 76 ++++++++++++++++++++---------------------
1 file changed, 38 insertions(+), 38 deletions(-)
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index 36539950347fbc..b3ecb2e2e344c3 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -279,44 +279,6 @@ static void tmio_mmc_reset_work(struct work_struct *work)
mmc_request_done(host->mmc, mrq);
}
-static void tmio_mmc_finish_request(struct tmio_mmc_host *host)
-{
- struct mmc_request *mrq;
- unsigned long flags;
-
- spin_lock_irqsave(&host->lock, flags);
-
- mrq = host->mrq;
- if (IS_ERR_OR_NULL(mrq)) {
- spin_unlock_irqrestore(&host->lock, flags);
- return;
- }
-
- host->cmd = NULL;
- host->data = NULL;
- host->force_pio = false;
-
- cancel_delayed_work(&host->delayed_reset_work);
-
- host->mrq = NULL;
- spin_unlock_irqrestore(&host->lock, flags);
-
- if (mrq->cmd->error || (mrq->data && mrq->data->error))
- tmio_mmc_abort_dma(host);
-
- if (host->check_scc_error)
- host->check_scc_error(host);
-
- mmc_request_done(host->mmc, mrq);
-}
-
-static void tmio_mmc_done_work(struct work_struct *work)
-{
- struct tmio_mmc_host *host = container_of(work, struct tmio_mmc_host,
- done);
- tmio_mmc_finish_request(host);
-}
-
/* These are the bitmasks the tmio chip requires to implement the MMC response
* types. Note that R1 and R6 are the same in this scheme. */
#define APP_CMD 0x0040
@@ -908,6 +870,44 @@ static void tmio_mmc_request(struct mmc_host *mmc, struct mmc_request *mrq)
tmio_process_mrq(host, mrq);
}
+static void tmio_mmc_finish_request(struct tmio_mmc_host *host)
+{
+ struct mmc_request *mrq;
+ unsigned long flags;
+
+ spin_lock_irqsave(&host->lock, flags);
+
+ mrq = host->mrq;
+ if (IS_ERR_OR_NULL(mrq)) {
+ spin_unlock_irqrestore(&host->lock, flags);
+ return;
+ }
+
+ host->cmd = NULL;
+ host->data = NULL;
+ host->force_pio = false;
+
+ cancel_delayed_work(&host->delayed_reset_work);
+
+ host->mrq = NULL;
+ spin_unlock_irqrestore(&host->lock, flags);
+
+ if (mrq->cmd->error || (mrq->data && mrq->data->error))
+ tmio_mmc_abort_dma(host);
+
+ if (host->check_scc_error)
+ host->check_scc_error(host);
+
+ mmc_request_done(host->mmc, mrq);
+}
+
+static void tmio_mmc_done_work(struct work_struct *work)
+{
+ struct tmio_mmc_host *host = container_of(work, struct tmio_mmc_host,
+ done);
+ tmio_mmc_finish_request(host);
+}
+
static int tmio_mmc_clk_enable(struct tmio_mmc_host *host)
{
if (!host->clk_enable)
--
2.11.0
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [RFC PATCH 4/6] mmc: tmio: move finish_request function further down
2017-05-01 9:03 ` [RFC PATCH 4/6] mmc: tmio: move finish_request function further down Wolfram Sang
@ 2017-05-02 10:21 ` Geert Uytterhoeven
0 siblings, 0 replies; 12+ messages in thread
From: Geert Uytterhoeven @ 2017-05-02 10:21 UTC (permalink / raw)
To: Wolfram Sang; +Cc: Linux MMC List, Linux-Renesas
On Mon, May 1, 2017 at 11:03 AM, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
> Plain code move with no changes. Needed for refactoring. Also, looks
> nicer if request and finish_request are next to each other.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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] 12+ messages in thread
* [RFC PATCH 5/6] mmc: tmio: add CMD23 support
2017-05-01 9:03 [RFC PATCH 0/6] tmio/sdhi: add cmd23 support Wolfram Sang
` (3 preceding siblings ...)
2017-05-01 9:03 ` [RFC PATCH 4/6] mmc: tmio: move finish_request function further down Wolfram Sang
@ 2017-05-01 9:03 ` Wolfram Sang
2017-05-01 9:03 ` [RFC PATCH 6/6] mmc: sdhi: add CMD23 support to R-Car Gen2 & Gen3 Wolfram Sang
5 siblings, 0 replies; 12+ messages in thread
From: Wolfram Sang @ 2017-05-01 9:03 UTC (permalink / raw)
To: linux-mmc; +Cc: linux-renesas-soc, Wolfram Sang
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/mmc/host/tmio_mmc_pio.c | 41 ++++++++++++++++++++++++++++-------------
1 file changed, 28 insertions(+), 13 deletions(-)
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index b3ecb2e2e344c3..a81b86ca735845 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -332,11 +332,11 @@ static int tmio_mmc_start_command(struct tmio_mmc_host *host, struct mmc_command
c |= TRANSFER_MULTI;
/*
- * Disable auto CMD12 at IO_RW_EXTENDED when
- * multiple block transfer
+ * Disable auto CMD12 at IO_RW_EXTENDED and SET_BLOCK_COUNT
+ * when doing multiple block transfer
*/
if ((host->pdata->flags & TMIO_MMC_HAVE_CMD12_CTRL) &&
- (cmd->opcode == SD_IO_RW_EXTENDED))
+ (cmd->opcode == SD_IO_RW_EXTENDED || host->mrq->sbc))
c |= NO_CMD12_ISSUE;
}
if (data->flags & MMC_DATA_READ)
@@ -513,7 +513,7 @@ void tmio_mmc_do_data_irq(struct tmio_mmc_host *host)
host->mrq);
}
- if (stop) {
+ if (stop && !host->mrq->sbc) {
if (stop->opcode != MMC_STOP_TRANSMISSION || stop->arg)
dev_err(&host->pdev->dev, "unsupported stop: CMD%u,0x%x. We did CMD12,0\n",
stop->opcode, stop->arg);
@@ -820,15 +820,21 @@ static int tmio_mmc_execute_tuning(struct mmc_host *mmc, u32 opcode)
static void tmio_process_mrq(struct tmio_mmc_host *host, struct mmc_request *mrq)
{
+ struct mmc_command *cmd;
int ret;
- if (mrq->data) {
- ret = tmio_mmc_start_data(host, mrq->data);
- if (ret)
- goto fail;
+ if (mrq->sbc && host->cmd != mrq->sbc) {
+ cmd = mrq->sbc;
+ } else {
+ cmd = mrq->cmd;
+ if (mrq->data) {
+ ret = tmio_mmc_start_data(host, mrq->data);
+ if (ret)
+ goto fail;
+ }
}
- ret = tmio_mmc_start_command(host, mrq->cmd);
+ ret = tmio_mmc_start_command(host, cmd);
if (ret)
goto fail;
@@ -883,13 +889,16 @@ static void tmio_mmc_finish_request(struct tmio_mmc_host *host)
return;
}
- host->cmd = NULL;
- host->data = NULL;
- host->force_pio = false;
+ /* If not SET_BLOCK_COUNT, clear old data */
+ if (host->cmd != mrq->sbc) {
+ host->cmd = NULL;
+ host->data = NULL;
+ host->force_pio = false;
+ host->mrq = NULL;
+ }
cancel_delayed_work(&host->delayed_reset_work);
- host->mrq = NULL;
spin_unlock_irqrestore(&host->lock, flags);
if (mrq->cmd->error || (mrq->data && mrq->data->error))
@@ -898,6 +907,12 @@ static void tmio_mmc_finish_request(struct tmio_mmc_host *host)
if (host->check_scc_error)
host->check_scc_error(host);
+ /* If SET_BLOCK_COUNT, continue with main command */
+ if (host->mrq) {
+ tmio_process_mrq(host, mrq);
+ return;
+ }
+
mmc_request_done(host->mmc, mrq);
}
--
2.11.0
^ permalink raw reply related [flat|nested] 12+ messages in thread* [RFC PATCH 6/6] mmc: sdhi: add CMD23 support to R-Car Gen2 & Gen3
2017-05-01 9:03 [RFC PATCH 0/6] tmio/sdhi: add cmd23 support Wolfram Sang
` (4 preceding siblings ...)
2017-05-01 9:03 ` [RFC PATCH 5/6] mmc: tmio: add CMD23 support Wolfram Sang
@ 2017-05-01 9:03 ` Wolfram Sang
2017-05-10 9:30 ` Simon Horman
5 siblings, 1 reply; 12+ messages in thread
From: Wolfram Sang @ 2017-05-01 9:03 UTC (permalink / raw)
To: linux-mmc; +Cc: linux-renesas-soc, Wolfram Sang
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/mmc/host/sh_mobile_sdhi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index bc6be0dbea3927..4843ce800c918d 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -96,7 +96,7 @@ static struct sh_mobile_sdhi_scc rcar_gen2_scc_taps[] = {
static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
.tmio_flags = TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE |
TMIO_MMC_CLK_ACTUAL | TMIO_MMC_MIN_RCAR2,
- .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+ .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ | MMC_CAP_CMD23,
.dma_buswidth = DMA_SLAVE_BUSWIDTH_4_BYTES,
.dma_rx_offset = 0x2000,
.scc_offset = 0x0300,
@@ -115,7 +115,7 @@ static struct sh_mobile_sdhi_scc rcar_gen3_scc_taps[] = {
static const struct sh_mobile_sdhi_of_data of_rcar_gen3_compatible = {
.tmio_flags = TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE |
TMIO_MMC_CLK_ACTUAL | TMIO_MMC_MIN_RCAR2,
- .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+ .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ | MMC_CAP_CMD23,
.bus_shift = 2,
.scc_offset = 0x1000,
.taps = rcar_gen3_scc_taps,
--
2.11.0
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [RFC PATCH 6/6] mmc: sdhi: add CMD23 support to R-Car Gen2 & Gen3
2017-05-01 9:03 ` [RFC PATCH 6/6] mmc: sdhi: add CMD23 support to R-Car Gen2 & Gen3 Wolfram Sang
@ 2017-05-10 9:30 ` Simon Horman
0 siblings, 0 replies; 12+ messages in thread
From: Simon Horman @ 2017-05-10 9:30 UTC (permalink / raw)
To: Wolfram Sang; +Cc: linux-mmc, linux-renesas-soc
On Mon, May 01, 2017 at 11:03:46AM +0200, Wolfram Sang wrote:
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> ---
> drivers/mmc/host/sh_mobile_sdhi.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index bc6be0dbea3927..4843ce800c918d 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -96,7 +96,7 @@ static struct sh_mobile_sdhi_scc rcar_gen2_scc_taps[] = {
> static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
> .tmio_flags = TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE |
> TMIO_MMC_CLK_ACTUAL | TMIO_MMC_MIN_RCAR2,
> - .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
> + .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ | MMC_CAP_CMD23,
Breaking capabilities over two lines would seem consistent with the
formatting of the rest of the structure.
> .dma_buswidth = DMA_SLAVE_BUSWIDTH_4_BYTES,
> .dma_rx_offset = 0x2000,
> .scc_offset = 0x0300,
> @@ -115,7 +115,7 @@ static struct sh_mobile_sdhi_scc rcar_gen3_scc_taps[] = {
> static const struct sh_mobile_sdhi_of_data of_rcar_gen3_compatible = {
> .tmio_flags = TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE |
> TMIO_MMC_CLK_ACTUAL | TMIO_MMC_MIN_RCAR2,
> - .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
> + .capabilities = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ | MMC_CAP_CMD23,
> .bus_shift = 2,
> .scc_offset = 0x1000,
> .taps = rcar_gen3_scc_taps,
> --
> 2.11.0
>
^ permalink raw reply [flat|nested] 12+ messages in thread