Commit a2b0221c authored by Masahiro Yamada's avatar Masahiro Yamada Committed by Peng Fan
Browse files

mmc: sdhci: use lower_32_bit2() and upper_32_bits() for setting adma_addr

Use {lower,upper}_32_bits() instead of the combination of cast
and shift.

Signed-off-by: Masahiro Yamada's avatarMasahiro Yamada <>
Reviewed-by: Jaehoon Chung's avatarJaehoon Chung <>
parent f5df6aa1
......@@ -153,9 +153,10 @@ static void sdhci_prepare_dma(struct sdhci_host *host, struct mmc_data *data,
} else if (host->flags & (USE_ADMA | USE_ADMA64)) {
sdhci_prepare_adma_table(host, data);
sdhci_writel(host, (u32)host->adma_addr, SDHCI_ADMA_ADDRESS);
sdhci_writel(host, lower_32_bits(host->adma_addr),
if (host->flags & USE_ADMA64)
sdhci_writel(host, (u64)host->adma_addr >> 32,
sdhci_writel(host, upper_32_bits(host->adma_addr),
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment