summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/sdhci.c
diff options
context:
space:
mode:
authorStefan Nilsson XK <stefan.xk.nilsson@stericsson.com>2011-10-26 10:52:17 +0200
committerChris Ball <cjb@laptop.org>2012-01-11 23:58:40 -0500
commit052d81da6e6f0f8839ef6d5a46f215fc8cd99d5a (patch)
tree39e77d55630168ae27eb5d63c58ae505875a31e3 /drivers/mmc/host/sdhci.c
parentfffe5d5aa05b4e69f79bc75a51c5ee0fc6203fa5 (diff)
downloadop-kernel-dev-052d81da6e6f0f8839ef6d5a46f215fc8cd99d5a.zip
op-kernel-dev-052d81da6e6f0f8839ef6d5a46f215fc8cd99d5a.tar.gz
mmc: sdio: Fix to support any block size optimally
This patch allows any block size to be set on the SDIO link, and still have an arbitrary sized packet (adjusted in size by using sdio_align_size) transferred in an optimal way (preferably one transfer). Previously if the block size was larger than the default of 512 bytes and the transfer size was exactly one block size (possibly thanks to using sdio_align_size to get an optimal transfer size), it was sent as a number of byte transfers instead of one block transfer. Also if the number of blocks was (max_blocks * N) + 1, the tranfer would be conducted with a number of blocks and finished off with a number of byte transfers. When doing this change it was also possible to break out the quirk for broken byte mode in a much cleaner way, and collect the logic of when to do byte or block transfer in one function instead of two. Signed-off-by: Stefan Nilsson XK <stefan.xk.nilsson@stericsson.com> Signed-off-by: Ulf Hansson <ulf.hansson@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc/host/sdhci.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud