summaryrefslogtreecommitdiffstats
path: root/target/linux/ipq806x/patches-4.0
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/ipq806x/patches-4.0')
-rw-r--r--target/linux/ipq806x/patches-4.0/121-mfd-qcom_rpm-Add-support-for-IPQ8064.patch71
-rw-r--r--target/linux/ipq806x/patches-4.0/123-mfd-devicetree-qcom_rpm-Document-IPQ8064-resources.patch42
-rw-r--r--target/linux/ipq806x/patches-4.0/126-add-rpm-to-ipq8064-dts.patch87
-rw-r--r--target/linux/ipq806x/patches-4.0/700-add-gmac-dts-suport.patch6
4 files changed, 203 insertions, 3 deletions
diff --git a/target/linux/ipq806x/patches-4.0/121-mfd-qcom_rpm-Add-support-for-IPQ8064.patch b/target/linux/ipq806x/patches-4.0/121-mfd-qcom_rpm-Add-support-for-IPQ8064.patch
new file mode 100644
index 0000000000..e5e9e4e6cc
--- /dev/null
+++ b/target/linux/ipq806x/patches-4.0/121-mfd-qcom_rpm-Add-support-for-IPQ8064.patch
@@ -0,0 +1,71 @@
+From 4d54b0adfa67476e6509bc8646b9dbac642e8a29 Mon Sep 17 00:00:00 2001
+From: Josh Cartwright <joshc@codeaurora.org>
+Date: Thu, 26 Mar 2015 11:29:26 -0700
+Subject: [PATCH] mfd: qcom_rpm: Add support for IPQ8064
+
+The IPQ8064 also includes an RPM following the same message structure as
+other chips. In addition, it supports a few new resource types to
+support the NSS fabric clocks and the SMB208/SMB209 regulators found on
+the reference boards.
+
+Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
+Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+---
+ drivers/mfd/qcom_rpm.c | 41 +++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 41 insertions(+)
+
+--- a/drivers/mfd/qcom_rpm.c
++++ b/drivers/mfd/qcom_rpm.c
+@@ -323,10 +323,51 @@ static const struct qcom_rpm_data msm896
+ .n_resources = ARRAY_SIZE(msm8960_rpm_resource_table),
+ };
+
++static const struct qcom_rpm_resource ipq806x_rpm_resource_table[] = {
++ [QCOM_RPM_CXO_CLK] = { 25, 9, 5, 1 },
++ [QCOM_RPM_PXO_CLK] = { 26, 10, 6, 1 },
++ [QCOM_RPM_APPS_FABRIC_CLK] = { 27, 11, 8, 1 },
++ [QCOM_RPM_SYS_FABRIC_CLK] = { 28, 12, 9, 1 },
++ [QCOM_RPM_NSS_FABRIC_0_CLK] = { 29, 13, 10, 1 },
++ [QCOM_RPM_DAYTONA_FABRIC_CLK] = { 30, 14, 11, 1 },
++ [QCOM_RPM_SFPB_CLK] = { 31, 15, 12, 1 },
++ [QCOM_RPM_CFPB_CLK] = { 32, 16, 13, 1 },
++ [QCOM_RPM_NSS_FABRIC_1_CLK] = { 33, 17, 14, 1 },
++ [QCOM_RPM_EBI1_CLK] = { 34, 18, 16, 1 },
++ [QCOM_RPM_APPS_FABRIC_HALT] = { 35, 19, 18, 2 },
++ [QCOM_RPM_APPS_FABRIC_MODE] = { 37, 20, 19, 3 },
++ [QCOM_RPM_APPS_FABRIC_IOCTL] = { 40, 21, 20, 1 },
++ [QCOM_RPM_APPS_FABRIC_ARB] = { 41, 22, 21, 12 },
++ [QCOM_RPM_SYS_FABRIC_HALT] = { 53, 23, 22, 2 },
++ [QCOM_RPM_SYS_FABRIC_MODE] = { 55, 24, 23, 3 },
++ [QCOM_RPM_SYS_FABRIC_IOCTL] = { 58, 25, 24, 1 },
++ [QCOM_RPM_SYS_FABRIC_ARB] = { 59, 26, 25, 30 },
++ [QCOM_RPM_MM_FABRIC_HALT] = { 89, 27, 26, 2 },
++ [QCOM_RPM_MM_FABRIC_MODE] = { 91, 28, 27, 3 },
++ [QCOM_RPM_MM_FABRIC_IOCTL] = { 94, 29, 28, 1 },
++ [QCOM_RPM_MM_FABRIC_ARB] = { 95, 30, 29, 2 },
++ [QCOM_RPM_CXO_BUFFERS] = { 209, 33, 31, 1 },
++ [QCOM_RPM_USB_OTG_SWITCH] = { 210, 34, 32, 1 },
++ [QCOM_RPM_HDMI_SWITCH] = { 211, 35, 33, 1 },
++ [QCOM_RPM_DDR_DMM] = { 212, 36, 34, 2 },
++ [QCOM_RPM_VDDMIN_GPIO] = { 215, 40, 39, 1 },
++ [QCOM_RPM_SMB208_S1a] = { 216, 41, 90, 2 },
++ [QCOM_RPM_SMB208_S1b] = { 218, 43, 91, 2 },
++ [QCOM_RPM_SMB208_S2a] = { 220, 45, 92, 2 },
++ [QCOM_RPM_SMB208_S2b] = { 222, 47, 93, 2 },
++};
++
++static const struct qcom_rpm_data ipq806x_template = {
++ .version = 3,
++ .resource_table = ipq806x_rpm_resource_table,
++ .n_resources = ARRAY_SIZE(ipq806x_rpm_resource_table),
++};
++
+ static const struct of_device_id qcom_rpm_of_match[] = {
+ { .compatible = "qcom,rpm-apq8064", .data = &apq8064_template },
+ { .compatible = "qcom,rpm-msm8660", .data = &msm8660_template },
+ { .compatible = "qcom,rpm-msm8960", .data = &msm8960_template },
++ { .compatible = "qcom,rpm-ipq8064", .data = &ipq806x_template },
+ { }
+ };
+ MODULE_DEVICE_TABLE(of, qcom_rpm_of_match);
diff --git a/target/linux/ipq806x/patches-4.0/123-mfd-devicetree-qcom_rpm-Document-IPQ8064-resources.patch b/target/linux/ipq806x/patches-4.0/123-mfd-devicetree-qcom_rpm-Document-IPQ8064-resources.patch
new file mode 100644
index 0000000000..c8a9f3f5d0
--- /dev/null
+++ b/target/linux/ipq806x/patches-4.0/123-mfd-devicetree-qcom_rpm-Document-IPQ8064-resources.patch
@@ -0,0 +1,42 @@
+From 30bc3aa5c4ed3072bdff7d915772df1b91307ed4 Mon Sep 17 00:00:00 2001
+From: Josh Cartwright <joshc@codeaurora.org>
+Date: Thu, 26 Mar 2015 11:29:25 -0700
+Subject: [PATCH] mfd: devicetree: qcom_rpm: Document IPQ8064 resources
+
+The IPQ8064 SoC has several RPM-controlled resources, an NSS fabrick
+clock and four regulator resources. Provide definitions for them.
+
+Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
+[sboyd@codeaurora.org: Drop regulator part of binding]
+Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
+Signed-off-by: Lee Jones <lee.jones@linaro.org>
+---
+ Documentation/devicetree/bindings/mfd/qcom-rpm.txt | 1 +
+ include/dt-bindings/mfd/qcom-rpm.h | 6 ++++++
+ 2 files changed, 7 insertions(+)
+
+--- a/Documentation/devicetree/bindings/mfd/qcom-rpm.txt
++++ b/Documentation/devicetree/bindings/mfd/qcom-rpm.txt
+@@ -12,6 +12,7 @@ frequencies.
+ "qcom,rpm-apq8064"
+ "qcom,rpm-msm8660"
+ "qcom,rpm-msm8960"
++ "qcom,rpm-ipq8064"
+
+ - reg:
+ Usage: required
+--- a/include/dt-bindings/mfd/qcom-rpm.h
++++ b/include/dt-bindings/mfd/qcom-rpm.h
+@@ -141,6 +141,12 @@
+ #define QCOM_RPM_SYS_FABRIC_MODE 131
+ #define QCOM_RPM_USB_OTG_SWITCH 132
+ #define QCOM_RPM_VDDMIN_GPIO 133
++#define QCOM_RPM_NSS_FABRIC_0_CLK 134
++#define QCOM_RPM_NSS_FABRIC_1_CLK 135
++#define QCOM_RPM_SMB208_S1a 136
++#define QCOM_RPM_SMB208_S1b 137
++#define QCOM_RPM_SMB208_S2a 138
++#define QCOM_RPM_SMB208_S2b 139
+
+ /*
+ * Constants used to select force mode for regulators.
diff --git a/target/linux/ipq806x/patches-4.0/126-add-rpm-to-ipq8064-dts.patch b/target/linux/ipq806x/patches-4.0/126-add-rpm-to-ipq8064-dts.patch
new file mode 100644
index 0000000000..854131c7f6
--- /dev/null
+++ b/target/linux/ipq806x/patches-4.0/126-add-rpm-to-ipq8064-dts.patch
@@ -0,0 +1,87 @@
+--- a/arch/arm/boot/dts/qcom-ipq8064.dtsi
++++ b/arch/arm/boot/dts/qcom-ipq8064.dtsi
+@@ -2,6 +2,7 @@
+
+ #include "skeleton.dtsi"
+ #include <dt-bindings/clock/qcom,gcc-ipq806x.h>
++#include <dt-bindings/mfd/qcom-rpm.h>
+ #include <dt-bindings/soc/qcom,gsbi.h>
+ #include <dt-bindings/reset/qcom,gcc-ipq806x.h>
+
+@@ -75,6 +76,63 @@
+ ranges;
+ compatible = "simple-bus";
+
++ rpm@108000 {
++ compatible = "qcom,rpm-ipq8064";
++ reg = <0x108000 0x1000>;
++ qcom,ipc = <&l2cc 0x8 2>;
++
++ interrupts = <0 19 0>,
++ <0 21 0>,
++ <0 22 0>;
++ interrupt-names = "ack",
++ "err",
++ "wakeup";
++
++ #address-cells = <1>;
++ #size-cells = <0>;
++
++ smb208_s1a: smb208-s1a {
++ compatible = "qcom,rpm-smb208";
++ reg = <QCOM_RPM_SMB208_S1a>;
++
++ regulator-min-microvolt = <1050000>;
++ regulator-max-microvolt = <1150000>;
++
++ qcom,switch-mode-frequency = <1200000>;
++
++ };
++
++ smb208_s1b: smb208-s1b {
++ compatible = "qcom,rpm-smb208";
++ reg = <QCOM_RPM_SMB208_S1b>;
++
++ regulator-min-microvolt = <1050000>;
++ regulator-max-microvolt = <1150000>;
++
++ qcom,switch-mode-frequency = <1200000>;
++ };
++
++ smb208_s2a: smb208-s2a {
++ compatible = "qcom,rpm-smb208";
++ reg = <QCOM_RPM_SMB208_S2a>;
++
++ regulator-min-microvolt = < 800000>;
++ regulator-max-microvolt = <1250000>;
++
++ qcom,switch-mode-frequency = <1200000>;
++ };
++
++ smb208_s2b: smb208-s2b {
++ compatible = "qcom,rpm-smb208";
++ reg = <QCOM_RPM_SMB208_S2b>;
++
++ regulator-min-microvolt = < 800000>;
++ regulator-max-microvolt = <1250000>;
++
++ qcom,switch-mode-frequency = <1200000>;
++ };
++ };
++
+ qcom_pinmux: pinmux@800000 {
+ compatible = "qcom,ipq8064-pinctrl";
+ reg = <0x800000 0x4000>;
+@@ -119,6 +177,12 @@
+ reg = <0x02098000 0x1000>, <0x02008000 0x1000>;
+ };
+
++ l2cc: clock-controller@2011000 {
++ compatible = "qcom,kpss-gcc", "syscon";
++ reg = <0x2011000 0x1000>;
++ clock-output-names = "acpu_l2_aux";
++ };
++
+ saw0: regulator@2089000 {
+ compatible = "qcom,saw2";
+ reg = <0x02089000 0x1000>, <0x02009000 0x1000>;
diff --git a/target/linux/ipq806x/patches-4.0/700-add-gmac-dts-suport.patch b/target/linux/ipq806x/patches-4.0/700-add-gmac-dts-suport.patch
index b5643dfd17..25a9373208 100644
--- a/target/linux/ipq806x/patches-4.0/700-add-gmac-dts-suport.patch
+++ b/target/linux/ipq806x/patches-4.0/700-add-gmac-dts-suport.patch
@@ -119,15 +119,15 @@
};
--- a/arch/arm/boot/dts/qcom-ipq8064.dtsi
+++ b/arch/arm/boot/dts/qcom-ipq8064.dtsi
-@@ -4,6 +4,7 @@
- #include <dt-bindings/clock/qcom,gcc-ipq806x.h>
+@@ -5,6 +5,7 @@
+ #include <dt-bindings/mfd/qcom-rpm.h>
#include <dt-bindings/soc/qcom,gsbi.h>
#include <dt-bindings/reset/qcom,gcc-ipq806x.h>
+#include <dt-bindings/interrupt-controller/arm-gic.h>
/ {
model = "Qualcomm IPQ8064";
-@@ -415,5 +416,42 @@
+@@ -479,5 +480,42 @@
status = "disabled";
};