mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-18 18:43:59 +08:00
mmc: sdhci: Add sdhci_adma_mark_end()
In preparation for 64-bit ADMA, separate out code that touches the ADMA descriptor by adding sdhci_adma_mark_end(). Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
This commit is contained in:
parent
4efaa6fbe1
commit
b5ffa6749c
@ -468,6 +468,13 @@ static void sdhci_adma_write_desc(u8 *desc, u32 addr, int len, unsigned cmd)
|
|||||||
dataddr[0] = cpu_to_le32(addr);
|
dataddr[0] = cpu_to_le32(addr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void sdhci_adma_mark_end(void *desc)
|
||||||
|
{
|
||||||
|
u8 *dma_desc = desc;
|
||||||
|
|
||||||
|
dma_desc[0] |= 0x2; /* end */
|
||||||
|
}
|
||||||
|
|
||||||
static int sdhci_adma_table_pre(struct sdhci_host *host,
|
static int sdhci_adma_table_pre(struct sdhci_host *host,
|
||||||
struct mmc_data *data)
|
struct mmc_data *data)
|
||||||
{
|
{
|
||||||
@ -564,7 +571,7 @@ static int sdhci_adma_table_pre(struct sdhci_host *host,
|
|||||||
*/
|
*/
|
||||||
if (desc != host->adma_table) {
|
if (desc != host->adma_table) {
|
||||||
desc -= 8;
|
desc -= 8;
|
||||||
desc[0] |= 0x2; /* end */
|
sdhci_adma_mark_end(desc);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user