diff options
| -rw-r--r-- | drivers/mmc/host/sdhci-of-esdhc.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/mmc/host/sdhci-of-esdhc.c b/drivers/mmc/host/sdhci-of-esdhc.c index 77dfc5915ddc..44b016baa585 100644 --- a/drivers/mmc/host/sdhci-of-esdhc.c +++ b/drivers/mmc/host/sdhci-of-esdhc.c | |||
| @@ -457,6 +457,20 @@ static void esdhc_of_set_clock(struct sdhci_host *host, unsigned int clock) | |||
| 457 | if (esdhc->vendor_ver < VENDOR_V_23) | 457 | if (esdhc->vendor_ver < VENDOR_V_23) |
| 458 | pre_div = 2; | 458 | pre_div = 2; |
| 459 | 459 | ||
| 460 | /* | ||
| 461 | * Limit SD clock to 167MHz for ls1046a according to its datasheet | ||
| 462 | */ | ||
| 463 | if (clock > 167000000 && | ||
| 464 | of_find_compatible_node(NULL, NULL, "fsl,ls1046a-esdhc")) | ||
| 465 | clock = 167000000; | ||
| 466 | |||
| 467 | /* | ||
| 468 | * Limit SD clock to 125MHz for ls1012a according to its datasheet | ||
| 469 | */ | ||
| 470 | if (clock > 125000000 && | ||
| 471 | of_find_compatible_node(NULL, NULL, "fsl,ls1012a-esdhc")) | ||
| 472 | clock = 125000000; | ||
| 473 | |||
| 460 | /* Workaround to reduce the clock frequency for p1010 esdhc */ | 474 | /* Workaround to reduce the clock frequency for p1010 esdhc */ |
| 461 | if (of_find_compatible_node(NULL, NULL, "fsl,p1010-esdhc")) { | 475 | if (of_find_compatible_node(NULL, NULL, "fsl,p1010-esdhc")) { |
| 462 | if (clock > 20000000) | 476 | if (clock > 20000000) |
