summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/sdhci-bcm-kona.c
diff options
context:
space:
mode:
authorJulia Lawall <Julia.Lawall@lip6.fr>2017-08-07 11:50:41 +0200
committerUlf Hansson <ulf.hansson@linaro.org>2017-08-30 14:01:52 +0200
commitb78f8a8c03405e508d95ab0442e88ec091926b96 (patch)
tree9e786ad72ddcd4fad9e37190f8da5bd586440d79 /drivers/mmc/host/sdhci-bcm-kona.c
parentd35ade8ff7e21d2a8ac57a994cf2cef3b599e9e3 (diff)
downloadlinux-stable-b78f8a8c03405e508d95ab0442e88ec091926b96.tar.gz
linux-stable-b78f8a8c03405e508d95ab0442e88ec091926b96.tar.bz2
linux-stable-b78f8a8c03405e508d95ab0442e88ec091926b96.zip
mmc: sdhci-bcm-kona: constify sdhci_pltfm_data and sdhci_ops structures
The sdhci_pltfm_data structure is only passed as the second argument of sdhci_pltfm_init, which is const, while the sdhci_ops structure is only stored in the ops field of a sdhci_pltfm_data structure, which is also const. Thus both kinds of structures can be const as well. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/host/sdhci-bcm-kona.c')
-rw-r--r--drivers/mmc/host/sdhci-bcm-kona.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/host/sdhci-bcm-kona.c b/drivers/mmc/host/sdhci-bcm-kona.c
index 51dd2fd65000..11ca95c60bcf 100644
--- a/drivers/mmc/host/sdhci-bcm-kona.c
+++ b/drivers/mmc/host/sdhci-bcm-kona.c
@@ -186,7 +186,7 @@ static void sdhci_bcm_kona_init_74_clocks(struct sdhci_host *host,
udelay(740);
}
-static struct sdhci_ops sdhci_bcm_kona_ops = {
+static const struct sdhci_ops sdhci_bcm_kona_ops = {
.set_clock = sdhci_set_clock,
.get_max_clock = sdhci_pltfm_clk_get_max_clock,
.get_timeout_clock = sdhci_pltfm_clk_get_max_clock,
@@ -197,7 +197,7 @@ static struct sdhci_ops sdhci_bcm_kona_ops = {
.card_event = sdhci_bcm_kona_card_event,
};
-static struct sdhci_pltfm_data sdhci_pltfm_data_kona = {
+static const struct sdhci_pltfm_data sdhci_pltfm_data_kona = {
.ops = &sdhci_bcm_kona_ops,
.quirks = SDHCI_QUIRK_NO_CARD_NO_RESET |
SDHCI_QUIRK_BROKEN_TIMEOUT_VAL | SDHCI_QUIRK_32BIT_DMA_ADDR |