All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC] MMC: CMD52 During Data Transfer support
@ 2015-02-09  3:14 ` Barry Song
  0 siblings, 0 replies; 4+ messages in thread
From: Barry Song @ 2015-02-09  3:14 UTC (permalink / raw)
  To: Chris Ball, Ulf Hansson, linux-mmc@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
  Cc: Yonghui.Zhang, DL-SHA-WorkGroupLinux, yongsheng.liu

hi Chris, Ulf,
According to https://www.sdcard.org/downloads/pls/simplified_specs/archive/partE1_200.pdf
(section CMD52 During Data Transfer ),
A card may accept CMD52 during data transfer if it supports Direct
Commands (see SDC, Table 6-3). For both SD and SPI modes, if an error
occurs during data transfer the SDIO card shall accept CMD52 to allow
I/O abort and reset regardless of this bit value of the value of SDC.

But drivers/mmc/host/sdhci.c doesn't support this mode if i didn't
miss something:-) we need it now to improve he throughput of a high
speed Software Digital Radio SDIO card. so we'd like to add support
for it.

a simple idea is

1. we need to drop this WARN_ON:

1343 static void sdhci_request(struct mmc_host *mmc, struct mmc_request *mrq)
1344 {
1345         struct sdhci_host *host;
1346         int present;
1347         unsigned long flags;
1348         u32 tuning_opcode;
1349
1350         host = mmc_priv(mmc);
1351
1352         sdhci_runtime_pm_get(host);
1353
1354         present = mmc_gpio_get_cd(host->mmc);
1355
1356         spin_lock_irqsave(&host->lock, flags);
1357
1358         WARN_ON(host->mrq != NULL);

2. we need to permit a new command to execute even when host->mrq is
not NULL and a CMD53 is ongoing.
this means we might add a new cmd52 request field in host struct to
buffer CMD52 request. and after the cmd52 finishes, we still need the
capability to wake up the blocking thread.

I'd like to know your suggestions on this feature.

-barry

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-02-10  7:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-09  3:14 [RFC] MMC: CMD52 During Data Transfer support Barry Song
2015-02-09  3:14 ` Barry Song
2015-02-10  7:29 ` Adrian Hunter
2015-02-10  7:29   ` Adrian Hunter

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.