Commit 2a9d6c80 authored by Patrice Chotard's avatar Patrice Chotard Committed by Ulf Hansson

mmc: mmci: Add STM32 variant

STM32F4 and STM32F7 MCUs has a SDIO controller that looks like
an ARM PL810.
This patch adds the STM32 variant so that mmci driver supports it.
Signed-off-by: default avatarAndrea Merello <andrea.merello@gmail.com>
Signed-off-by: default avatarPatrice Chotard <patrice.chotard@st.com>
Reviewed-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
parent f9bb304c
...@@ -244,6 +244,23 @@ static struct variant_data variant_ux500v2 = { ...@@ -244,6 +244,23 @@ static struct variant_data variant_ux500v2 = {
.opendrain = MCI_OD, .opendrain = MCI_OD,
}; };
static struct variant_data variant_stm32 = {
.fifosize = 32 * 4,
.fifohalfsize = 8 * 4,
.clkreg = MCI_CLK_ENABLE,
.clkreg_enable = MCI_ST_UX500_HWFCEN,
.clkreg_8bit_bus_enable = MCI_ST_8BIT_BUS,
.clkreg_neg_edge_enable = MCI_ST_UX500_NEG_EDGE,
.datalength_bits = 24,
.datactrl_mask_sdio = MCI_DPSM_ST_SDIOEN,
.st_sdio = true,
.st_clkdiv = true,
.pwrreg_powerup = MCI_PWR_ON,
.f_max = 48000000,
.pwrreg_clkgate = true,
.pwrreg_nopower = true,
};
static struct variant_data variant_qcom = { static struct variant_data variant_qcom = {
.fifosize = 16 * 4, .fifosize = 16 * 4,
.fifohalfsize = 8 * 4, .fifohalfsize = 8 * 4,
...@@ -2021,6 +2038,11 @@ static const struct amba_id mmci_ids[] = { ...@@ -2021,6 +2038,11 @@ static const struct amba_id mmci_ids[] = {
.mask = 0xf0ffffff, .mask = 0xf0ffffff,
.data = &variant_ux500v2, .data = &variant_ux500v2,
}, },
{
.id = 0x00880180,
.mask = 0x00ffffff,
.data = &variant_stm32,
},
/* Qualcomm variants */ /* Qualcomm variants */
{ {
.id = 0x00051180, .id = 0x00051180,
......
Markdown is supported
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