ARM: tegra: loki: fix build error due to warning
[linux-3.10.git] / arch / arm / mach-tegra / board-ardbeg-sdhci.c
index 26a250d..ab3a0eb 100644 (file)
@@ -35,6 +35,7 @@
 #include "gpio-names.h"
 #include "board.h"
 #include "board-ardbeg.h"
+#include "dvfs.h"
 #include "iomap.h"
 
 #define ARDBEG_WLAN_RST        TEGRA_GPIO_PCC5
@@ -156,7 +157,9 @@ static struct tegra_sdhci_platform_data tegra_sdhci_platform_data2 = {
        .power_gpio = -1,
        .tap_delay = 0,
        .trim_delay = 0x3,
-       .uhs_mask = MMC_UHS_MASK_SDR104 |
+/*FIXME: Enable UHS modes for SD */
+       .uhs_mask = MMC_UHS_MASK_SDR12 | MMC_UHS_MASK_SDR25 |
+                MMC_UHS_MASK_SDR104 |
                MMC_UHS_MASK_DDR50 | MMC_UHS_MASK_SDR50,
 /*     .max_clk = 12000000, */
 };
@@ -296,6 +299,33 @@ subsys_initcall_sync(ardbeg_wifi_prepower);
 
 int __init ardbeg_sdhci_init(void)
 {
+       int nominal_core_mv;
+       int min_vcore_override_mv;
+       int boot_vcore_mv;
+
+       nominal_core_mv =
+               tegra_dvfs_rail_get_nominal_millivolts(tegra_core_rail);
+       if (nominal_core_mv) {
+               tegra_sdhci_platform_data0.nominal_vcore_mv = nominal_core_mv;
+               tegra_sdhci_platform_data2.nominal_vcore_mv = nominal_core_mv;
+               tegra_sdhci_platform_data3.nominal_vcore_mv = nominal_core_mv;
+       }
+       min_vcore_override_mv =
+               tegra_dvfs_rail_get_override_floor(tegra_core_rail);
+       if (min_vcore_override_mv) {
+               tegra_sdhci_platform_data0.min_vcore_override_mv =
+                       min_vcore_override_mv;
+               tegra_sdhci_platform_data2.min_vcore_override_mv =
+                       min_vcore_override_mv;
+               tegra_sdhci_platform_data3.min_vcore_override_mv =
+                       min_vcore_override_mv;
+       }
+       boot_vcore_mv = tegra_dvfs_rail_get_boot_level(tegra_core_rail);
+       if (boot_vcore_mv) {
+               tegra_sdhci_platform_data0.boot_vcore_mv = boot_vcore_mv;
+               tegra_sdhci_platform_data2.boot_vcore_mv = boot_vcore_mv;
+               tegra_sdhci_platform_data3.boot_vcore_mv = boot_vcore_mv;
+       }
        platform_device_register(&tegra_sdhci_device3);
        platform_device_register(&tegra_sdhci_device2);
        platform_device_register(&tegra_sdhci_device0);