]> git.karo-electronics.de Git - linux-beck.git/commitdiff
arm64: dts: db820c: add support to external sd card.
authorSrinivas Kandagatla <srinivas.kandagatla@linaro.org>
Tue, 21 Jun 2016 17:22:49 +0000 (18:22 +0100)
committerAndy Gross <andy.gross@linaro.org>
Thu, 25 Aug 2016 15:29:00 +0000 (10:29 -0500)
This patch adds support to external sd card.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
arch/arm64/boot/dts/qcom/apq8096-db820c-pins.dtsi [new file with mode: 0644]
arch/arm64/boot/dts/qcom/apq8096-db820c.dtsi

diff --git a/arch/arm64/boot/dts/qcom/apq8096-db820c-pins.dtsi b/arch/arm64/boot/dts/qcom/apq8096-db820c-pins.dtsi
new file mode 100644 (file)
index 0000000..24552f1
--- /dev/null
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2013-2016, The Linux Foundation. All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 and
+ * only version 2 as published by the Free Software Foundation.
+ *
+ * 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.
+ */
+&msmgpio {
+       sdc2_cd_on: sdc2_cd_on {
+               mux {
+                       pins = "gpio38";
+                       function = "gpio";
+               };
+
+               config {
+                       pins = "gpio38";
+                       bias-pull-up;           /* pull up */
+                       drive-strength = <16>;  /* 16 MA */
+               };
+       };
+
+       sdc2_cd_off: sdc2_cd_off {
+               mux {
+                       pins = "gpio38";
+                       function = "gpio";
+               };
+
+               config {
+                       pins = "gpio38";
+                       bias-pull-up;           /* pull up */
+                       drive-strength = <2>;   /* 2 MA */
+               };
+       };
+};
index adf7602b7c23d00e4c86c4f079311018abd437ee..afb218cffc6025dc841337330d38f5b14c93f3f8 100644 (file)
@@ -12,6 +12,7 @@
  */
 
 #include "msm8996.dtsi"
+#include "apq8096-db820c-pins.dtsi"
 
 / {
        aliases {
                        label = "HS-SPI1";
                        status = "okay";
                };
+
+               sdhci@74a4900 {
+               /* External SD card */
+                       pinctrl-names = "default", "sleep";
+                       pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on &sdc2_cd_on>;
+                       pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off &sdc2_cd_off>;
+                       cd-gpios = <&msmgpio 38 0x1>;
+                       status = "okay";
+               };
        };
 };