[2/3] mmc: core: Respect MMC host's maximum segment size
diff mbox series

Message ID 20190909125658.30559-3-thierry.reding@gmail.com
State New
Headers show
  • mmc: Fix scatter/gather on SDHCI
Related show

Commit Message

Thierry Reding Sept. 9, 2019, 12:56 p.m. UTC
From: Thierry Reding <treding@nvidia.com>

Do not overwrite the MMC host's configured maximum segment size for DMA
transfers. For devices behind an IOMMU, the queue's maximum segment size
may be larger than that of the MMC host, but that doesn't mean that the
MMC host actually supports it.

Signed-off-by: Thierry Reding <treding@nvidia.com>
 drivers/mmc/core/queue.c | 2 --
 1 file changed, 2 deletions(-)

diff mbox series

diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c
index 1e29b305767e..987b01f4cfb3 100644
--- a/drivers/mmc/core/queue.c
+++ b/drivers/mmc/core/queue.c
@@ -389,8 +389,6 @@  static void mmc_setup_queue(struct mmc_queue *mq, struct mmc_card *card)
 			round_down(host->max_seg_size, block_size));
-	dma_set_max_seg_size(mmc_dev(host), queue_max_segment_size(mq->queue));
 	INIT_WORK(&mq->recovery_work, mmc_mq_recovery_handler);
 	INIT_WORK(&mq->complete_work, mmc_blk_mq_complete_work);