summaryrefslogtreecommitdiff
path: root/src/mainboard/google/veyron_emile/sdmmc.c
diff options
context:
space:
mode:
authorZhengShunQian <zhengsq@rock-chips.com>2015-10-22 10:45:23 +0800
committerPatrick Georgi <pgeorgi@google.com>2015-11-11 20:44:43 +0100
commit0dc117aa5d0375f0ef94824ceab399c8fe94b136 (patch)
tree6fd26ca111ff1bbb7ecaf709cf42a5003d5627f6 /src/mainboard/google/veyron_emile/sdmmc.c
parent278f20e88d565a0de5bd4beefc2a3dcfd209a89b (diff)
downloadcoreboot-0dc117aa5d0375f0ef94824ceab399c8fe94b136.tar.xz
google/veyron_emile: adjust to the spec of emile
o. Make some gpio changes base on Emile spec. o. Init sdmmc function. o. Revert cpu freq reducing in recovery mode since Emile have more effective thermal than Mickey. o. Revert the changes of lpddr3-samsung-2GB config. BUG=chrome-os-partner:46658 TEST=build and boot on Emile BRANCH=veyron Change-Id: Ibdc2ce511c8e215c202e2067d79f4c60cdfca738 Signed-off-by: Patrick Georgi <pgeorgi@chromium.org> Original-Commit-Id: 39e5436c8aa3353af77f62e548f48d19dc722999 Original-Change-Id: Ib2c78c9b5e3ac6620ab1772879a7ea0f7007f96e Original-Signed-off-by: ZhengShunQian <zhengsq@rock-chips.com> Original-Reviewed-on: https://chromium-review.googlesource.com/307651 Original-Commit-Ready: Shunqian Zheng <zhengsq@rock-chips.com> Original-Tested-by: Shunqian Zheng <zhengsq@rock-chips.com> Original-Reviewed-by: David Hendricks <dhendrix@chromium.org> Reviewed-on: http://review.coreboot.org/12396 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'src/mainboard/google/veyron_emile/sdmmc.c')
-rw-r--r--src/mainboard/google/veyron_emile/sdmmc.c38
1 files changed, 38 insertions, 0 deletions
diff --git a/src/mainboard/google/veyron_emile/sdmmc.c b/src/mainboard/google/veyron_emile/sdmmc.c
new file mode 100644
index 0000000000..3b3863836e
--- /dev/null
+++ b/src/mainboard/google/veyron_emile/sdmmc.c
@@ -0,0 +1,38 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright 2015 Google Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "board.h"
+
+#include <soc/rk808.h>
+
+static void sdmmc_power(int enable)
+{
+ rk808_configure_ldo(4, enable ? 3300 : 0); /* VCC33_SD_LDO */
+ rk808_configure_ldo(5, enable ? 3300 : 0); /* VCCIO_SD */
+}
+
+void sdmmc_power_off(void)
+{
+ sdmmc_power(0);
+}
+
+void sdmmc_power_on(void)
+{
+ sdmmc_power(1);
+}