Skip to content

Commit 9cc811a

Browse files
pdp7storulf
authored andcommitted
mmc: sdhci: add __sdhci_execute_tuning() to header
Expose __sdhci_execute_tuning() so that it can be called from the mmc host controller drivers. In the sdhci-of-dwcmshc driver, sdhci_dwcmshc_th1520_ops sets platform_execute_tuning to th1520_execute_tuning(). That function has to manipulate phy registers before tuning can be performed. To avoid copying the code verbatim from __sdhci_execute_tuning() into th1520_execute_tuning(), make it possible for __sdhci_execute_tuning() to be called from sdhci-of-dwcmshc. Acked-by: Adrian Hunter <[email protected]> Signed-off-by: Drew Fustini <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Ulf Hansson <[email protected]>
1 parent edee955 commit 9cc811a

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

drivers/mmc/host/sdhci.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2841,7 +2841,7 @@ void sdhci_send_tuning(struct sdhci_host *host, u32 opcode)
28412841
}
28422842
EXPORT_SYMBOL_GPL(sdhci_send_tuning);
28432843

2844-
static int __sdhci_execute_tuning(struct sdhci_host *host, u32 opcode)
2844+
int __sdhci_execute_tuning(struct sdhci_host *host, u32 opcode)
28452845
{
28462846
int i;
28472847

@@ -2879,6 +2879,7 @@ static int __sdhci_execute_tuning(struct sdhci_host *host, u32 opcode)
28792879
sdhci_reset_tuning(host);
28802880
return -EAGAIN;
28812881
}
2882+
EXPORT_SYMBOL_GPL(__sdhci_execute_tuning);
28822883

28832884
int sdhci_execute_tuning(struct mmc_host *mmc, u32 opcode)
28842885
{

drivers/mmc/host/sdhci.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -793,6 +793,7 @@ void sdhci_set_bus_width(struct sdhci_host *host, int width);
793793
void sdhci_reset(struct sdhci_host *host, u8 mask);
794794
void sdhci_set_uhs_signaling(struct sdhci_host *host, unsigned timing);
795795
int sdhci_execute_tuning(struct mmc_host *mmc, u32 opcode);
796+
int __sdhci_execute_tuning(struct sdhci_host *host, u32 opcode);
796797
void sdhci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios);
797798
int sdhci_start_signal_voltage_switch(struct mmc_host *mmc,
798799
struct mmc_ios *ios);

0 commit comments

Comments
 (0)