summaryrefslogtreecommitdiff
path: root/include/dwmmc.h
diff options
context:
space:
mode:
authorSam Protsenko <[email protected]>2024-08-07 22:14:31 -0500
committerMinkyu Kang <[email protected]>2024-08-19 16:09:06 +0900
commit56ba9455a5dc2faaf409aa4e403576ec9b85ac6c (patch)
treec150837ed5ba1099cc9c5178b70b48c71814a949 /include/dwmmc.h
parenta95b726e2e4a35de9b9694869293e40d3c82d754 (diff)
mmc: exynos_dw_mmc: Refactor fixed CIU clock divider
Some chips like Exynos4412 have fixed internal CIU clock divider. Instead of reading it from non-standard "div" dts property, store its value in the driver internally, in static chip data associated with corresponding compatible. This makes it possible to avoid using host->div for storing it, so the latter can be removed safely. Also create a helper function called exynos_dwmmc_get_ciu_div() for getting the current div value: in case the fixed div is provided in the chip data it will be used, otherwise the current div value is being read from CLKSEL register. The insights for this change were taken from dw_mmc-exynos.c driver in Linux kernel. No functional change. Signed-off-by: Sam Protsenko <[email protected]> Signed-off-by: Minkyu Kang <[email protected]>
Diffstat (limited to 'include/dwmmc.h')
-rw-r--r--include/dwmmc.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/include/dwmmc.h b/include/dwmmc.h
index a99b2f3bf0c..8c2500da9ef 100644
--- a/include/dwmmc.h
+++ b/include/dwmmc.h
@@ -184,7 +184,6 @@ struct dwmci_idmac_regs {
* @caps: Capabilities - see MMC_MODE_...
* @clock: Current clock frequency (after internal divider), Hz
* @bus_hz: Bus speed in Hz, if @get_mmc_clk() is NULL
- * @div: Arbitrary clock divider value for use by controller
* @dev_index: Arbitrary device index for use by controller
* @dev_id: Arbitrary device ID for use by controller
* @buswidth: Bus width in bits (8 or 4)
@@ -205,7 +204,6 @@ struct dwmci_host {
unsigned int caps;
unsigned int clock;
unsigned int bus_hz;
- unsigned int div;
int dev_index;
int dev_id;
int buswidth;