* [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
@ 2010-07-20 7:52 Yusuke Goda
2010-07-23 11:05 ` Magnus Damm
2010-08-20 15:06 ` Arnd Hannemann
0 siblings, 2 replies; 7+ messages in thread
From: Yusuke Goda @ 2010-07-20 7:52 UTC (permalink / raw)
To: ian, damm, sameo, Paul Mundt, g.liakhovetski, linux-mmc,
linux-kernel
Cc: Andrew Morton
Adjust the tmio_mmc block size check to accept 2-byte requests in 4-bit mode.
Tested with the SDHI hardware block included in sh7724.
Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
---
drivers/mmc/host/tmio_mmc.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mmc/host/tmio_mmc.c b/drivers/mmc/host/tmio_mmc.c
index ee7d0a5..f49d945 100644
--- a/drivers/mmc/host/tmio_mmc.c
+++ b/drivers/mmc/host/tmio_mmc.c
@@ -660,8 +660,8 @@ static int tmio_mmc_start_data(struct tmio_mmc_host *host,
pr_debug("setup data transfer: blocksize %08x nr_blocks %d\n",
data->blksz, data->blocks);
- /* Hardware cannot perform 1 and 2 byte requests in 4 bit mode */
- if (data->blksz < 4 && host->mmc->ios.bus_width == MMC_BUS_WIDTH_4) {
+ /* Hardware cannot perform 1 byte requests in 4 bit mode */
+ if (data->blksz < 2 && host->mmc->ios.bus_width == MMC_BUS_WIDTH_4) {
pr_err("%s: %d byte block unsupported in 4 bit mode\n",
mmc_hostname(host->mmc), data->blksz);
return -EINVAL;
--
1.7.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
2010-07-20 7:52 [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode Yusuke Goda
@ 2010-07-23 11:05 ` Magnus Damm
2010-07-27 7:57 ` Ian Molton
2010-08-20 15:06 ` Arnd Hannemann
1 sibling, 1 reply; 7+ messages in thread
From: Magnus Damm @ 2010-07-23 11:05 UTC (permalink / raw)
To: Yusuke Goda
Cc: ian, damm, sameo, Paul Mundt, g.liakhovetski, linux-mmc,
linux-kernel, Andrew Morton
2010/7/20 Yusuke Goda <yusuke.goda.sx@renesas.com>:
> Adjust the tmio_mmc block size check to accept 2-byte requests in 4-bit mode.
> Tested with the SDHI hardware block included in sh7724.
>
> Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
With this patch applied I can use SDIO cards in polling mode with the
tmio-mmc driver. Tested with the SDHI hardware block on sh7372 using
the b43 driver and BCM4318 hardware and the unfortunately out-of-tree
AR6002 "android" driver.
Acked-by: Magnus Damm <damm@opensource.se>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
2010-07-23 11:05 ` Magnus Damm
@ 2010-07-27 7:57 ` Ian Molton
2010-07-27 8:05 ` Magnus Damm
0 siblings, 1 reply; 7+ messages in thread
From: Ian Molton @ 2010-07-27 7:57 UTC (permalink / raw)
To: Magnus Damm
Cc: Yusuke Goda, damm, sameo, Paul Mundt, g.liakhovetski, linux-mmc,
linux-kernel, Andrew Morton
This change needs to be modified to test what hardware is present.
this wont work on my hardware TTBOMK.
--
Ian Molton
Linux, Automotive, and other hacking:
http://www.mnementh.co.uk/
On 23 July 2010 12:05, Magnus Damm <magnus.damm@gmail.com> wrote:
> 2010/7/20 Yusuke Goda <yusuke.goda.sx@renesas.com>:
>> Adjust the tmio_mmc block size check to accept 2-byte requests in 4-bit mode.
>> Tested with the SDHI hardware block included in sh7724.
>>
>> Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
>
> With this patch applied I can use SDIO cards in polling mode with the
> tmio-mmc driver. Tested with the SDHI hardware block on sh7372 using
> the b43 driver and BCM4318 hardware and the unfortunately out-of-tree
> AR6002 "android" driver.
>
> Acked-by: Magnus Damm <damm@opensource.se>
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
2010-07-27 7:57 ` Ian Molton
@ 2010-07-27 8:05 ` Magnus Damm
2010-08-20 22:59 ` Magnus Damm
0 siblings, 1 reply; 7+ messages in thread
From: Magnus Damm @ 2010-07-27 8:05 UTC (permalink / raw)
To: Ian Molton
Cc: Yusuke Goda, damm, sameo, Paul Mundt, g.liakhovetski, linux-mmc,
linux-kernel, Andrew Morton
> On 23 July 2010 12:05, Magnus Damm <magnus.damm@gmail.com> wrote:
>> 2010/7/20 Yusuke Goda <yusuke.goda.sx@renesas.com>:
>>> Adjust the tmio_mmc block size check to accept 2-byte requests in 4-bit mode.
>>> Tested with the SDHI hardware block included in sh7724.
>>>
>>> Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
>>
>> With this patch applied I can use SDIO cards in polling mode with the
>> tmio-mmc driver. Tested with the SDHI hardware block on sh7372 using
>> the b43 driver and BCM4318 hardware and the unfortunately out-of-tree
>> AR6002 "android" driver.
>>
>> Acked-by: Magnus Damm <damm@opensource.se>
>>
Hi Ian,
Thanks for your feedback!
On Tue, Jul 27, 2010 at 4:57 PM, Ian Molton <ian@mnementh.co.uk> wrote:
> This change needs to be modified to test what hardware is present.
> this wont work on my hardware TTBOMK.
Ok, just curious, on which platform did you test it?
On SDHI hardware the 2-byte access works just fine in 4-bit mode.
Thanks,
/ magnus
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
2010-07-20 7:52 [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode Yusuke Goda
2010-07-23 11:05 ` Magnus Damm
@ 2010-08-20 15:06 ` Arnd Hannemann
2010-08-20 23:01 ` Magnus Damm
1 sibling, 1 reply; 7+ messages in thread
From: Arnd Hannemann @ 2010-08-20 15:06 UTC (permalink / raw)
To: Yusuke Goda
Cc: ian, damm, sameo, Paul Mundt, g.liakhovetski, linux-mmc,
linux-kernel, Andrew Morton
Hi,
Am 20.07.2010 09:52, schrieb Yusuke Goda:
> Adjust the tmio_mmc block size check to accept 2-byte requests in
> 4-bit mode. Tested with the SDHI hardware block included in sh7724.
>
> Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
Tested on AP4EVB (sh7372) with SDHC and MMC cards - no regression.
Tested-by: Arnd Hannemann <arnd@arndnet.de>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
2010-07-27 8:05 ` Magnus Damm
@ 2010-08-20 22:59 ` Magnus Damm
0 siblings, 0 replies; 7+ messages in thread
From: Magnus Damm @ 2010-08-20 22:59 UTC (permalink / raw)
To: Ian Molton
Cc: Yusuke Goda, damm, sameo, Paul Mundt, g.liakhovetski, linux-mmc,
linux-kernel, Andrew Morton
On Tue, Jul 27, 2010 at 5:05 PM, Magnus Damm <magnus.damm@gmail.com> wrote:
>> On 23 July 2010 12:05, Magnus Damm <magnus.damm@gmail.com> wrote:
>>> 2010/7/20 Yusuke Goda <yusuke.goda.sx@renesas.com>:
>>>> Adjust the tmio_mmc block size check to accept 2-byte requests in 4-bit mode.
>>>> Tested with the SDHI hardware block included in sh7724.
>>>>
>>>> Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
>>>
>>> With this patch applied I can use SDIO cards in polling mode with the
>>> tmio-mmc driver. Tested with the SDHI hardware block on sh7372 using
>>> the b43 driver and BCM4318 hardware and the unfortunately out-of-tree
>>> AR6002 "android" driver.
>>>
>>> Acked-by: Magnus Damm <damm@opensource.se>
>>>
> On Tue, Jul 27, 2010 at 4:57 PM, Ian Molton <ian@mnementh.co.uk> wrote:
>> This change needs to be modified to test what hardware is present.
>> this wont work on my hardware TTBOMK.
>
> Ok, just curious, on which platform did you test it?
>
> On SDHI hardware the 2-byte access works just fine in 4-bit mode.
Hi Ian,
Any update on this? I'd like to see this patch upstream since it
unbreaks SDIO support for platforms with SDHI controllers.
I have a BCM4318-based SDIO card that I can send with snail mail from
Japan if anyone is interested in testing on non-SDHI platforms.
Thanks,
/ magnus
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode
2010-08-20 15:06 ` Arnd Hannemann
@ 2010-08-20 23:01 ` Magnus Damm
0 siblings, 0 replies; 7+ messages in thread
From: Magnus Damm @ 2010-08-20 23:01 UTC (permalink / raw)
To: Arnd Hannemann
Cc: Yusuke Goda, ian, damm, sameo, Paul Mundt, g.liakhovetski,
linux-mmc, linux-kernel, Andrew Morton
On Sat, Aug 21, 2010 at 12:06 AM, Arnd Hannemann <arnd@arndnet.de> wrote:
> Am 20.07.2010 09:52, schrieb Yusuke Goda:
>> Adjust the tmio_mmc block size check to accept 2-byte requests in
>> 4-bit mode. Tested with the SDHI hardware block included in sh7724.
>>
>> Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
>
> Tested on AP4EVB (sh7372) with SDHC and MMC cards - no regression.
>
> Tested-by: Arnd Hannemann <arnd@arndnet.de>
Hi Arnd,
With both you, Goda-san and me testing it certainly looks like this
one also is ok on platforms with SDHI.
Thanks a lot!
/ magnus
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2010-08-20 23:01 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-20 7:52 [PATCH] tmio_mmc: Allow 2 byte requests in 4-bit mode Yusuke Goda
2010-07-23 11:05 ` Magnus Damm
2010-07-27 7:57 ` Ian Molton
2010-07-27 8:05 ` Magnus Damm
2010-08-20 22:59 ` Magnus Damm
2010-08-20 15:06 ` Arnd Hannemann
2010-08-20 23:01 ` Magnus Damm
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).