Skip to content

Commit 24922c1

Browse files
krzkstorulf
authored andcommitted
mmc: sdhci_am654: Constify struct sdhci_ops
The local struct sdhci_ops can be made const for code safety. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Adrian Hunter <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Ulf Hansson <[email protected]>
1 parent 8fc516c commit 24922c1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/mmc/host/sdhci_am654.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -543,7 +543,7 @@ static int sdhci_am654_platform_execute_tuning(struct sdhci_host *host,
543543
return 0;
544544
}
545545

546-
static struct sdhci_ops sdhci_am654_ops = {
546+
static const struct sdhci_ops sdhci_am654_ops = {
547547
.platform_execute_tuning = sdhci_am654_platform_execute_tuning,
548548
.get_max_clock = sdhci_pltfm_clk_get_max_clock,
549549
.get_timeout_clock = sdhci_pltfm_clk_get_max_clock,
@@ -573,7 +573,7 @@ static const struct sdhci_am654_driver_data sdhci_am654_drvdata = {
573573
.flags = IOMUX_PRESENT | FREQSEL_2_BIT | STRBSEL_4_BIT | DLL_PRESENT,
574574
};
575575

576-
static struct sdhci_ops sdhci_j721e_8bit_ops = {
576+
static const struct sdhci_ops sdhci_j721e_8bit_ops = {
577577
.platform_execute_tuning = sdhci_am654_platform_execute_tuning,
578578
.get_max_clock = sdhci_pltfm_clk_get_max_clock,
579579
.get_timeout_clock = sdhci_pltfm_clk_get_max_clock,
@@ -597,7 +597,7 @@ static const struct sdhci_am654_driver_data sdhci_j721e_8bit_drvdata = {
597597
.flags = DLL_PRESENT | DLL_CALIB,
598598
};
599599

600-
static struct sdhci_ops sdhci_j721e_4bit_ops = {
600+
static const struct sdhci_ops sdhci_j721e_4bit_ops = {
601601
.platform_execute_tuning = sdhci_am654_platform_execute_tuning,
602602
.get_max_clock = sdhci_pltfm_clk_get_max_clock,
603603
.get_timeout_clock = sdhci_pltfm_clk_get_max_clock,

0 commit comments

Comments
 (0)