summaryrefslogtreecommitdiff
path: root/include/sdhci.h
diff options
context:
space:
mode:
authorMichael Walle <michael@walle.cc>2020-09-23 13:42:51 +0300
committerPeng Fan <peng.fan@nxp.com>2020-10-12 10:50:19 +0300
commit4d6a773b1cfcb7e62d12dd31e588b5d00179b470 (patch)
tree262d88f7955fceeb8806c9675a42543e4fc8e8bc /include/sdhci.h
parent7e48a028a42c111ba38a90b86e5f57dace980fa0 (diff)
downloadu-boot-4d6a773b1cfcb7e62d12dd31e588b5d00179b470.tar.xz
mmc: sdhci: move the ADMA2 table handling into own module
There are other (non-SDHCI) controllers which supports ADMA2 descriptor tables, namely the Freescale eSDHC. Instead of copying the code, move it into an own module. Signed-off-by: Michael Walle <michael@walle.cc>
Diffstat (limited to 'include/sdhci.h')
-rw-r--r--include/sdhci.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/sdhci.h b/include/sdhci.h
index 94fc3ed56a..f69d5f81fb 100644
--- a/include/sdhci.h
+++ b/include/sdhci.h
@@ -271,7 +271,6 @@ struct sdhci_ops {
int (*deferred_probe)(struct sdhci_host *host);
};
-#if CONFIG_IS_ENABLED(MMC_SDHCI_ADMA)
#define ADMA_MAX_LEN 65532
#ifdef CONFIG_DMA_ADDR_T_64BIT
#define ADMA_DESC_LEN 16
@@ -302,7 +301,7 @@ struct sdhci_adma_desc {
u32 addr_hi;
#endif
} __packed;
-#endif
+
struct sdhci_host {
const char *name;
void *ioaddr;
@@ -334,7 +333,6 @@ struct sdhci_host {
dma_addr_t adma_addr;
#if CONFIG_IS_ENABLED(MMC_SDHCI_ADMA)
struct sdhci_adma_desc *adma_desc_table;
- uint desc_slot;
#endif
};
@@ -496,4 +494,8 @@ extern const struct dm_mmc_ops sdhci_ops;
#else
#endif
+struct sdhci_adma_desc *sdhci_adma_init(void);
+void sdhci_prepare_adma_table(struct sdhci_adma_desc *table,
+ struct mmc_data *data, dma_addr_t addr);
+
#endif /* __SDHCI_HW_H */