diff options
author | Veerabhadrarao Badiganti <vbadigan@codeaurora.org> | 2020-01-20 20:08:38 +0530 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2020-01-24 12:11:48 +0100 |
commit | a663f64bf18dea0816642ff343c5e3bf8fb22fca (patch) | |
tree | 1008c520c3117ef2b4d32375425d086bbb177239 /drivers/mmc/host/sdhci.h | |
parent | 80c7482356ac9f08dbdb01a3c8485401494d9e05 (diff) | |
download | linux-a663f64bf18dea0816642ff343c5e3bf8fb22fca.tar.gz linux-a663f64bf18dea0816642ff343c5e3bf8fb22fca.tar.bz2 linux-a663f64bf18dea0816642ff343c5e3bf8fb22fca.zip |
mmc: sdhci: Let a vendor driver supply and update ADMA descriptor size
Let a vendor driver supply the maximum descriptor size that it
can operate on. ADMA descriptor table would be allocated using this
supplied size.
If any SD Host controller is of version prior to v4.10 spec
but supports 16byte descriptor, this change allows them to supply
correct descriptor size for ADMA table allocation.
Also let a vendor driver update the descriptor size by overriding
sdhc_host->desc_size if it has to operates on a different descriptor
sizes in different conditions.
Suggested-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Veerabhadrarao Badiganti <vbadigan@codeaurora.org>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Link: https://lore.kernel.org/r/1579531122-28341-1-git-send-email-vbadigan@codeaurora.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/host/sdhci.h')
-rw-r--r-- | drivers/mmc/host/sdhci.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h index 1fe230c2ed84..a6a3ddcf97e7 100644 --- a/drivers/mmc/host/sdhci.h +++ b/drivers/mmc/host/sdhci.h @@ -558,7 +558,8 @@ struct sdhci_host { dma_addr_t adma_addr; /* Mapped ADMA descr. table */ dma_addr_t align_addr; /* Mapped bounce buffer */ - unsigned int desc_sz; /* ADMA descriptor size */ + unsigned int desc_sz; /* ADMA current descriptor size */ + unsigned int alloc_desc_sz; /* ADMA descr. max size host supports */ struct workqueue_struct *complete_wq; /* Request completion wq */ struct work_struct complete_work; /* Request completion work */ |