From: Heiner Kallweit Date: Tue, 7 Feb 2017 21:34:58 +0000 (+0100) Subject: mmc: meson-gx: set max block count and request size X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=efe0b669716314072f0467368c2be2f501f04afc;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git mmc: meson-gx: set max block count and request size So far max_blk_count isn't set what results in a default of value 8 to be used (PAGE_SIZE / block size). Block length field has 9 bits, so set max_blk_count to 2^9-1 = 511. In addition set max_req_size because max_blk_count is also limited by max_req_size / block_size. Signed-off-by: Heiner Kallweit Reviewed-by: Kevin Hilman Tested-by: Kevin Hilman Acked-by: Kevin Hilman Signed-off-by: Ulf Hansson --- diff --git a/drivers/mmc/host/meson-gx-mmc.c b/drivers/mmc/host/meson-gx-mmc.c index 4c622ad26a70..c9f251713611 100644 --- a/drivers/mmc/host/meson-gx-mmc.c +++ b/drivers/mmc/host/meson-gx-mmc.c @@ -778,6 +778,9 @@ static int meson_mmc_probe(struct platform_device *pdev) if (ret) goto free_host; + mmc->max_blk_count = CMD_CFG_LENGTH_MASK; + mmc->max_req_size = mmc->max_blk_count * mmc->max_blk_size; + /* data bounce buffer */ host->bounce_buf_size = SZ_512K; host->bounce_buf =