Merge "msm: mdss: Set rotator output format as pseudo planar 420"
diff --git a/Documentation/devicetree/bindings/coresight/coresight.txt b/Documentation/devicetree/bindings/coresight/coresight.txt
index 17ff3f0..737e262 100644
--- a/Documentation/devicetree/bindings/coresight/coresight.txt
+++ b/Documentation/devicetree/bindings/coresight/coresight.txt
@@ -22,10 +22,24 @@
"arm,coresight-cti" for coresight cti devices,
"qcom,coresight-hwevent" for coresight hardware event devices
"arm,coresight-fuse" for coresight fuse device,
-- reg : physical base address and length of the register set(s) of the component
-- reg-names : names corresponding to each reg property value. The reg-names that
- need to be used with corresponding compatible string for a coresight device
- are:
+ "qcom,coresight-audio-etm" for coresight audio etm trace device,
+ "qcom,coresight-modem-etm" for coresight modem etm trace device,
+ "qcom,coresight-wcn-etm" for coresight wireless etm trace device,
+ "qcom,coresight-rpm-etm" for coresight rpm etm trace device
+- reg : physical base address and length of the register set(s) of the component.
+ Not required for the following compatible strings:
+ - "qcom,coresight-audio-etm",
+ - "qcom,coresight-modem-etm",
+ - "qcom,coresight-wcn-etm",
+ - "qcom,coresight-rpm-etm"
+- reg-names : names corresponding to each reg property value.
+ Not required for the following compatible strings:
+ - "qcom,coresight-audio-etm",
+ - "qcom,coresight-modem-etm",
+ - "qcom,coresight-wcn-etm",
+ - "qcom,coresight-rpm-etm"
+ The reg-names that need to be used with corresponding compatible string
+ for a coresight device are:
- for coresight tmc-etr or tmc-etf device:
compatible : should be "arm,coresight-tmc"
reg-names : should be:
diff --git a/Documentation/devicetree/bindings/fb/mdss-mdp.txt b/Documentation/devicetree/bindings/fb/mdss-mdp.txt
index bf30879..8f17a90 100644
--- a/Documentation/devicetree/bindings/fb/mdss-mdp.txt
+++ b/Documentation/devicetree/bindings/fb/mdss-mdp.txt
@@ -107,6 +107,7 @@
Optional properties:
- vdd-cx-supply : Phandle for vdd CX regulator device node.
+- batfet-supply : Phandle for battery FET regulator device node.
- qcom,vbif-settings : Array with key-value pairs of constant VBIF register
settings used to setup MDSS QoS for optimum performance.
The key used should be offset from "vbif_phys" register
@@ -179,6 +180,7 @@
interrupts = <0 72 0>;
vdd-supply = <&gdsc_mdss>;
vdd-cx-supply = <&pm8841_s2_corner>;
+ batfet-supply = <&pm8941_chg_batif>;
qcom,max-clk-rate = <320000000>;
qcom,vbif-settings = <0x0004 0x00000001>,
<0x00D8 0x00000707>;
diff --git a/arch/arm/boot/dts/apq8074-dragonboard.dtsi b/arch/arm/boot/dts/apq8074-dragonboard.dtsi
index 60bb518..8afd986 100644
--- a/arch/arm/boot/dts/apq8074-dragonboard.dtsi
+++ b/arch/arm/boot/dts/apq8074-dragonboard.dtsi
@@ -23,9 +23,12 @@
status = "ok";
};
- qcom,mdss_dsi_sharp_qhd_video {
- status = "ok";
- qcom,cont-splash-enabled;
+ qcom,mdss_dsi@fd922800 {
+ qcom,dsi-pref-prim-pan = <&dsi_sharp_qhd_vid>;
+ };
+
+ qcom,mdss_mdp@fd900000 {
+ qcom,mdss-pref-prim-intf = "dsi";
};
qcom,hdmi_tx@fd922100 {
@@ -670,3 +673,7 @@
qcom,pad-drv-off = <0x0 0x0 0x0>; /* 2mA, 2mA, 2mA */
status = "ok";
};
+
+&dsi_sharp_qhd_vid {
+ qcom,cont-splash-enabled;
+};
diff --git a/arch/arm/boot/dts/dsi-panel-jdi-1080p-video.dtsi b/arch/arm/boot/dts/dsi-panel-jdi-1080p-video.dtsi
new file mode 100644
index 0000000..1b64cf7
--- /dev/null
+++ b/arch/arm/boot/dts/dsi-panel-jdi-1080p-video.dtsi
@@ -0,0 +1,72 @@
+/* Copyright (c) 2013, 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.
+ */
+
+/*---------------------------------------------------------------------------
+ * This file is autogenerated file using gcdb parser. Please do not edit it.
+ * Update input XML file to add a new entry or update variable in this file
+ * VERSION = "1.0"
+ *---------------------------------------------------------------------------*/
+&mdss_mdp {
+ dsi_jdi_1080_vid: qcom,mdss_dsi_jdi_1080p_video {
+ qcom,mdss-dsi-panel-name = "jdi 1080p video mode dsi panel";
+ qcom,mdss-dsi-panel-controller = <&mdss_dsi0>;
+ qcom,mdss-dsi-panel-type = "dsi_video_mode";
+ qcom,mdss-dsi-panel-destination = "display_1";
+ qcom,mdss-dsi-panel-framerate = <60>;
+ qcom,mdss-dsi-virtual-channel-id = <0>;
+ qcom,mdss-dsi-stream = <0>;
+ qcom,mdss-dsi-panel-width = <1080>;
+ qcom,mdss-dsi-panel-height = <1920>;
+ qcom,mdss-dsi-h-front-porch = <96>;
+ qcom,mdss-dsi-h-back-porch = <64>;
+ qcom,mdss-dsi-h-pulse-width = <16>;
+ qcom,mdss-dsi-h-sync-skew = <0>;
+ qcom,mdss-dsi-v-back-porch = <4>;
+ qcom,mdss-dsi-v-front-porch = <3>;
+ qcom,mdss-dsi-v-pulse-width = <1>;
+ qcom,mdss-dsi-h-left-border = <0>;
+ qcom,mdss-dsi-h-right-border = <0>;
+ qcom,mdss-dsi-v-top-border = <0>;
+ qcom,mdss-dsi-v-bottom-border = <0>;
+ qcom,mdss-dsi-bpp = <24>;
+ qcom,mdss-dsi-color-order = <0>;
+ qcom,mdss-dsi-underflow-color = <0xff>;
+ qcom,mdss-dsi-border-color = <0>;
+ qcom,mdss-dsi-on-command = [15 01 00 00 00 00 02 55 00
+ 15 01 00 00 00 00 02 53 2C
+ 15 01 00 00 00 00 02 35 00
+ 05 01 00 00 78 00 02 29 00
+ 05 01 00 00 78 00 02 11 00];
+ qcom,mdss-dsi-off-command = [05 01 00 00 02 00 02 28 00
+ 05 01 00 00 79 00 02 10 00];
+ qcom,mdss-dsi-on-command-state = "dsi_lp_mode";
+ qcom,mdss-dsi-off-command-state = "dsi_hs_mode";
+ qcom,mdss-dsi-h-sync-pulse = <0>;
+ qcom,mdss-dsi-traffic-mode = <2>;
+ qcom,mdss-dsi-lane-map = <0>;
+ qcom,mdss-dsi-bllp-eof-power-mode;
+ qcom,mdss-dsi-bllp-power-mode;
+ qcom,mdss-dsi-lane-0-state;
+ qcom,mdss-dsi-lane-1-state;
+ qcom,mdss-dsi-lane-2-state;
+ qcom,mdss-dsi-lane-3-state;
+ qcom,mdss-dsi-panel-timings = [e1 37 25 00 67 6b 2a 3a 59 03 04 00];
+ qcom,mdss-dsi-t-clk-post = <0x04>;
+ qcom,mdss-dsi-t-clk-pre = <0x1b>;
+ qcom,mdss-dsi-bl-min-level = <1>;
+ qcom,mdss-dsi-bl-max-level = <4095>;
+ qcom,mdss-dsi-dma-trigger = <0x04>;
+ qcom,mdss-dsi-mdp-trigger = <0x0>;
+ qcom,mdss-dsi-bl-pmic-control-type = "bl_ctrl_wled";
+ qcom,mdss-dsi-reset-sequence = <1 20>, <0 200>, <1 20>;
+ };
+};
diff --git a/arch/arm/boot/dts/msm8610-qrd-skuab.dtsi b/arch/arm/boot/dts/msm8610-qrd-skuab.dtsi
index 17bf329..2fe6a34 100644
--- a/arch/arm/boot/dts/msm8610-qrd-skuab.dtsi
+++ b/arch/arm/boot/dts/msm8610-qrd-skuab.dtsi
@@ -44,6 +44,40 @@
focaltech,no-force-update;
focaltech,i2c-pull-up;
};
+ goodix@5d {
+ compatible = "goodix,gt9xx";
+ reg = <0x5d>;
+ interrupt-parent = <&msmgpio>;
+ interrupts = <1 0x2008>;
+ reset-gpios = <&msmgpio 0 0x00>;
+ interrupt-gpios = <&msmgpio 1 0x00>;
+ vdd-supply = <&pm8110_l19>;
+ vcc-i2c-supply = <&pm8110_l14>;
+ goodix,panel-coords = <0 0 540 980>;
+ goodix,display-coords = <0 0 540 960>;
+ goodix,button-map= <139 102 158>;
+ goodix,product-id = "915";
+ goodix,cfg-data0 = [
+ 46 1C 02 C0 03 0A 05 11 01 08
+ 14 3B 46 32 03 05 00 00 00 00
+ 00 00 00 00 00 00 00 8A 09 0B
+ 39 00 99 0A 00 00 02 83 03 1D
+ 00 08 00 00 00 00 00 00 00 00
+ 00 1D 73 94 C5 02 07 00 00 04
+ 78 21 00 5C 2C 00 48 3A 00 3A
+ 4C 00 2F 65 00 30 10 30 50 00
+ 56 45 35 FF FF 17 00 00 00 00
+ 00 01 1C 15 0C 14 5F 03 02 00
+ 00 00 00 00 00 00 00 00 00 00
+ 00 00 16 14 12 10 0E 0C 0A 08
+ 06 04 02 FF FF FF 00 00 00 00
+ 00 00 00 00 00 00 00 00 00 00
+ 00 00 22 21 20 1F 1E 1D 1C 18
+ 16 12 10 0F 0C 0A 08 06 04 02
+ 00 FF FF FF FF FF FF FF 00 00
+ 00 FF FF FF FF FF FF FF FF FF
+ F8 FF FF FF E4 01];
+ };
};
gen-vkeys {
compatible = "qcom,gen-vkeys";
@@ -55,6 +89,7 @@
qcom,key-codes = <139 102 158>;
qcom,y-offset = <0>;
};
+
i2c@f9925000 {
fsl@1c {
compatible = "fsl,mma8x5x";
diff --git a/arch/arm/boot/dts/msm8974-mdss-panels.dtsi b/arch/arm/boot/dts/msm8974-mdss-panels.dtsi
index 00fc779..d405bf8 100644
--- a/arch/arm/boot/dts/msm8974-mdss-panels.dtsi
+++ b/arch/arm/boot/dts/msm8974-mdss-panels.dtsi
@@ -14,3 +14,4 @@
/include/ "dsi-panel-toshiba-720p-video.dtsi"
/include/ "dsi-panel-sharp-qhd-video.dtsi"
/include/ "dsi-panel-generic-720p-cmd.dtsi"
+/include/ "dsi-panel-jdi-1080p-video.dtsi"
diff --git a/arch/arm/boot/dts/msm8974pro-ab-cdp.dts b/arch/arm/boot/dts/msm8974pro-ab-cdp.dts
deleted file mode 100644
index 646eb56..0000000
--- a/arch/arm/boot/dts/msm8974pro-ab-cdp.dts
+++ /dev/null
@@ -1,33 +0,0 @@
-/* Copyright (c) 2013, 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.
- */
-
-/dts-v1/;
-
-/include/ "msm8974pro-ab.dtsi"
-/include/ "msm8974-cdp.dtsi"
-
-/ {
- model = "Qualcomm MSM 8974Pro CDP";
- compatible = "qcom,msm8974-cdp", "qcom,msm8974", "qcom,cdp";
- qcom,msm-id = <208 1 0x10000>,
- <209 1 0x10000>,
- <211 1 0x10000>,
- <212 1 0x10000>,
- <214 1 0x10000>,
- <215 1 0x10000>,
- <217 1 0x10000>,
- <218 1 0x10000>,
- <194 1 0x10000>, /* 8974Pro-AC IDs */
- <210 1 0x10000>,
- <213 1 0x10000>,
- <216 1 0x10000>;
-};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-fluid.dts b/arch/arm/boot/dts/msm8974pro-ab-pm8941-cdp.dts
similarity index 61%
copy from arch/arm/boot/dts/msm8974pro-ab-fluid.dts
copy to arch/arm/boot/dts/msm8974pro-ab-pm8941-cdp.dts
index 9a31834..b6a6fcb 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-fluid.dts
+++ b/arch/arm/boot/dts/msm8974pro-ab-pm8941-cdp.dts
@@ -12,17 +12,11 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
-/include/ "msm8974-fluid.dtsi"
+/include/ "msm8974pro-ab-pm8941.dtsi"
+/include/ "msm8974-cdp.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro FLUID";
- compatible = "qcom,msm8974-fluid", "qcom,msm8974", "qcom,fluid";
- qcom,msm-id = <209 3 0x10000>,
- <211 3 0x10000>,
- <212 3 0x10000>,
- <214 3 0x10000>,
- <215 3 0x10000>,
- <217 3 0x10000>,
- <218 3 0x10000>;
+ model = "Qualcomm MSM 8974Pro-AA/AB CDP";
+ compatible = "qcom,msm8974-cdp", "qcom,msm8974", "qcom,cdp";
+ qcom,board-id = <1 0>;
};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-fluid.dts b/arch/arm/boot/dts/msm8974pro-ab-pm8941-fluid.dts
similarity index 71%
rename from arch/arm/boot/dts/msm8974pro-ab-fluid.dts
rename to arch/arm/boot/dts/msm8974pro-ab-pm8941-fluid.dts
index 9a31834..be298d1 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-fluid.dts
+++ b/arch/arm/boot/dts/msm8974pro-ab-pm8941-fluid.dts
@@ -12,17 +12,11 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
+/include/ "msm8974pro-ab-pm8941.dtsi"
/include/ "msm8974-fluid.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro FLUID";
+ model = "Qualcomm MSM 8974Pro-AA/AB FLUID";
compatible = "qcom,msm8974-fluid", "qcom,msm8974", "qcom,fluid";
- qcom,msm-id = <209 3 0x10000>,
- <211 3 0x10000>,
- <212 3 0x10000>,
- <214 3 0x10000>,
- <215 3 0x10000>,
- <217 3 0x10000>,
- <218 3 0x10000>;
+ qcom,board-id = <3 0>;
};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-liquid.dts b/arch/arm/boot/dts/msm8974pro-ab-pm8941-liquid.dts
similarity index 71%
copy from arch/arm/boot/dts/msm8974pro-ab-liquid.dts
copy to arch/arm/boot/dts/msm8974pro-ab-pm8941-liquid.dts
index 0ec9d8a..49c3df0 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-liquid.dts
+++ b/arch/arm/boot/dts/msm8974pro-ab-pm8941-liquid.dts
@@ -12,17 +12,11 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
+/include/ "msm8974pro-ab-pm8941.dtsi"
/include/ "msm8974-liquid.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro LIQUID";
+ model = "Qualcomm MSM 8974Pro-AA/AB LIQUID";
compatible = "qcom,msm8974-liquid", "qcom,msm8974", "qcom,liquid";
- qcom,msm-id = <209 9 0x10000>,
- <211 9 0x10000>,
- <212 9 0x10000>,
- <214 9 0x10000>,
- <215 9 0x10000>,
- <217 9 0x10000>,
- <218 9 0x10000>;
+ qcom,board-id = <9 0>;
};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-mtp.dts b/arch/arm/boot/dts/msm8974pro-ab-pm8941-mtp.dts
similarity index 73%
rename from arch/arm/boot/dts/msm8974pro-ab-mtp.dts
rename to arch/arm/boot/dts/msm8974pro-ab-pm8941-mtp.dts
index f61b4a6..fa313bf 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-mtp.dts
+++ b/arch/arm/boot/dts/msm8974pro-ab-pm8941-mtp.dts
@@ -12,19 +12,13 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
+/include/ "msm8974pro-ab-pm8941.dtsi"
/include/ "msm8974-mtp.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro MTP";
+ model = "Qualcomm MSM 8974Pro-AA/AB MTP";
compatible = "qcom,msm8974-mtp", "qcom,msm8974", "qcom,mtp";
- qcom,msm-id = <209 8 0x10000>,
- <211 8 0x10000>,
- <212 8 0x10000>,
- <214 8 0x10000>,
- <215 8 0x10000>,
- <217 8 0x10000>,
- <218 8 0x10000>;
+ qcom,board-id = <8 0>;
};
&sdhc_1 {
diff --git a/arch/arm/boot/dts/msm8974pro-ab-pm8941.dtsi b/arch/arm/boot/dts/msm8974pro-ab-pm8941.dtsi
new file mode 100644
index 0000000..a44bc56
--- /dev/null
+++ b/arch/arm/boot/dts/msm8974pro-ab-pm8941.dtsi
@@ -0,0 +1,24 @@
+/* Copyright (c) 2013, 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.
+ */
+
+/include/ "msm8974pro-pm8941.dtsi"
+
+/ {
+ qcom,msm-id = <208 0x10000>,
+ <209 0x10000>,
+ <211 0x10000>,
+ <212 0x10000>,
+ <214 0x10000>,
+ <215 0x10000>,
+ <217 0x10000>,
+ <218 0x10000>;
+};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-fluid.dts b/arch/arm/boot/dts/msm8974pro-ac-pm8941-cdp.dts
similarity index 61%
copy from arch/arm/boot/dts/msm8974pro-ab-fluid.dts
copy to arch/arm/boot/dts/msm8974pro-ac-pm8941-cdp.dts
index 9a31834..3e0feda 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-fluid.dts
+++ b/arch/arm/boot/dts/msm8974pro-ac-pm8941-cdp.dts
@@ -12,17 +12,11 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
-/include/ "msm8974-fluid.dtsi"
+/include/ "msm8974pro-ac-pm8941.dtsi"
+/include/ "msm8974-cdp.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro FLUID";
- compatible = "qcom,msm8974-fluid", "qcom,msm8974", "qcom,fluid";
- qcom,msm-id = <209 3 0x10000>,
- <211 3 0x10000>,
- <212 3 0x10000>,
- <214 3 0x10000>,
- <215 3 0x10000>,
- <217 3 0x10000>,
- <218 3 0x10000>;
+ model = "Qualcomm MSM 8974Pro-AC CDP";
+ compatible = "qcom,msm8974-cdp", "qcom,msm8974", "qcom,cdp";
+ qcom,board-id = <1 0>;
};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-liquid.dts b/arch/arm/boot/dts/msm8974pro-ac-pm8941-liquid.dts
similarity index 71%
rename from arch/arm/boot/dts/msm8974pro-ab-liquid.dts
rename to arch/arm/boot/dts/msm8974pro-ac-pm8941-liquid.dts
index 0ec9d8a..7b88abe 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-liquid.dts
+++ b/arch/arm/boot/dts/msm8974pro-ac-pm8941-liquid.dts
@@ -12,17 +12,11 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
+/include/ "msm8974pro-ac-pm8941.dtsi"
/include/ "msm8974-liquid.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro LIQUID";
+ model = "Qualcomm MSM 8974Pro-AC LIQUID";
compatible = "qcom,msm8974-liquid", "qcom,msm8974", "qcom,liquid";
- qcom,msm-id = <209 9 0x10000>,
- <211 9 0x10000>,
- <212 9 0x10000>,
- <214 9 0x10000>,
- <215 9 0x10000>,
- <217 9 0x10000>,
- <218 9 0x10000>;
+ qcom,board-id = <9 0>;
};
diff --git a/arch/arm/boot/dts/msm8974pro-ab-mtp.dts b/arch/arm/boot/dts/msm8974pro-ac-pm8941-mtp.dts
similarity index 61%
copy from arch/arm/boot/dts/msm8974pro-ab-mtp.dts
copy to arch/arm/boot/dts/msm8974pro-ac-pm8941-mtp.dts
index f61b4a6..f79d361 100644
--- a/arch/arm/boot/dts/msm8974pro-ab-mtp.dts
+++ b/arch/arm/boot/dts/msm8974pro-ac-pm8941-mtp.dts
@@ -12,21 +12,19 @@
/dts-v1/;
-/include/ "msm8974pro-ab.dtsi"
+/include/ "msm8974pro-ac-pm8941.dtsi"
/include/ "msm8974-mtp.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro MTP";
+ model = "Qualcomm MSM 8974Pro-AC MTP";
compatible = "qcom,msm8974-mtp", "qcom,msm8974", "qcom,mtp";
- qcom,msm-id = <209 8 0x10000>,
- <211 8 0x10000>,
- <212 8 0x10000>,
- <214 8 0x10000>,
- <215 8 0x10000>,
- <217 8 0x10000>,
- <218 8 0x10000>;
+ qcom,board-id = <8 0>;
};
&sdhc_1 {
- qcom,pad-drv-on = <0x4 0x4 0x4>; /* 10mA, 10mA, 10mA */
+ qcom,clk-rates = <400000 20000000 25000000 50000000 100000000 192000000 384000000>;
+ qcom,bus-speed-mode = "HS400_1p8v", "HS200_1p8v", "DDR_1p8v";
+
+ qcom,pad-pull-on = <0x0 0x3 0x3 0x1>; /* no-pull, pull-up, pull-up, pull-down */
+ qcom,pad-pull-off = <0x0 0x3 0x3 0x1>; /* no-pull, pull-up, pull-up, pull-down */
};
diff --git a/arch/arm/boot/dts/msm8974pro-ac-pm8941.dtsi b/arch/arm/boot/dts/msm8974pro-ac-pm8941.dtsi
index 811b2ef..cdcfecb 100644
--- a/arch/arm/boot/dts/msm8974pro-ac-pm8941.dtsi
+++ b/arch/arm/boot/dts/msm8974pro-ac-pm8941.dtsi
@@ -10,247 +10,15 @@
* GNU General Public License for more details.
*/
-/include/ "msm8974pro-ac.dtsi"
-&spmi_bus {
- pm8941_lsid0: qcom,pm8941@2 {
- reg = <0x2>;
- };
- pm8941_lsid1: qcom,pm8941@3 {
- reg = <0x3>;
- };
-};
-/include/ "msm-pm8941.dtsi"
+/include/ "msm8974pro-pm8941.dtsi"
-&pm8941_lsid0 {
- qcom,power-on@800 {
- status = "disabled";
- };
-
- clkdiv@5b00 {
- status = "disabled";
- };
-
- clkdiv@5c00 {
- status = "disabled";
- };
-
- clkdiv@5d00 {
- status = "disabled";
- };
-
- qcom,pm8941_rtc {
- status = "disabled";
- };
-
- gpios {
- status = "disabled";
- };
-
- mpps {
- status = "disabled";
- };
+/ {
+ qcom,msm-id = <194 0x10000>,
+ <210 0x10000>,
+ <213 0x10000>,
+ <216 0x10000>;
};
-&pm8941_lsid1 {
- pm8941_boost: regulator@a000 {
- regulator-min-microvolt = <5000000>;
- regulator-max-microvolt = <5000000>;
- qcom,enable-time = <500>;
- status = "okay";
- };
-
- pm8941_mvs1: regulator@8300 {
- parent-supply = <&pm8941_chg_otg>;
- qcom,enable-time = <1000>;
- qcom,pull-down-enable = <1>;
- interrupts = <0x3 0x83 0x2>;
- interrupt-names = "ocp";
- qcom,ocp-enable = <1>;
- qcom,ocp-max-retries = <10>;
- qcom,ocp-retry-delay = <30>;
- qcom,soft-start-enable = <1>;
- qcom,vs-soft-start-strength = <0>;
- qcom,hpm-enable = <1>;
- qcom,auto-mode-enable = <0>;
- status = "okay";
- };
-};
-
-&pma8084_mvs1 {
- parent-supply = <&pm8941_boost>;
-};
-
-&pm8941_chg {
- otg-parent-supply = <&pm8941_boost>;
-};
-
-&pm8941_chg_boost {
- regulator-min-microvolt = <5000000>;
- regulator-max-microvolt = <5000000>;
- regulator-name = "8941_smbb_boost";
-};
-
-&pm8941_chg_batif {
- regulator-name = "batfet";
-};
-
-&pm8941_chg_otg {
- regulator-name = "8941_smbb_otg";
-};
-
-&usb3 {
- vbus_dwc3-supply = <&pm8941_mvs1>;
- qcom,misc-ref = <&pm8941_misc>;
- dwc_usb3-adc_tm = <&pm8941_adc_tm>;
- interrupt-map-mask = <0x0 0xffffffff>;
- interrupt-map = <0x0 0 &intc 0 133 0
- 0x0 1 &spmi_bus 0x0 0x2 0x9 0x0>;
- interrupt-names = "hs_phy_irq", "pmic_id_irq";
-};
-
-/* Correct PM8941 local slave ID 0 to use global SID 4 for all interrupts. */
-&pm8941_lsid0 {
- qcom,temp-alarm@2400 {
- interrupts = <0x2 0x24 0x0>;
- };
-
- qcom,power-on@800 {
- interrupts = <0x2 0x8 0x0>,
- <0x2 0x8 0x1>,
- <0x2 0x8 0x4>,
- <0x2 0x8 0x5>;
- interrupt-names = "kpdpwr", "resin",
- "resin-bark", "kpdpwr-resin-bark";
- };
-
- qcom,bsi@1b00 {
- interrupts = <0x2 0x1b 0x0>,
- <0x2 0x1b 0x1>,
- <0x2 0x1b 0x2>,
- <0x2 0x12 0x0>;
- interrupt-names = "err",
- "rx",
- "tx",
- "batt-present";
- };
-
- qcom,bms {
- qcom,bms-bms@4000 {
- interrupts = <0x2 0x40 0x0>,
- <0x2 0x40 0x1>,
- <0x2 0x40 0x2>,
- <0x2 0x40 0x3>,
- <0x2 0x40 0x4>,
- <0x2 0x40 0x5>,
- <0x2 0x40 0x6>,
- <0x2 0x40 0x7>;
- interrupt-names = "cc_thr",
- "ocv_for_r",
- "good_ocv",
- "charge_begin",
- "ocv_thr",
- "sw_cc_thr",
- "vsense_avg",
- "vsense_for_r";
- };
- };
-
- qcom,charger {
- qcom,chgr@1000 {
- interrupts = <0x2 0x10 0x0>,
- <0x2 0x10 0x1>,
- <0x2 0x10 0x2>,
- <0x2 0x10 0x3>,
- <0x2 0x10 0x4>,
- <0x2 0x10 0x5>,
- <0x2 0x10 0x6>,
- <0x2 0x10 0x7>;
- interrupt-names = "vbat-det-lo",
- "vbat-det-hi",
- "chgwdog",
- "state-change",
- "trkl-chg-on",
- "fast-chg-on",
- "chg-failed",
- "chg-done";
- };
-
- qcom,buck@1100 {
- interrupts = <0x2 0x11 0x0>,
- <0x2 0x11 0x1>,
- <0x2 0x11 0x2>,
- <0x2 0x11 0x3>,
- <0x2 0x11 0x4>,
- <0x2 0x11 0x5>,
- <0x2 0x11 0x6>;
- interrupt-names = "vbat-ov",
- "vreg-ov",
- "overtemp",
- "vchg-loop",
- "ichg-loop",
- "ibat-loop",
- "vdd-loop";
- };
-
- qcom,bat-if@1200 {
- interrupts = <0x2 0x12 0x0>,
- <0x2 0x12 0x1>,
- <0x2 0x12 0x2>,
- <0x2 0x12 0x3>,
- <0x2 0x12 0x4>;
- interrupt-names = "batt-pres",
- "bat-temp-ok",
- "bat-fet-on",
- "vcp-on",
- "psi";
- };
-
- qcom,usb-chgpth@1300 {
- interrupts = <0x2 0x13 0x0>,
- <0x2 0x13 0x1>,
- <0x2 0x13 0x2>;
- interrupt-names = "coarse-det-usb",
- "usbin-valid",
- "chg-gone";
- };
-
- qcom,dc-chgpth@1400 {
- interrupts = <0x2 0x14 0x0>,
- <0x2 0x14 0x1>;
- interrupt-names = "coarse-det-dc",
- "dcin-valid";
- };
-
- qcom,boost@1500 {
- interrupts = <0x2 0x15 0x0>,
- <0x2 0x15 0x1>;
- interrupt-names = "boost-pwr-ok",
- "limit-error";
- };
- };
-
- qcom,pm8941_rtc {
- qcom,pm8941_rtc_alarm@6100 {
- interrupts = <0x2 0x61 0x1>;
- };
- };
-
- vadc@3100 {
- interrupts = <0x2 0x31 0x0>;
- interrupt-names = "eoc-int-en-set";
- };
-
- iadc@3600 {
- interrupts = <0x2 0x36 0x0>;
- interrupt-names = "eoc-int-en-set";
- };
-
- qcom,vadc@3400 {
- interrupts = <0x2 0x34 0x0>,
- <0x2 0x34 0x3>,
- <0x2 0x34 0x4>;
- interrupt-names = "eoc-int-en-set",
- "high-thr-en-set",
- "low-thr-en-set";
- };
+&sdhc_1 {
+ reg = <0xf9824900 0x1a0>, <0xf9824000 0x800>;
};
diff --git a/arch/arm/boot/dts/msm8974pro-ac-mtp.dts b/arch/arm/boot/dts/msm8974pro-ac-pma8084-pm8941-mtp.dts
similarity index 82%
rename from arch/arm/boot/dts/msm8974pro-ac-mtp.dts
rename to arch/arm/boot/dts/msm8974pro-ac-pma8084-pm8941-mtp.dts
index e1d7605..8a4ad45 100644
--- a/arch/arm/boot/dts/msm8974pro-ac-mtp.dts
+++ b/arch/arm/boot/dts/msm8974pro-ac-pma8084-pm8941-mtp.dts
@@ -12,16 +12,13 @@
/dts-v1/;
-/include/ "msm8974pro-ac-pm8941.dtsi"
-/include/ "msm8974pro-ac-mtp.dtsi"
+/include/ "msm8974pro-ac-pma8084-pm8941.dtsi"
+/include/ "msm8974pro-pma8084-mtp.dtsi"
/ {
- model = "Qualcomm MSM 8974Pro-AC MTP";
+ model = "Qualcomm MSM 8974Pro-AC + PMA8084 MTP";
compatible = "qcom,msm8974-mtp", "qcom,msm8974", "qcom,mtp";
- qcom,msm-id = <194 8 0x10000>,
- <210 8 0x10000>,
- <213 8 0x10000>,
- <216 8 0x10000>;
+ qcom,board-id = <8 1>;
};
&pma8084_vadc {
@@ -123,12 +120,3 @@
qcom,thermal-node;
};
};
-
-&sdhc_1 {
- reg = <0xf9824900 0x1a0>, <0xf9824000 0x800>;
- qcom,clk-rates = <400000 20000000 25000000 50000000 100000000 200000000 384000000>;
- qcom,bus-speed-mode = "HS400_1p8v", "HS200_1p8v", "DDR_1p8v";
-
- qcom,pad-pull-on = <0x0 0x3 0x3 0x1>; /* no-pull, pull-up, pull-up, pull-down */
- qcom,pad-pull-off = <0x0 0x3 0x3 0x1>; /* no-pull, pull-up, pull-up, pull-down */
-};
diff --git a/arch/arm/boot/dts/msm8974pro-ac-pma8084-pm8941.dtsi b/arch/arm/boot/dts/msm8974pro-ac-pma8084-pm8941.dtsi
new file mode 100644
index 0000000..746702b
--- /dev/null
+++ b/arch/arm/boot/dts/msm8974pro-ac-pma8084-pm8941.dtsi
@@ -0,0 +1,256 @@
+/* Copyright (c) 2013, 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.
+ */
+
+/include/ "msm8974pro-ac-pma8084.dtsi"
+&spmi_bus {
+ pm8941_lsid0: qcom,pm8941@2 {
+ reg = <0x2>;
+ };
+ pm8941_lsid1: qcom,pm8941@3 {
+ reg = <0x3>;
+ };
+};
+/include/ "msm-pm8941.dtsi"
+
+&pm8941_lsid0 {
+ qcom,power-on@800 {
+ status = "disabled";
+ };
+
+ clkdiv@5b00 {
+ status = "disabled";
+ };
+
+ clkdiv@5c00 {
+ status = "disabled";
+ };
+
+ clkdiv@5d00 {
+ status = "disabled";
+ };
+
+ qcom,pm8941_rtc {
+ status = "disabled";
+ };
+
+ gpios {
+ status = "disabled";
+ };
+
+ mpps {
+ status = "disabled";
+ };
+};
+
+&pm8941_lsid1 {
+ pm8941_boost: regulator@a000 {
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ qcom,enable-time = <500>;
+ status = "okay";
+ };
+
+ pm8941_mvs1: regulator@8300 {
+ parent-supply = <&pm8941_chg_otg>;
+ qcom,enable-time = <1000>;
+ qcom,pull-down-enable = <1>;
+ interrupts = <0x3 0x83 0x2>;
+ interrupt-names = "ocp";
+ qcom,ocp-enable = <1>;
+ qcom,ocp-max-retries = <10>;
+ qcom,ocp-retry-delay = <30>;
+ qcom,soft-start-enable = <1>;
+ qcom,vs-soft-start-strength = <0>;
+ qcom,hpm-enable = <1>;
+ qcom,auto-mode-enable = <0>;
+ status = "okay";
+ };
+};
+
+&pma8084_mvs1 {
+ parent-supply = <&pm8941_boost>;
+};
+
+&pm8941_chg {
+ otg-parent-supply = <&pm8941_boost>;
+};
+
+&pm8941_chg_boost {
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ regulator-name = "8941_smbb_boost";
+};
+
+&pm8941_chg_batif {
+ regulator-name = "batfet";
+};
+
+&pm8941_chg_otg {
+ regulator-name = "8941_smbb_otg";
+};
+
+&usb3 {
+ vbus_dwc3-supply = <&pm8941_mvs1>;
+ qcom,misc-ref = <&pm8941_misc>;
+ dwc_usb3-adc_tm = <&pm8941_adc_tm>;
+ interrupt-map-mask = <0x0 0xffffffff>;
+ interrupt-map = <0x0 0 &intc 0 133 0
+ 0x0 1 &spmi_bus 0x0 0x2 0x9 0x0>;
+ interrupt-names = "hs_phy_irq", "pmic_id_irq";
+};
+
+/* Correct PM8941 local slave ID 0 to use global SID 4 for all interrupts. */
+&pm8941_lsid0 {
+ qcom,temp-alarm@2400 {
+ interrupts = <0x2 0x24 0x0>;
+ };
+
+ qcom,power-on@800 {
+ interrupts = <0x2 0x8 0x0>,
+ <0x2 0x8 0x1>,
+ <0x2 0x8 0x4>,
+ <0x2 0x8 0x5>;
+ interrupt-names = "kpdpwr", "resin",
+ "resin-bark", "kpdpwr-resin-bark";
+ };
+
+ qcom,bsi@1b00 {
+ interrupts = <0x2 0x1b 0x0>,
+ <0x2 0x1b 0x1>,
+ <0x2 0x1b 0x2>,
+ <0x2 0x12 0x0>;
+ interrupt-names = "err",
+ "rx",
+ "tx",
+ "batt-present";
+ };
+
+ qcom,bms {
+ qcom,bms-bms@4000 {
+ interrupts = <0x2 0x40 0x0>,
+ <0x2 0x40 0x1>,
+ <0x2 0x40 0x2>,
+ <0x2 0x40 0x3>,
+ <0x2 0x40 0x4>,
+ <0x2 0x40 0x5>,
+ <0x2 0x40 0x6>,
+ <0x2 0x40 0x7>;
+ interrupt-names = "cc_thr",
+ "ocv_for_r",
+ "good_ocv",
+ "charge_begin",
+ "ocv_thr",
+ "sw_cc_thr",
+ "vsense_avg",
+ "vsense_for_r";
+ };
+ };
+
+ qcom,charger {
+ qcom,chgr@1000 {
+ interrupts = <0x2 0x10 0x0>,
+ <0x2 0x10 0x1>,
+ <0x2 0x10 0x2>,
+ <0x2 0x10 0x3>,
+ <0x2 0x10 0x4>,
+ <0x2 0x10 0x5>,
+ <0x2 0x10 0x6>,
+ <0x2 0x10 0x7>;
+ interrupt-names = "vbat-det-lo",
+ "vbat-det-hi",
+ "chgwdog",
+ "state-change",
+ "trkl-chg-on",
+ "fast-chg-on",
+ "chg-failed",
+ "chg-done";
+ };
+
+ qcom,buck@1100 {
+ interrupts = <0x2 0x11 0x0>,
+ <0x2 0x11 0x1>,
+ <0x2 0x11 0x2>,
+ <0x2 0x11 0x3>,
+ <0x2 0x11 0x4>,
+ <0x2 0x11 0x5>,
+ <0x2 0x11 0x6>;
+ interrupt-names = "vbat-ov",
+ "vreg-ov",
+ "overtemp",
+ "vchg-loop",
+ "ichg-loop",
+ "ibat-loop",
+ "vdd-loop";
+ };
+
+ qcom,bat-if@1200 {
+ interrupts = <0x2 0x12 0x0>,
+ <0x2 0x12 0x1>,
+ <0x2 0x12 0x2>,
+ <0x2 0x12 0x3>,
+ <0x2 0x12 0x4>;
+ interrupt-names = "batt-pres",
+ "bat-temp-ok",
+ "bat-fet-on",
+ "vcp-on",
+ "psi";
+ };
+
+ qcom,usb-chgpth@1300 {
+ interrupts = <0x2 0x13 0x0>,
+ <0x2 0x13 0x1>,
+ <0x2 0x13 0x2>;
+ interrupt-names = "coarse-det-usb",
+ "usbin-valid",
+ "chg-gone";
+ };
+
+ qcom,dc-chgpth@1400 {
+ interrupts = <0x2 0x14 0x0>,
+ <0x2 0x14 0x1>;
+ interrupt-names = "coarse-det-dc",
+ "dcin-valid";
+ };
+
+ qcom,boost@1500 {
+ interrupts = <0x2 0x15 0x0>,
+ <0x2 0x15 0x1>;
+ interrupt-names = "boost-pwr-ok",
+ "limit-error";
+ };
+ };
+
+ qcom,pm8941_rtc {
+ qcom,pm8941_rtc_alarm@6100 {
+ interrupts = <0x2 0x61 0x1>;
+ };
+ };
+
+ vadc@3100 {
+ interrupts = <0x2 0x31 0x0>;
+ interrupt-names = "eoc-int-en-set";
+ };
+
+ iadc@3600 {
+ interrupts = <0x2 0x36 0x0>;
+ interrupt-names = "eoc-int-en-set";
+ };
+
+ qcom,vadc@3400 {
+ interrupts = <0x2 0x34 0x0>,
+ <0x2 0x34 0x3>,
+ <0x2 0x34 0x4>;
+ interrupt-names = "eoc-int-en-set",
+ "high-thr-en-set",
+ "low-thr-en-set";
+ };
+};
diff --git a/arch/arm/boot/dts/msm8974pro-ac-pma8084.dtsi b/arch/arm/boot/dts/msm8974pro-ac-pma8084.dtsi
new file mode 100644
index 0000000..4b7ed1d
--- /dev/null
+++ b/arch/arm/boot/dts/msm8974pro-ac-pma8084.dtsi
@@ -0,0 +1,24 @@
+/* Copyright (c) 2013, 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.
+ */
+
+/include/ "msm8974pro-pma8084.dtsi"
+
+/ {
+ qcom,msm-id = <194 0x10000>,
+ <210 0x10000>,
+ <213 0x10000>,
+ <216 0x10000>;
+};
+
+&sdhc_1 {
+ reg = <0xf9824900 0x1a0>, <0xf9824000 0x800>;
+};
diff --git a/arch/arm/boot/dts/msm8974pro-ab.dtsi b/arch/arm/boot/dts/msm8974pro-pm8941.dtsi
similarity index 100%
rename from arch/arm/boot/dts/msm8974pro-ab.dtsi
rename to arch/arm/boot/dts/msm8974pro-pm8941.dtsi
diff --git a/arch/arm/boot/dts/msm8974pro-ac-mtp.dtsi b/arch/arm/boot/dts/msm8974pro-pma8084-mtp.dtsi
similarity index 95%
rename from arch/arm/boot/dts/msm8974pro-ac-mtp.dtsi
rename to arch/arm/boot/dts/msm8974pro-pma8084-mtp.dtsi
index cdb4ed0..26fdebb 100644
--- a/arch/arm/boot/dts/msm8974pro-ac-mtp.dtsi
+++ b/arch/arm/boot/dts/msm8974pro-pma8084-mtp.dtsi
@@ -91,6 +91,12 @@
&sdhc_1 {
vdd-supply = <&pma8084_l20>;
vdd-io-supply = <&pma8084_s4>;
+
+ qcom,clk-rates = <400000 20000000 25000000 50000000 100000000 200000000 384000000>;
+ qcom,bus-speed-mode = "HS400_1p8v", "HS200_1p8v", "DDR_1p8v";
+
+ qcom,pad-pull-on = <0x0 0x3 0x3 0x1>; /* no-pull, pull-up, pull-up, pull-down */
+ qcom,pad-pull-off = <0x0 0x3 0x3 0x1>; /* no-pull, pull-up, pull-up, pull-down */
};
&sdhc_2 {
diff --git a/arch/arm/boot/dts/msm8974pro-ac-regulator.dtsi b/arch/arm/boot/dts/msm8974pro-pma8084-regulator.dtsi
similarity index 100%
rename from arch/arm/boot/dts/msm8974pro-ac-regulator.dtsi
rename to arch/arm/boot/dts/msm8974pro-pma8084-regulator.dtsi
diff --git a/arch/arm/boot/dts/msm8974pro-ac.dtsi b/arch/arm/boot/dts/msm8974pro-pma8084.dtsi
similarity index 98%
rename from arch/arm/boot/dts/msm8974pro-ac.dtsi
rename to arch/arm/boot/dts/msm8974pro-pma8084.dtsi
index f8a371d..cd485c5 100644
--- a/arch/arm/boot/dts/msm8974pro-ac.dtsi
+++ b/arch/arm/boot/dts/msm8974pro-pma8084.dtsi
@@ -20,7 +20,7 @@
/include/ "msm-pma8084-rpm-regulator.dtsi"
/include/ "msm-pma8084.dtsi"
-/include/ "msm8974pro-ac-regulator.dtsi"
+/include/ "msm8974pro-pma8084-regulator.dtsi"
/*
* Override PM8841 and PM8941 resources with proper PMA8084 resources for
diff --git a/arch/arm/configs/msm8610-perf_defconfig b/arch/arm/configs/msm8610-perf_defconfig
index c572ad8..325aba1 100644
--- a/arch/arm/configs/msm8610-perf_defconfig
+++ b/arch/arm/configs/msm8610-perf_defconfig
@@ -234,6 +234,8 @@
CONFIG_TOUCHSCREEN_SYNAPTICS_I2C_RMI4=y
CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_RMI4_DEV=y
CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE=y
+CONFIG_TOUCHSCREEN_GT9XX=y
+CONFIG_GT9XX_TOUCHPANEL_DRIVER=y
CONFIG_INPUT_MISC=y
CONFIG_INPUT_UINPUT=y
CONFIG_INPUT_GPIO=m
diff --git a/arch/arm/configs/msm8610_defconfig b/arch/arm/configs/msm8610_defconfig
index 6a7097d..2c5363d 100644
--- a/arch/arm/configs/msm8610_defconfig
+++ b/arch/arm/configs/msm8610_defconfig
@@ -236,6 +236,8 @@
CONFIG_TOUCHSCREEN_SYNAPTICS_I2C_RMI4=y
CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_RMI4_DEV=y
CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE=y
+CONFIG_TOUCHSCREEN_GT9XX=y
+CONFIG_GT9XX_TOUCHPANEL_DRIVER=y
CONFIG_INPUT_MISC=y
CONFIG_INPUT_UINPUT=y
CONFIG_INPUT_GPIO=m
diff --git a/arch/arm/mach-msm/Makefile.boot b/arch/arm/mach-msm/Makefile.boot
index 910264e..552ed16 100644
--- a/arch/arm/mach-msm/Makefile.boot
+++ b/arch/arm/mach-msm/Makefile.boot
@@ -67,11 +67,14 @@
dtb-$(CONFIG_ARCH_MSM8974) += msm8974-v2.2-fluid.dtb
dtb-$(CONFIG_ARCH_MSM8974) += msm8974-v2.2-liquid.dtb
dtb-$(CONFIG_ARCH_MSM8974) += msm8974-v2.2-mtp.dtb
- dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-cdp.dtb
- dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-fluid.dtb
- dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-liquid.dtb
- dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-mtp.dtb
- dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ac-mtp.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-pm8941-cdp.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-pm8941-fluid.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-pm8941-liquid.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ab-pm8941-mtp.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ac-pm8941-cdp.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ac-pm8941-liquid.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ac-pm8941-mtp.dtb
+ dtb-$(CONFIG_ARCH_MSM8974) += msm8974pro-ac-pma8084-pm8941-mtp.dtb
# APQ8084
zreladdr-$(CONFIG_ARCH_APQ8084) := 0x00008000
diff --git a/arch/arm/mach-msm/acpuclock-8974.c b/arch/arm/mach-msm/acpuclock-8974.c
index 3e488e3..66534eb 100644
--- a/arch/arm/mach-msm/acpuclock-8974.c
+++ b/arch/arm/mach-msm/acpuclock-8974.c
@@ -273,10 +273,10 @@
[10] = { { 1036800, HFPLL, 1, 54 }, LVL_NOM, 950000, 5 },
[11] = { { 1113600, HFPLL, 1, 58 }, LVL_HIGH, 1050000, 6 },
[12] = { { 1190400, HFPLL, 1, 62 }, LVL_HIGH, 1050000, 6 },
- [13] = { { 1267200, HFPLL, 1, 66 }, LVL_HIGH, 1050000, 7 },
- [14] = { { 1344000, HFPLL, 1, 70 }, LVL_HIGH, 1050000, 7 },
- [15] = { { 1420800, HFPLL, 1, 74 }, LVL_HIGH, 1050000, 7 },
- [16] = { { 1497600, HFPLL, 1, 78 }, LVL_HIGH, 1050000, 7 },
+ [13] = { { 1267200, HFPLL, 1, 66 }, LVL_HIGH, 1050000, 6 },
+ [14] = { { 1344000, HFPLL, 1, 70 }, LVL_HIGH, 1050000, 6 },
+ [15] = { { 1420800, HFPLL, 1, 74 }, LVL_HIGH, 1050000, 6 },
+ [16] = { { 1497600, HFPLL, 1, 78 }, LVL_HIGH, 1050000, 6 },
[17] = { { 1574400, HFPLL, 1, 82 }, LVL_HIGH, 1050000, 7 },
[18] = { { 1651200, HFPLL, 1, 86 }, LVL_HIGH, 1050000, 7 },
[19] = { { 1728000, HFPLL, 1, 90 }, LVL_HIGH, 1050000, 8 },
@@ -900,219 +900,226 @@
};
static struct acpu_level pro_rev0_2p3g_pvs0[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 775000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 775000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 780000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 790000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 800000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 810000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 820000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 830000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 840000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 850000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 865000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 875000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 890000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 900000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 915000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 925000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 940000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 955000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 970000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 985000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 1000000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1015000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1030000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1045000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1060000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1075000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 775000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 775000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 780000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 790000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 800000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 810000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 820000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 830000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 840000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 850000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 865000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 875000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 890000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 900000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 915000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 925000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 940000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 955000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 970000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 985000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 1000000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1015000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1030000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1045000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1060000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1060000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1075000, 708 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p3g_pvs1[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 775000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 775000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 775000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 775000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 785000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 795000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 805000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 815000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 825000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 835000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 850000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 860000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 870000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 885000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 895000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 905000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 920000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 935000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 950000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 965000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 980000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 995000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1005000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1020000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1035000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1050000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 775000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 775000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 775000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 775000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 785000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 795000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 805000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 815000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 825000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 835000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 850000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 860000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 870000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 885000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 895000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 905000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 920000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 935000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 950000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 965000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 980000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 995000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1005000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1020000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1035000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1035000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1050000, 708 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p3g_pvs2[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 760000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 770000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 780000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 790000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 800000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 810000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 820000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 830000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 840000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 850000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 865000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 875000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 885000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 900000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 915000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 930000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 945000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 955000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 970000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 980000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 995000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1010000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1025000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 760000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 770000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 780000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 790000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 800000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 810000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 820000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 830000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 840000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 850000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 865000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 875000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 885000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 900000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 915000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 930000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 945000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 955000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 970000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 980000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 995000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1010000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1010000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1025000, 708 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p3g_pvs3[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 755000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 765000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 775000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 785000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 795000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 805000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 815000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 825000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 835000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 850000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 860000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 870000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 885000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 900000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 910000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 925000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 935000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 945000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 960000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 970000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 985000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1000000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 755000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 765000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 775000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 785000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 795000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 805000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 815000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 825000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 835000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 850000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 860000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 870000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 885000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 900000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 910000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 925000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 935000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 945000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 960000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 970000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 985000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 985000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1000000, 708 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p3g_pvs4[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 750000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 755000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 765000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 775000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 785000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 795000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 805000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 815000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 825000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 835000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 845000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 855000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 870000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 885000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 895000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 905000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 915000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 925000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 935000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 950000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 960000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 975000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 750000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 755000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 765000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 775000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 785000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 795000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 805000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 815000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 825000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 835000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 845000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 855000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 870000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 885000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 895000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 905000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 915000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 925000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 935000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 950000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 960000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 960000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 975000, 708 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p3g_pvs5[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 725000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 725000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 725000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 725000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 725000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 735000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 745000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 755000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 765000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 775000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 785000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 795000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 805000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 815000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 825000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 835000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 845000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 855000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 865000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 875000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 885000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 895000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 905000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 915000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 930000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 940000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 950000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 725000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 725000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 725000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 725000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 725000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 735000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 745000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 755000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 765000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 775000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 785000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 795000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 805000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 815000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 825000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 835000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 845000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 855000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 865000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 875000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 885000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 895000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 905000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 915000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 930000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 940000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 940000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 950000, 708 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p3g_pvs6[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 725000, 72 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 725000, 83 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 725000, 101 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 725000, 120 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 725000, 139 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 725000, 159 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 735000, 180 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 745000, 200 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 755000, 221 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 765000, 242 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 775000, 264 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 785000, 287 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 795000, 308 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 805000, 333 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 815000, 356 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 825000, 380 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 835000, 404 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 845000, 430 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 850000, 456 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 860000, 482 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 870000, 510 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 880000, 538 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 890000, 565 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 895000, 596 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 905000, 627 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 915000, 659 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 925000, 691 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 725000, 74 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 725000, 85 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 725000, 104 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 725000, 124 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 725000, 144 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 725000, 164 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 735000, 184 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 745000, 206 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 755000, 227 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 765000, 249 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 775000, 271 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 785000, 295 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 795000, 318 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 805000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 815000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 825000, 392 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 835000, 416 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 845000, 442 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 850000, 469 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 860000, 497 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 870000, 525 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 880000, 554 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 890000, 583 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 895000, 613 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 905000, 642 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 915000, 663 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 915000, 675 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 925000, 708 },
{ 0, { 0 } }
};
@@ -1122,31 +1129,32 @@
{ 1, { 422400, HFPLL, 2, 44 }, L2(2), 800000, 106 },
{ 0, { 499200, HFPLL, 2, 52 }, L2(2), 800000, 125 },
{ 0, { 576000, HFPLL, 1, 30 }, L2(3), 800000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 800000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 800000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 800000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 800000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 800000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 805000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 815000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 825000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 835000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 845000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 855000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 870000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 885000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 900000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 915000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 930000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 945000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 960000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 980000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1000000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1020000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1040000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1060000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1080000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 1100000, 800 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 810000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 820000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 830000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 840000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 850000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 860000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 870000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 880000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 890000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 900000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 910000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 920000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 930000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 945000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 960000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 975000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 990000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1005000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1020000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1035000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1050000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1050000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1065000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1080000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1095000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 1100000, 785 },
{ 0, { 0 } }
};
@@ -1156,31 +1164,32 @@
{ 1, { 422400, HFPLL, 2, 44 }, L2(2), 800000, 106 },
{ 0, { 499200, HFPLL, 2, 52 }, L2(2), 800000, 125 },
{ 0, { 576000, HFPLL, 1, 30 }, L2(3), 800000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 800000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 800000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 800000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 800000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 800000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 800000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 805000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 815000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 825000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 835000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 845000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 855000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 870000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 885000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 900000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 915000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 930000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 945000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 960000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 975000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 995000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1015000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1035000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1055000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 1075000, 800 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 800000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 800000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 805000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 815000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 825000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 835000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 845000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 855000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 865000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 875000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 885000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 895000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 905000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 920000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 935000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 950000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 965000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 980000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 995000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1010000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1025000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1025000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1040000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1055000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1070000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 1075000, 785 },
{ 0, { 0 } }
};
@@ -1190,31 +1199,32 @@
{ 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 106 },
{ 0, { 499200, HFPLL, 2, 52 }, L2(2), 775000, 125 },
{ 0, { 576000, HFPLL, 1, 30 }, L2(3), 775000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 775000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 775000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 775000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 775000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 775000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 780000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 790000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 800000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 810000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 820000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 830000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 840000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 850000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 865000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 880000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 895000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 910000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 925000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 940000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 955000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 970000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 990000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1010000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1030000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 1050000, 800 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 775000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 775000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 780000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 790000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 800000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 810000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 820000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 830000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 840000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 850000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 860000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 870000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 880000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 895000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 910000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 925000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 940000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 955000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 970000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 985000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1000000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1000000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1015000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1030000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1045000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 1050000, 785 },
{ 0, { 0 } }
};
@@ -1224,65 +1234,67 @@
{ 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 106 },
{ 0, { 499200, HFPLL, 2, 52 }, L2(2), 775000, 125 },
{ 0, { 576000, HFPLL, 1, 30 }, L2(3), 775000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 775000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 775000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 775000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 775000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 775000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 775000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 780000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 790000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 800000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 810000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 820000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 830000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 840000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 850000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 865000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 880000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 895000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 910000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 925000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 940000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 955000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 970000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 985000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1005000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 1025000, 800 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 775000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 775000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 775000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 775000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 780000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 785000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 795000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 805000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 815000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 825000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 835000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 845000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 855000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 870000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 885000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 900000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 915000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 930000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 945000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 960000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 975000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 975000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 990000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1005000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 1020000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 1025000, 785 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p5g_pvs4[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 76 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 87 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 106 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 125 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 750000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 750000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 750000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 750000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 750000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 760000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 770000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 780000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 790000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 800000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 810000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 820000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 830000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 840000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 850000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 865000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 880000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 895000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 910000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 925000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 940000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 955000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 970000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 985000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 1000000, 800 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 775000, 76 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 775000, 87 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 775000, 106 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 775000, 125 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 775000, 145 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 775000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 775000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 775000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 775000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 775000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 775000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 775000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 780000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 790000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 800000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 810000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 820000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 830000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 845000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 860000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 875000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 890000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 905000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 920000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 935000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 950000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 950000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 965000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 980000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 995000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 1000000, 785 },
{ 0, { 0 } }
};
@@ -1292,65 +1304,67 @@
{ 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 106 },
{ 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 125 },
{ 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 750000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 750000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 750000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 750000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 750000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 750000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 760000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 770000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 780000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 790000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 800000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 810000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 820000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 830000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 840000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 850000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 860000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 870000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 885000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 900000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 915000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 930000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 945000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 960000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 975000, 800 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 750000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 750000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 750000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 750000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 750000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 750000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 750000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 760000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 770000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 780000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 790000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 800000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 810000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 820000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 835000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 850000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 865000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 880000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 895000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 910000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 925000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 925000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 940000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 955000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 970000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 975000, 785 },
{ 0, { 0 } }
};
static struct acpu_level pro_rev0_2p5g_pvs6[] __initdata = {
- { 1, { 300000, PLL_0, 0, 0 }, L2(0), 725000, 76 },
- { 0, { 345600, HFPLL, 2, 36 }, L2(1), 725000, 87 },
- { 1, { 422400, HFPLL, 2, 44 }, L2(2), 725000, 106 },
- { 0, { 499200, HFPLL, 2, 52 }, L2(2), 725000, 125 },
- { 0, { 576000, HFPLL, 1, 30 }, L2(3), 725000, 145 },
- { 1, { 652800, HFPLL, 1, 34 }, L2(3), 725000, 164 },
- { 1, { 729600, HFPLL, 1, 38 }, L2(4), 725000, 183 },
- { 0, { 806400, HFPLL, 1, 42 }, L2(4), 725000, 202 },
- { 1, { 883200, HFPLL, 1, 46 }, L2(4), 725000, 222 },
- { 1, { 960000, HFPLL, 1, 50 }, L2(9), 725000, 241 },
- { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 735000, 261 },
- { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 745000, 282 },
- { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 755000, 305 },
- { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 765000, 327 },
- { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 775000, 350 },
- { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 785000, 373 },
- { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 795000, 398 },
- { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 805000, 424 },
- { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 815000, 449 },
- { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 825000, 476 },
- { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 835000, 503 },
- { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 845000, 530 },
- { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 855000, 559 },
- { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 865000, 590 },
- { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 875000, 621 },
- { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 890000, 654 },
- { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 905000, 686 },
- { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 920000, 723 },
- { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 935000, 761 },
- { 1, { 2496000, HFPLL, 1, 130 }, L2(19), 950000, 800 },
+ { 1, { 300000, PLL_0, 0, 0 }, L2(0), 750000, 76 },
+ { 0, { 345600, HFPLL, 2, 36 }, L2(1), 750000, 87 },
+ { 1, { 422400, HFPLL, 2, 44 }, L2(2), 750000, 106 },
+ { 0, { 499200, HFPLL, 2, 52 }, L2(2), 750000, 125 },
+ { 0, { 576000, HFPLL, 1, 30 }, L2(3), 750000, 145 },
+ { 1, { 652800, HFPLL, 1, 34 }, L2(3), 750000, 165 },
+ { 1, { 729600, HFPLL, 1, 38 }, L2(4), 750000, 186 },
+ { 0, { 806400, HFPLL, 1, 42 }, L2(4), 750000, 208 },
+ { 1, { 883200, HFPLL, 1, 46 }, L2(4), 750000, 229 },
+ { 1, { 960000, HFPLL, 1, 50 }, L2(9), 750000, 251 },
+ { 1, { 1036800, HFPLL, 1, 54 }, L2(10), 750000, 273 },
+ { 0, { 1113600, HFPLL, 1, 58 }, L2(10), 750000, 296 },
+ { 1, { 1190400, HFPLL, 1, 62 }, L2(10), 750000, 319 },
+ { 1, { 1267200, HFPLL, 1, 66 }, L2(13), 755000, 342 },
+ { 0, { 1344000, HFPLL, 1, 70 }, L2(14), 765000, 365 },
+ { 0, { 1420800, HFPLL, 1, 74 }, L2(15), 775000, 390 },
+ { 1, { 1497600, HFPLL, 1, 78 }, L2(16), 785000, 415 },
+ { 1, { 1574400, HFPLL, 1, 82 }, L2(17), 795000, 439 },
+ { 0, { 1651200, HFPLL, 1, 86 }, L2(17), 805000, 465 },
+ { 1, { 1728000, HFPLL, 1, 90 }, L2(18), 815000, 493 },
+ { 0, { 1804800, HFPLL, 1, 94 }, L2(18), 825000, 521 },
+ { 0, { 1881600, HFPLL, 1, 98 }, L2(18), 840000, 549 },
+ { 1, { 1958400, HFPLL, 1, 102 }, L2(19), 855000, 579 },
+ { 0, { 2035200, HFPLL, 1, 106 }, L2(19), 870000, 608 },
+ { 0, { 2112000, HFPLL, 1, 110 }, L2(19), 885000, 638 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 900000, 667 },
+ { 0, { 2188800, HFPLL, 1, 114 }, L2(19), 900000, 667 },
+ { 1, { 2265600, HFPLL, 1, 118 }, L2(19), 915000, 700 },
+ { 0, { 2342400, HFPLL, 1, 122 }, L2(19), 930000, 734 },
+ { 0, { 2419200, HFPLL, 1, 126 }, L2(19), 945000, 769 },
+ { 1, { 2457600, HFPLL, 1, 128 }, L2(19), 950000, 785 },
{ 0, { 0 } }
};
@@ -1380,6 +1394,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1025000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1040000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1055000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1070000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1070000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1085000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1100000, 751 },
@@ -1414,6 +1429,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1015000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1030000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1045000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1060000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1060000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1075000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1090000, 751 },
@@ -1448,6 +1464,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1005000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1020000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1035000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1050000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1050000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1065000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1080000, 751 },
@@ -1482,6 +1499,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 995000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1010000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1025000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1040000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1040000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1055000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1070000, 751 },
@@ -1516,6 +1534,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 985000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1000000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1015000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1030000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1030000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1045000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1060000, 751 },
@@ -1550,6 +1569,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 975000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 990000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1005000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1020000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1020000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1035000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1050000, 751 },
@@ -1584,6 +1604,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 965000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 980000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 995000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1010000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1010000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1025000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1040000, 751 },
@@ -1618,6 +1639,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 955000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 970000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 985000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1000000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1000000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1015000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1030000, 751 },
@@ -1652,6 +1674,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 945000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 960000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 975000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 990000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 990000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1005000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1020000, 751 },
@@ -1686,6 +1709,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 935000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 950000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 965000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 980000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 980000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 995000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1010000, 751 },
@@ -1720,6 +1744,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 925000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 940000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 955000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 970000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 970000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 985000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 1000000, 751 },
@@ -1754,6 +1779,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 915000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 930000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 945000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 960000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 960000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 975000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 990000, 751 },
@@ -1788,6 +1814,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 905000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 920000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 935000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 950000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 950000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 965000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 980000, 751 },
@@ -1822,6 +1849,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 895000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 910000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 925000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 940000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 940000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 955000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 970000, 751 },
@@ -1856,6 +1884,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 885000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 900000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 915000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 930000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 930000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 945000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 960000, 751 },
@@ -1890,6 +1919,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 875000, 588 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 890000, 617 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 905000, 649 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 920000, 682 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 920000, 682 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 935000, 716 },
{ 0, { 2342400, HFPLL, 1, 122 }, L2(19), 950000, 751 },
@@ -1924,6 +1954,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1060000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1075000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1090000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1105000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1105000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1120000, 738 },
{ 0, { 0 } }
@@ -1955,6 +1986,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1050000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1065000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1080000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1095000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1095000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1110000, 738 },
{ 0, { 0 } }
@@ -1986,6 +2018,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1040000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1055000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1070000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1085000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1085000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1100000, 738 },
{ 0, { 0 } }
@@ -2017,6 +2050,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1030000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1045000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1060000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1075000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1075000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1090000, 738 },
{ 0, { 0 } }
@@ -2048,6 +2082,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1020000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1035000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1050000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1065000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1065000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1080000, 738 },
{ 0, { 0 } }
@@ -2079,6 +2114,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1010000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1025000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1040000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1055000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1055000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1070000, 738 },
{ 0, { 0 } }
@@ -2110,6 +2146,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 1000000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1015000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1030000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1045000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1045000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1060000, 738 },
{ 0, { 0 } }
@@ -2141,6 +2178,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 990000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 1005000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1020000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1035000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1035000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1050000, 738 },
{ 0, { 0 } }
@@ -2172,6 +2210,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 980000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 995000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1010000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1025000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1025000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1040000, 738 },
{ 0, { 0 } }
@@ -2203,6 +2242,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 970000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 985000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 1000000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1015000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1015000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1030000, 738 },
{ 0, { 0 } }
@@ -2234,6 +2274,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 960000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 975000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 990000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 1005000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 1005000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1020000, 738 },
{ 0, { 0 } }
@@ -2265,6 +2306,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 950000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 965000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 980000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 995000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 995000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1010000, 738 },
{ 0, { 0 } }
@@ -2296,6 +2338,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 940000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 955000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 970000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 985000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 985000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 1000000, 738 },
{ 0, { 0 } }
@@ -2327,6 +2370,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 930000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 945000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 960000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 975000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 975000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 990000, 738 },
{ 0, { 0 } }
@@ -2358,6 +2402,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 920000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 935000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 950000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 965000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 965000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 980000, 738 },
{ 0, { 0 } }
@@ -2389,6 +2434,7 @@
{ 1, { 1958400, HFPLL, 1, 102 }, L2(19), 910000, 604 },
{ 0, { 2035200, HFPLL, 1, 106 }, L2(19), 925000, 636 },
{ 0, { 2112000, HFPLL, 1, 110 }, L2(19), 940000, 669 },
+ { 0, { 2150400, HFPLL, 1, 112 }, L2(19), 955000, 703 },
{ 0, { 2188800, HFPLL, 1, 114 }, L2(19), 955000, 703 },
{ 1, { 2265600, HFPLL, 1, 118 }, L2(19), 970000, 738 },
{ 0, { 0 } }
diff --git a/arch/arm/mach-msm/msm_bus/msm_bus_fabric.c b/arch/arm/mach-msm/msm_bus/msm_bus_fabric.c
index ddf747e..7c694a7 100644
--- a/arch/arm/mach-msm/msm_bus/msm_bus_fabric.c
+++ b/arch/arm/mach-msm/msm_bus/msm_bus_fabric.c
@@ -766,6 +766,8 @@
pdata = msm_bus_of_get_fab_data(pdev);
if (IS_ERR(pdata) || ZERO_OR_NULL_PTR(pdata)) {
pr_err("Null platform data\n");
+ kfree(fabric->info.node_info);
+ kfree(fabric);
return PTR_ERR(pdata);
}
msm_bus_board_init(pdata);
diff --git a/arch/arm/mach-msm/pil-pronto.c b/arch/arm/mach-msm/pil-pronto.c
index 620ab5c..69df3ae 100644
--- a/arch/arm/mach-msm/pil-pronto.c
+++ b/arch/arm/mach-msm/pil-pronto.c
@@ -334,7 +334,7 @@
pr_err("Ignoring wcnss bite irq, restart in progress\n");
return IRQ_HANDLED;
}
- wcnss_pronto_log_debug_regs();
+ wcnss_log_debug_regs_on_bite();
drv->restart_inprogress = true;
restart_wcnss(drv);
diff --git a/arch/arm/mach-msm/pil-q6v5-lpass.c b/arch/arm/mach-msm/pil-q6v5-lpass.c
index de15be5..322061d 100644
--- a/arch/arm/mach-msm/pil-q6v5-lpass.c
+++ b/arch/arm/mach-msm/pil-q6v5-lpass.c
@@ -494,7 +494,7 @@
if (!lpass_status) {
pr_err("%s: kobject create failed\n", __func__);
ret = -ENOMEM;
- goto err_notif_modem;
+ goto err_create_kobj;
}
ret = sysfs_create_group(lpass_status, &attr_group);
@@ -507,6 +507,8 @@
return 0;
err_kobj:
kobject_put(lpass_status);
+err_create_kobj:
+ subsys_notif_unregister_notifier(drv->modem_notif_hdle, &mnb);
err_notif_modem:
subsys_notif_unregister_notifier(drv->wcnss_notif_hdle, &wnb);
err_notif_wcnss:
diff --git a/arch/arm/mach-msm/qdsp6v2/aac_in.c b/arch/arm/mach-msm/qdsp6v2/aac_in.c
index 5e959b5..0741538 100644
--- a/arch/arm/mach-msm/qdsp6v2/aac_in.c
+++ b/arch/arm/mach-msm/qdsp6v2/aac_in.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010-2012, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2010-2013, 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
@@ -125,6 +125,7 @@
case AUDIO_GET_AAC_ENC_CONFIG: {
struct msm_audio_aac_enc_config cfg;
struct msm_audio_aac_enc_config *enc_cfg;
+ memset(&cfg, 0, sizeof(cfg));
enc_cfg = audio->enc_cfg;
if (enc_cfg->channels == CH_MODE_MONO)
cfg.channels = 1;
diff --git a/drivers/base/genlock.c b/drivers/base/genlock.c
index 58b0513..1149dec 100644
--- a/drivers/base/genlock.c
+++ b/drivers/base/genlock.c
@@ -788,6 +788,8 @@
if (ret < 0)
return ret;
+ memset(¶m, 0, sizeof(param));
+
param.fd = ret;
if (copy_to_user((void __user *) arg, ¶m,
diff --git a/drivers/coresight/Kconfig b/drivers/coresight/Kconfig
index 5e2acfb..fc6df7b 100644
--- a/drivers/coresight/Kconfig
+++ b/drivers/coresight/Kconfig
@@ -151,6 +151,38 @@
If unsure, say 'N' here to avoid potential power penalty.
+config CORESIGHT_AUDIO_ETM
+ bool "Audio processor ETM trace support"
+ help
+ Enables support for ETM trace collection on audio processor using
+ CoreSight framework. Enabling this will allow turning on ETM tracing
+ on audio processor via sysfs by configuring the required CoreSight
+ components.
+
+config CORESIGHT_MODEM_ETM
+ bool "Modem processor ETM trace support"
+ help
+ Enables support for ETM trace collection on modem processor using
+ CoreSight framework. Enabling this will allow turning on ETM tracing
+ on modem processor via sysfs by configuring the required CoreSight
+ components.
+
+config CORESIGHT_WCN_ETM
+ bool "Wireless subsystem processor ETM trace support"
+ help
+ Enables support for ETM trace collection on wireless subsystem
+ processor using CoreSight framework. Enabling this will allow
+ turning on ETM tracing on wireless subsystem via sysfs by configuring
+ the required CoreSight components.
+
+config CORESIGHT_RPM_ETM
+ bool "RPM processor ETM trace support"
+ help
+ Enables support for ETM trace collection on RPM processor using
+ CoreSight framework. Enabling this will allow turning on ETM
+ tracing on RPM processor via sysfs by configuring the required
+ CoreSight components.
+
endif
config CORESIGHT_EVENT
diff --git a/drivers/coresight/Makefile b/drivers/coresight/Makefile
index 23352a7..9d93a6c 100644
--- a/drivers/coresight/Makefile
+++ b/drivers/coresight/Makefile
@@ -13,4 +13,8 @@
obj-$(CONFIG_CORESIGHT_STM) += coresight-stm.o
obj-$(CONFIG_CORESIGHT_HWEVENT) += coresight-hwevent.o
obj-$(CONFIG_CORESIGHT_ETM) += coresight-etm.o coresight-etm-cp14.o
+obj-$(CONFIG_CORESIGHT_AUDIO_ETM) += coresight-audio-etm.o
+obj-$(CONFIG_CORESIGHT_MODEM_ETM) += coresight-modem-etm.o
+obj-$(CONFIG_CORESIGHT_WCN_ETM) += coresight-wcn-etm.o
+obj-$(CONFIG_CORESIGHT_RPM_ETM) += coresight-rpm-etm.o
obj-$(CONFIG_CORESIGHT_EVENT) += coresight-event.o
diff --git a/drivers/coresight/coresight-audio-etm.c b/drivers/coresight/coresight-audio-etm.c
new file mode 100644
index 0000000..cdf44bf
--- /dev/null
+++ b/drivers/coresight/coresight-audio-etm.c
@@ -0,0 +1,132 @@
+/* Copyright (c) 2013, 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.
+ */
+
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/init.h>
+#include <linux/types.h>
+#include <linux/device.h>
+#include <linux/platform_device.h>
+#include <linux/io.h>
+#include <linux/err.h>
+#include <linux/sysfs.h>
+#include <linux/of_coresight.h>
+#include <linux/coresight.h>
+
+struct audio_etm_drvdata {
+ struct device *dev;
+ struct coresight_device *csdev;
+};
+
+static int audio_etm_enable(struct coresight_device *csdev)
+{
+ struct audio_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "Audio ETM tracing enabled\n");
+ return 0;
+}
+
+
+static void audio_etm_disable(struct coresight_device *csdev)
+{
+ struct audio_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "Audio ETM tracing disabled\n");
+}
+
+static const struct coresight_ops_source audio_etm_source_ops = {
+ .enable = audio_etm_enable,
+ .disable = audio_etm_disable,
+};
+
+static const struct coresight_ops audio_cs_ops = {
+ .source_ops = &audio_etm_source_ops,
+};
+
+static int audio_etm_probe(struct platform_device *pdev)
+{
+ struct device *dev = &pdev->dev;
+ struct coresight_platform_data *pdata;
+ struct audio_etm_drvdata *drvdata;
+ struct coresight_desc *desc;
+
+ if (pdev->dev.of_node) {
+ pdata = of_get_coresight_platform_data(dev, pdev->dev.of_node);
+ if (IS_ERR(pdata))
+ return PTR_ERR(pdata);
+ pdev->dev.platform_data = pdata;
+ }
+
+ drvdata = devm_kzalloc(dev, sizeof(*drvdata), GFP_KERNEL);
+ if (!drvdata)
+ return -ENOMEM;
+
+ drvdata->dev = &pdev->dev;
+ platform_set_drvdata(pdev, drvdata);
+
+ desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL);
+ if (!desc)
+ return -ENOMEM;
+
+ desc->type = CORESIGHT_DEV_TYPE_SOURCE;
+ desc->subtype.source_subtype = CORESIGHT_DEV_SUBTYPE_SOURCE_PROC;
+ desc->ops = &audio_cs_ops;
+ desc->pdata = pdev->dev.platform_data;
+ desc->dev = &pdev->dev;
+ desc->owner = THIS_MODULE;
+ drvdata->csdev = coresight_register(desc);
+ if (IS_ERR(drvdata->csdev))
+ return PTR_ERR(drvdata->csdev);
+
+ dev_info(dev, "Audio ETM initialized\n");
+ return 0;
+}
+
+static int audio_etm_remove(struct platform_device *pdev)
+{
+ struct audio_etm_drvdata *drvdata = platform_get_drvdata(pdev);
+
+ coresight_unregister(drvdata->csdev);
+ return 0;
+}
+
+static struct of_device_id audio_etm_match[] = {
+ {.compatible = "qcom,coresight-audio-etm"},
+ {}
+};
+
+static struct platform_driver audio_etm_driver = {
+ .probe = audio_etm_probe,
+ .remove = audio_etm_remove,
+ .driver = {
+ .name = "coresight-audio-etm",
+ .owner = THIS_MODULE,
+ .of_match_table = audio_etm_match,
+ },
+};
+
+int __init audio_etm_init(void)
+{
+ return platform_driver_register(&audio_etm_driver);
+}
+module_init(audio_etm_init);
+
+void __exit audio_etm_exit(void)
+{
+ platform_driver_unregister(&audio_etm_driver);
+}
+module_exit(audio_etm_exit);
+
+MODULE_LICENSE("GPL v2");
+MODULE_DESCRIPTION("CoreSight Audio ETM driver");
diff --git a/drivers/coresight/coresight-modem-etm.c b/drivers/coresight/coresight-modem-etm.c
new file mode 100644
index 0000000..4c8075c
--- /dev/null
+++ b/drivers/coresight/coresight-modem-etm.c
@@ -0,0 +1,132 @@
+/* Copyright (c) 2013, 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.
+ */
+
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/init.h>
+#include <linux/types.h>
+#include <linux/device.h>
+#include <linux/platform_device.h>
+#include <linux/io.h>
+#include <linux/err.h>
+#include <linux/sysfs.h>
+#include <linux/of_coresight.h>
+#include <linux/coresight.h>
+
+struct modem_etm_drvdata {
+ struct device *dev;
+ struct coresight_device *csdev;
+};
+
+static int modem_etm_enable(struct coresight_device *csdev)
+{
+ struct modem_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "Modem ETM tracing enabled\n");
+ return 0;
+}
+
+
+static void modem_etm_disable(struct coresight_device *csdev)
+{
+ struct modem_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "Modem ETM tracing disabled\n");
+}
+
+static const struct coresight_ops_source modem_etm_source_ops = {
+ .enable = modem_etm_enable,
+ .disable = modem_etm_disable,
+};
+
+static const struct coresight_ops modem_cs_ops = {
+ .source_ops = &modem_etm_source_ops,
+};
+
+static int modem_etm_probe(struct platform_device *pdev)
+{
+ struct device *dev = &pdev->dev;
+ struct coresight_platform_data *pdata;
+ struct modem_etm_drvdata *drvdata;
+ struct coresight_desc *desc;
+
+ if (pdev->dev.of_node) {
+ pdata = of_get_coresight_platform_data(dev, pdev->dev.of_node);
+ if (IS_ERR(pdata))
+ return PTR_ERR(pdata);
+ pdev->dev.platform_data = pdata;
+ }
+
+ drvdata = devm_kzalloc(dev, sizeof(*drvdata), GFP_KERNEL);
+ if (!drvdata)
+ return -ENOMEM;
+
+ drvdata->dev = &pdev->dev;
+ platform_set_drvdata(pdev, drvdata);
+
+ desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL);
+ if (!desc)
+ return -ENOMEM;
+
+ desc->type = CORESIGHT_DEV_TYPE_SOURCE;
+ desc->subtype.source_subtype = CORESIGHT_DEV_SUBTYPE_SOURCE_PROC;
+ desc->ops = &modem_cs_ops;
+ desc->pdata = pdev->dev.platform_data;
+ desc->dev = &pdev->dev;
+ desc->owner = THIS_MODULE;
+ drvdata->csdev = coresight_register(desc);
+ if (IS_ERR(drvdata->csdev))
+ return PTR_ERR(drvdata->csdev);
+
+ dev_info(dev, "Modem ETM initialized\n");
+ return 0;
+}
+
+static int modem_etm_remove(struct platform_device *pdev)
+{
+ struct modem_etm_drvdata *drvdata = platform_get_drvdata(pdev);
+
+ coresight_unregister(drvdata->csdev);
+ return 0;
+}
+
+static struct of_device_id modem_etm_match[] = {
+ {.compatible = "qcom,coresight-modem-etm"},
+ {}
+};
+
+static struct platform_driver modem_etm_driver = {
+ .probe = modem_etm_probe,
+ .remove = modem_etm_remove,
+ .driver = {
+ .name = "coresight-modem-etm",
+ .owner = THIS_MODULE,
+ .of_match_table = modem_etm_match,
+ },
+};
+
+int __init modem_etm_init(void)
+{
+ return platform_driver_register(&modem_etm_driver);
+}
+module_init(modem_etm_init);
+
+void __exit modem_etm_exit(void)
+{
+ platform_driver_unregister(&modem_etm_driver);
+}
+module_exit(modem_etm_exit);
+
+MODULE_LICENSE("GPL v2");
+MODULE_DESCRIPTION("CoreSight Modem ETM driver");
diff --git a/drivers/coresight/coresight-rpm-etm.c b/drivers/coresight/coresight-rpm-etm.c
new file mode 100644
index 0000000..e752e4f
--- /dev/null
+++ b/drivers/coresight/coresight-rpm-etm.c
@@ -0,0 +1,132 @@
+/* Copyright (c) 2013, 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.
+ */
+
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/init.h>
+#include <linux/types.h>
+#include <linux/device.h>
+#include <linux/platform_device.h>
+#include <linux/io.h>
+#include <linux/err.h>
+#include <linux/sysfs.h>
+#include <linux/of_coresight.h>
+#include <linux/coresight.h>
+
+struct rpm_etm_drvdata {
+ struct device *dev;
+ struct coresight_device *csdev;
+};
+
+static int rpm_etm_enable(struct coresight_device *csdev)
+{
+ struct rpm_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "RPM ETM tracing enabled\n");
+ return 0;
+}
+
+
+static void rpm_etm_disable(struct coresight_device *csdev)
+{
+ struct rpm_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "RPM ETM tracing disabled\n");
+}
+
+static const struct coresight_ops_source rpm_etm_source_ops = {
+ .enable = rpm_etm_enable,
+ .disable = rpm_etm_disable,
+};
+
+static const struct coresight_ops rpm_cs_ops = {
+ .source_ops = &rpm_etm_source_ops,
+};
+
+static int rpm_etm_probe(struct platform_device *pdev)
+{
+ struct device *dev = &pdev->dev;
+ struct coresight_platform_data *pdata;
+ struct rpm_etm_drvdata *drvdata;
+ struct coresight_desc *desc;
+
+ if (pdev->dev.of_node) {
+ pdata = of_get_coresight_platform_data(dev, pdev->dev.of_node);
+ if (IS_ERR(pdata))
+ return PTR_ERR(pdata);
+ pdev->dev.platform_data = pdata;
+ }
+
+ drvdata = devm_kzalloc(dev, sizeof(*drvdata), GFP_KERNEL);
+ if (!drvdata)
+ return -ENOMEM;
+
+ drvdata->dev = &pdev->dev;
+ platform_set_drvdata(pdev, drvdata);
+
+ desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL);
+ if (!desc)
+ return -ENOMEM;
+
+ desc->type = CORESIGHT_DEV_TYPE_SOURCE;
+ desc->subtype.source_subtype = CORESIGHT_DEV_SUBTYPE_SOURCE_PROC;
+ desc->ops = &rpm_cs_ops;
+ desc->pdata = pdev->dev.platform_data;
+ desc->dev = &pdev->dev;
+ desc->owner = THIS_MODULE;
+ drvdata->csdev = coresight_register(desc);
+ if (IS_ERR(drvdata->csdev))
+ return PTR_ERR(drvdata->csdev);
+
+ dev_info(dev, "RPM ETM initialized\n");
+ return 0;
+}
+
+static int rpm_etm_remove(struct platform_device *pdev)
+{
+ struct rpm_etm_drvdata *drvdata = platform_get_drvdata(pdev);
+
+ coresight_unregister(drvdata->csdev);
+ return 0;
+}
+
+static struct of_device_id rpm_etm_match[] = {
+ {.compatible = "qcom,coresight-rpm-etm"},
+ {}
+};
+
+static struct platform_driver rpm_etm_driver = {
+ .probe = rpm_etm_probe,
+ .remove = rpm_etm_remove,
+ .driver = {
+ .name = "coresight-rpm-etm",
+ .owner = THIS_MODULE,
+ .of_match_table = rpm_etm_match,
+ },
+};
+
+int __init rpm_etm_init(void)
+{
+ return platform_driver_register(&rpm_etm_driver);
+}
+module_init(rpm_etm_init);
+
+void __exit rpm_etm_exit(void)
+{
+ platform_driver_unregister(&rpm_etm_driver);
+}
+module_exit(rpm_etm_exit);
+
+MODULE_LICENSE("GPL v2");
+MODULE_DESCRIPTION("CoreSight RPM ETM driver");
diff --git a/drivers/coresight/coresight-wcn-etm.c b/drivers/coresight/coresight-wcn-etm.c
new file mode 100644
index 0000000..44852fb
--- /dev/null
+++ b/drivers/coresight/coresight-wcn-etm.c
@@ -0,0 +1,132 @@
+/* Copyright (c) 2013, 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.
+ */
+
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/init.h>
+#include <linux/types.h>
+#include <linux/device.h>
+#include <linux/platform_device.h>
+#include <linux/io.h>
+#include <linux/err.h>
+#include <linux/sysfs.h>
+#include <linux/of_coresight.h>
+#include <linux/coresight.h>
+
+struct wcn_etm_drvdata {
+ struct device *dev;
+ struct coresight_device *csdev;
+};
+
+static int wcn_etm_enable(struct coresight_device *csdev)
+{
+ struct wcn_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "Wireless ETM tracing enabled\n");
+ return 0;
+}
+
+
+static void wcn_etm_disable(struct coresight_device *csdev)
+{
+ struct wcn_etm_drvdata *drvdata =
+ dev_get_drvdata(csdev->dev.parent);
+
+ dev_info(drvdata->dev, "Wireless ETM tracing disabled\n");
+}
+
+static const struct coresight_ops_source wcn_etm_source_ops = {
+ .enable = wcn_etm_enable,
+ .disable = wcn_etm_disable,
+};
+
+static const struct coresight_ops wcn_cs_ops = {
+ .source_ops = &wcn_etm_source_ops,
+};
+
+static int wcn_etm_probe(struct platform_device *pdev)
+{
+ struct device *dev = &pdev->dev;
+ struct coresight_platform_data *pdata;
+ struct wcn_etm_drvdata *drvdata;
+ struct coresight_desc *desc;
+
+ if (pdev->dev.of_node) {
+ pdata = of_get_coresight_platform_data(dev, pdev->dev.of_node);
+ if (IS_ERR(pdata))
+ return PTR_ERR(pdata);
+ pdev->dev.platform_data = pdata;
+ }
+
+ drvdata = devm_kzalloc(dev, sizeof(*drvdata), GFP_KERNEL);
+ if (!drvdata)
+ return -ENOMEM;
+
+ drvdata->dev = &pdev->dev;
+ platform_set_drvdata(pdev, drvdata);
+
+ desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL);
+ if (!desc)
+ return -ENOMEM;
+
+ desc->type = CORESIGHT_DEV_TYPE_SOURCE;
+ desc->subtype.source_subtype = CORESIGHT_DEV_SUBTYPE_SOURCE_PROC;
+ desc->ops = &wcn_cs_ops;
+ desc->pdata = pdev->dev.platform_data;
+ desc->dev = &pdev->dev;
+ desc->owner = THIS_MODULE;
+ drvdata->csdev = coresight_register(desc);
+ if (IS_ERR(drvdata->csdev))
+ return PTR_ERR(drvdata->csdev);
+
+ dev_info(dev, "Wireless ETM initialized\n");
+ return 0;
+}
+
+static int wcn_etm_remove(struct platform_device *pdev)
+{
+ struct wcn_etm_drvdata *drvdata = platform_get_drvdata(pdev);
+
+ coresight_unregister(drvdata->csdev);
+ return 0;
+}
+
+static struct of_device_id wcn_etm_match[] = {
+ {.compatible = "qcom,coresight-wcn-etm"},
+ {}
+};
+
+static struct platform_driver wcn_etm_driver = {
+ .probe = wcn_etm_probe,
+ .remove = wcn_etm_remove,
+ .driver = {
+ .name = "coresight-wcn-etm",
+ .owner = THIS_MODULE,
+ .of_match_table = wcn_etm_match,
+ },
+};
+
+int __init wcn_etm_init(void)
+{
+ return platform_driver_register(&wcn_etm_driver);
+}
+module_init(wcn_etm_init);
+
+void __exit wcn_etm_exit(void)
+{
+ platform_driver_unregister(&wcn_etm_driver);
+}
+module_exit(wcn_etm_exit);
+
+MODULE_LICENSE("GPL v2");
+MODULE_DESCRIPTION("CoreSight Wireless ETM driver");
diff --git a/drivers/gpu/msm/adreno.c b/drivers/gpu/msm/adreno.c
index b393b21..79fbd2c 100644
--- a/drivers/gpu/msm/adreno.c
+++ b/drivers/gpu/msm/adreno.c
@@ -1702,8 +1702,8 @@
/* Power down the device */
kgsl_pwrctrl_disable(device);
- /* Certain targets need the fixup. You know who you are */
- if (adreno_is_a330v2(adreno_dev))
+ /* Enable the power on shader corruption fix for all A3XX targets */
+ if (adreno_is_a3xx(adreno_dev))
adreno_a3xx_pwron_fixup_init(adreno_dev);
return 0;
@@ -3669,6 +3669,8 @@
}
}
for (i = 0; i < FT_DETECT_REGS_COUNT; i++) {
+ if (ft_detect_regs[i] == 0)
+ continue;
if (curr_reg_val[i] != prev_reg_val[i])
fast_hang_detected = 0;
}
@@ -3730,8 +3732,12 @@
/* If hangs are not detected copy the current reg values
* to previous values and return no hang */
- for (i = 0; i < FT_DETECT_REGS_COUNT; i++)
- prev_reg_val[i] = curr_reg_val[i];
+ for (i = 0; i < FT_DETECT_REGS_COUNT; i++) {
+ if (ft_detect_regs[i] == 0)
+ continue;
+ prev_reg_val[i] = curr_reg_val[i];
+ }
+
return 0;
}
diff --git a/drivers/gpu/msm/adreno_profile.c b/drivers/gpu/msm/adreno_profile.c
index 896b6e8..7d9d63f 100644
--- a/drivers/gpu/msm/adreno_profile.c
+++ b/drivers/gpu/msm/adreno_profile.c
@@ -597,7 +597,7 @@
static char *_parse_next_assignment(struct adreno_device *adreno_dev,
char *str, int *groupid, int *countable, bool *remove)
{
- char *groupid_str, *countable_str;
+ char *groupid_str, *countable_str, *next_str = NULL;
int ret;
*groupid = -EINVAL;
@@ -635,8 +635,15 @@
if (countable_str == str)
return NULL;
- *str = '\0';
- str++;
+ /*
+ * If we have reached the end of the original string then make sure we
+ * return NULL from this function or we could accidently overrun
+ */
+
+ if (*str != '\0') {
+ *str = '\0';
+ next_str = str + 1;
+ }
/* set results */
*groupid = adreno_perfcounter_get_groupid(adreno_dev,
@@ -647,7 +654,7 @@
if (ret)
return NULL;
- return str;
+ return next_str;
}
static ssize_t profile_assignments_write(struct file *filep,
diff --git a/drivers/gpu/msm/adreno_ringbuffer.c b/drivers/gpu/msm/adreno_ringbuffer.c
index ceff923..8aec755 100644
--- a/drivers/gpu/msm/adreno_ringbuffer.c
+++ b/drivers/gpu/msm/adreno_ringbuffer.c
@@ -1073,7 +1073,7 @@
struct adreno_device *adreno_dev = ADRENO_DEVICE(device);
unsigned int *link = 0;
unsigned int *cmds;
- unsigned int i;
+ unsigned int i, cmdflags;
struct adreno_context *drawctxt = NULL;
unsigned int start_index = 0;
int ret;
@@ -1095,6 +1095,8 @@
goto done;
}
+ cmdflags = (flags & KGSL_CMD_FLAGS_EOF);
+
/* process any profiling results that are available into the log_buf */
adreno_profile_process_results(device);
@@ -1161,7 +1163,7 @@
if (test_and_clear_bit(ADRENO_DEVICE_PWRON, &adreno_dev->priv) &&
test_bit(ADRENO_DEVICE_PWRON_FIXUP, &adreno_dev->priv))
- flags |= KGSL_CMD_FLAGS_PWRON_FIXUP;
+ cmdflags |= KGSL_CMD_FLAGS_PWRON_FIXUP;
if (drawctxt->flags & CTXT_FLAGS_USER_GENERATED_TS) {
if (timestamp_cmp(drawctxt->timestamp, *timestamp) >= 0) {
@@ -1178,7 +1180,7 @@
ret = adreno_ringbuffer_addcmds(&adreno_dev->ringbuffer,
drawctxt,
- flags,
+ cmdflags,
&link[0], (cmds - link));
if (ret)
goto done;
diff --git a/drivers/gpu/msm/kgsl.c b/drivers/gpu/msm/kgsl.c
index 7da0811..298b36e 100644
--- a/drivers/gpu/msm/kgsl.c
+++ b/drivers/gpu/msm/kgsl.c
@@ -909,6 +909,9 @@
private = kgsl_find_process_private(cur_dev_priv);
+ if (!private)
+ return NULL;
+
mutex_lock(&private->process_private_mutex);
if (test_bit(KGSL_PROCESS_INIT, &private->priv))
@@ -3049,7 +3052,7 @@
static inline bool
mmap_range_valid(unsigned long addr, unsigned long len)
{
- return (addr + len) > addr && (addr + len) < TASK_SIZE;
+ return ((ULONG_MAX - addr) > len) && ((addr + len) < TASK_SIZE);
}
static unsigned long
diff --git a/drivers/gpu/msm/kgsl.h b/drivers/gpu/msm/kgsl.h
index 8d390a9..0525eab 100644
--- a/drivers/gpu/msm/kgsl.h
+++ b/drivers/gpu/msm/kgsl.h
@@ -267,7 +267,7 @@
size = 1;
/* don't overflow */
- if ((gpuaddr + size) < gpuaddr)
+ if (size > UINT_MAX - gpuaddr)
return 0;
if (gpuaddr >= memdesc->gpuaddr &&
diff --git a/drivers/input/misc/mma8x5x.c b/drivers/input/misc/mma8x5x.c
index f49ff14..a325d54 100644
--- a/drivers/input/misc/mma8x5x.c
+++ b/drivers/input/misc/mma8x5x.c
@@ -304,6 +304,28 @@
return 0;
}
+static int mma8x5x_device_start(struct i2c_client *client)
+{
+ struct mma8x5x_data *pdata = i2c_get_clientdata(client);
+
+ if (i2c_smbus_write_byte_data(client, MMA8X5X_CTRL_REG1, 0))
+ goto err_out;
+ if (i2c_smbus_write_byte_data(client, MMA8X5X_XYZ_DATA_CFG,
+ pdata->mode))
+ goto err_out;
+
+ /* The BT(boot time) for mma8x5x is 1.55ms according to
+ *Freescale mma8450Q document. Document Number:MMA8450Q
+ *Rev: 9.1, 04/2012
+ */
+ usleep_range(1600, 2000);
+ return 0;
+
+err_out:
+ dev_err(&client->dev, "%s:start device failed", __func__);
+ return -EIO;
+}
+
static int mma8x5x_read_data(struct i2c_client *client,
struct mma8x5x_data_axis *data)
{
@@ -381,32 +403,73 @@
int ret;
unsigned long enable;
u8 val = 0;
+
ret = kstrtoul(buf, 10, &enable);
if (ret)
return ret;
mutex_lock(&pdata->data_lock);
enable = (enable > 0) ? 1 : 0;
- if (enable && pdata->active == MMA_STANDBY) {
- val = i2c_smbus_read_byte_data(client, MMA8X5X_CTRL_REG1);
- ret = i2c_smbus_write_byte_data(client,
- MMA8X5X_CTRL_REG1, val|0x01);
- if (!ret) {
+ if (enable) {
+ if (pdata->active & MMA_SHUTTEDDOWN) {
+ ret = mma8x5x_config_regulator(client, 1);
+ if (ret)
+ goto err_failed;
+
+ ret = mma8x5x_device_start(client);
+ if (ret)
+ goto err_failed;
+
+ pdata->active &= ~MMA_SHUTTEDDOWN;
+ }
+ if (pdata->active == MMA_STANDBY) {
+ val = i2c_smbus_read_byte_data(client,
+ MMA8X5X_CTRL_REG1);
+ if (val < 0) {
+ dev_err(dev, "read device state failed!");
+ ret = val;
+ goto err_failed;
+ }
+
+ ret = i2c_smbus_write_byte_data(client,
+ MMA8X5X_CTRL_REG1, val | 0x01);
+ if (ret) {
+ dev_err(dev, "change device state failed!");
+ goto err_failed;
+ }
pdata->active = MMA_ACTIVED;
- dev_dbg(dev,
- "%s:mma enable setting active.\n", __func__);
+ dev_dbg(dev, "%s:mma enable setting active.\n",
+ __func__);
}
- } else if (enable == 0 && pdata->active == MMA_ACTIVED) {
- val = i2c_smbus_read_byte_data(client, MMA8X5X_CTRL_REG1);
- ret = i2c_smbus_write_byte_data(client,
- MMA8X5X_CTRL_REG1, val & 0xFE);
- if (!ret) {
+ } else if (enable == 0) {
+ if (pdata->active == MMA_ACTIVED) {
+ val = i2c_smbus_read_byte_data(client,
+ MMA8X5X_CTRL_REG1);
+ if (val < 0) {
+ dev_err(dev, "read device state failed!");
+ ret = val;
+ goto err_failed;
+ }
+
+ ret = i2c_smbus_write_byte_data(client,
+ MMA8X5X_CTRL_REG1, val & 0xFE);
+ if (ret) {
+ dev_err(dev, "change device state failed!");
+ goto err_failed;
+ }
+
pdata->active = MMA_STANDBY;
- dev_dbg(dev,
- "%s:mma enable setting inactive.\n", __func__);
+ dev_dbg(dev, "%s:mma enable setting inactive.\n",
+ __func__);
}
+ if (!mma8x5x_config_regulator(client, 0))
+ pdata->active |= MMA_SHUTTEDDOWN;
}
mutex_unlock(&pdata->data_lock);
return count;
+
+err_failed:
+ mutex_unlock(&pdata->data_lock);
+ return ret;
}
static ssize_t mma8x5x_position_show(struct device *dev,
struct device_attribute *attr, char *buf)
@@ -617,6 +680,8 @@
struct mma8x5x_data *pdata = i2c_get_clientdata(client);
if (pdata->active == MMA_ACTIVED)
mma8x5x_device_stop(client);
+ if (pdata->active & MMA_SHUTTEDDOWN)
+ return 0;
if (!mma8x5x_config_regulator(client, 0))
/* The highest bit sotres the power state */
pdata->active |= MMA_SHUTTEDDOWN;
@@ -628,22 +693,16 @@
int val = 0;
struct i2c_client *client = to_i2c_client(dev);
struct mma8x5x_data *pdata = i2c_get_clientdata(client);
+
+ /* No need to power on while device is shutdowned from standby state */
+ if (pdata->active == (MMA_SHUTTEDDOWN | MMA_STANDBY))
+ return 0;
if (pdata->active & MMA_SHUTTEDDOWN) {
if (mma8x5x_config_regulator(client, 1))
goto out;
- if (i2c_smbus_write_byte_data(client, MMA8X5X_CTRL_REG1, 0))
+ if (mma8x5x_device_start(client))
goto out;
-
- if (i2c_smbus_write_byte_data(client, MMA8X5X_XYZ_DATA_CFG,
- pdata->mode))
- goto out;
-
- /* The BT(boot time) for mma8x5x is 1.55ms according to
- Freescale mma8450Q document. Document Number:MMA8450Q
- Rev: 9.1, 04/2012
- */
- usleep_range(1600, 2000);
pdata->active &= ~MMA_SHUTTEDDOWN;
}
if (pdata->active == MMA_ACTIVED) {
diff --git a/drivers/input/touchscreen/ft5x06_ts.c b/drivers/input/touchscreen/ft5x06_ts.c
index 367a987..aa50d44 100644
--- a/drivers/input/touchscreen/ft5x06_ts.c
+++ b/drivers/input/touchscreen/ft5x06_ts.c
@@ -336,7 +336,6 @@
input_report_abs(ip_dev, ABS_MT_PRESSURE, pressure);
} else {
input_mt_report_slot_state(ip_dev, MT_TOOL_FINGER, 0);
- input_report_abs(ip_dev, ABS_MT_PRESSURE, 0);
}
}
diff --git a/drivers/media/platform/msm/camera_v2/sensor/hi256.c b/drivers/media/platform/msm/camera_v2/sensor/hi256.c
index 835230e..a10d60e 100644
--- a/drivers/media/platform/msm/camera_v2/sensor/hi256.c
+++ b/drivers/media/platform/msm/camera_v2/sensor/hi256.c
@@ -33,7 +33,7 @@
.seq_type = SENSOR_GPIO,
.seq_val = SENSOR_GPIO_STANDBY,
.config_val = GPIO_OUT_LOW,
- .delay = 20,
+ .delay = 0,
},
{
.seq_type = SENSOR_GPIO,
@@ -63,13 +63,13 @@
.seq_type = SENSOR_CLK,
.seq_val = SENSOR_CAM_MCLK,
.config_val = 24000000,
- .delay = 10,
+ .delay = 5,
},
{
.seq_type = SENSOR_GPIO,
.seq_val = SENSOR_GPIO_STANDBY,
.config_val = GPIO_OUT_LOW,
- .delay = 20,
+ .delay = 0,
},
{
.seq_type = SENSOR_GPIO,
@@ -81,7 +81,7 @@
.seq_type = SENSOR_GPIO,
.seq_val = SENSOR_GPIO_RESET,
.config_val = GPIO_OUT_HIGH,
- .delay = 30,
+ .delay = 1,
},
{
.seq_type = SENSOR_I2C_MUX,
diff --git a/drivers/media/platform/msm/vidc/msm_vdec.c b/drivers/media/platform/msm/vidc/msm_vdec.c
index ea91849..5e7c84c 100644
--- a/drivers/media/platform/msm/vidc/msm_vdec.c
+++ b/drivers/media/platform/msm/vidc/msm_vdec.c
@@ -717,12 +717,7 @@
if (f->type == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE) {
for (i = 0; i < fmt->num_planes; ++i) {
f->fmt.pix_mp.plane_fmt[i].sizeimage =
- fmt->get_frame_size(i,
- inst->capability.height.max,
- inst->capability.width.max);
- inst->bufq[OUTPUT_PORT].
- vb2_bufq.plane_sizes[i] =
- f->fmt.pix_mp.plane_fmt[i].sizeimage;
+ inst->bufq[OUTPUT_PORT].vb2_bufq.plane_sizes[i];
}
} else {
switch (fmt->fourcc) {
@@ -838,6 +833,8 @@
int ret = 0;
int i;
struct hal_buffer_requirements *buff_req_buffer;
+ int max_input_size = 0;
+
if (!inst || !f) {
dprintk(VIDC_ERR,
"Invalid input, inst = %p, format = %p\n", inst, f);
@@ -920,9 +917,14 @@
frame_sz.width = inst->prop.width;
frame_sz.height = inst->prop.height;
msm_comm_try_set_prop(inst, HAL_PARAM_FRAME_SIZE, &frame_sz);
- f->fmt.pix_mp.plane_fmt[0].sizeimage =
- fmt->get_frame_size(0, inst->capability.height.max,
+
+ max_input_size = fmt->get_frame_size(0,
+ inst->capability.height.max,
inst->capability.width.max);
+
+ if (f->fmt.pix_mp.plane_fmt[0].sizeimage > max_input_size)
+ f->fmt.pix_mp.plane_fmt[0].sizeimage = max_input_size;
+
f->fmt.pix_mp.num_planes = fmt->num_planes;
for (i = 0; i < fmt->num_planes; ++i) {
inst->bufq[OUTPUT_PORT].vb2_bufq.plane_sizes[i] =
diff --git a/drivers/media/platform/msm/vidc/msm_venc.c b/drivers/media/platform/msm/vidc/msm_venc.c
index 9e8a639..b94d9db 100644
--- a/drivers/media/platform/msm/vidc/msm_venc.c
+++ b/drivers/media/platform/msm/vidc/msm_venc.c
@@ -25,9 +25,9 @@
#define MAX_BIT_RATE 160000000
#define DEFAULT_BIT_RATE 64000
#define BIT_RATE_STEP 100
-#define MIN_FRAME_RATE 65536
-#define MAX_FRAME_RATE 15728640
-#define DEFAULT_FRAME_RATE 1966080
+#define MIN_FRAME_RATE 1
+#define MAX_FRAME_RATE 240
+#define DEFAULT_FRAME_RATE 15
#define DEFAULT_IR_MBS 30
#define MAX_SLICE_BYTE_SIZE 1024
#define MIN_SLICE_BYTE_SIZE 1024
@@ -1257,8 +1257,9 @@
if (!__temp) { \
dprintk(VIDC_ERR, "Can't find %s (%x) in cluster", \
#__ctrl_id, __ctrl_id); \
- rc = -ENOENT; \
- break; \
+ /* Clusters are hardcoded, if we can't find */ \
+ /* something then things are massively screwed up */ \
+ BUG_ON(1); \
} \
__temp; \
})
@@ -1270,11 +1271,15 @@
idr_period.idr_period = ctrl->val;
pdata = &idr_period;
break;
- case V4L2_CID_MPEG_VIDEO_H264_I_PERIOD: {
- struct v4l2_ctrl *b;
- b = TRY_GET_CTRL(V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES);
+ case V4L2_CID_MPEG_VIDEO_H264_I_PERIOD:
+ case V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES:
+ case V4L2_CID_MPEG_VIDC_VIDEO_NUM_P_FRAMES:
+ {
+ int num_p, num_b;
+ struct v4l2_ctrl update_ctrl = {.id = 0, .val = 0};
- if (inst->fmts[CAPTURE_PORT]->fourcc != V4L2_PIX_FMT_H264 &&
+ if (ctrl->id == V4L2_CID_MPEG_VIDEO_H264_I_PERIOD &&
+ inst->fmts[CAPTURE_PORT]->fourcc != V4L2_PIX_FMT_H264 &&
inst->fmts[CAPTURE_PORT]->fourcc !=
V4L2_PIX_FMT_H264_NO_SC) {
dprintk(VIDC_ERR, "Control 0x%x only valid for H264",
@@ -1283,110 +1288,115 @@
break;
}
- /*
- * We can't set the I-period explicitly. So set it implicitly
- * by setting the number of P and B frames per I-period
- */
- property_id = HAL_CONFIG_VENC_INTRA_PERIOD;
- intra_period.pframes = (ctrl->val - 1) - b->val;
- intra_period.bframes = b->val;
- pdata = &intra_period;
- break;
- }
- case V4L2_CID_MPEG_VIDC_VIDEO_NUM_P_FRAMES:
- temp_ctrl = TRY_GET_CTRL(V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES);
- property_id =
- HAL_CONFIG_VENC_INTRA_PERIOD;
- intra_period.pframes = ctrl->val;
- intra_period.bframes = temp_ctrl->val;
- pdata = &intra_period;
- break;
- case V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES:
+ temp_ctrl = TRY_GET_CTRL(V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES);
+ num_b = temp_ctrl->val;
+
temp_ctrl = TRY_GET_CTRL(V4L2_CID_MPEG_VIDC_VIDEO_NUM_P_FRAMES);
- intra_period.bframes = ctrl->val;
- intra_period.pframes = temp_ctrl->val;
- if (intra_period.bframes) {
+ num_p = temp_ctrl->val;
+
+ /* V4L2_CID_MPEG_VIDEO_H264_I_PERIOD and _NUM_P_FRAMES are
+ * implicitly tied to each other. If either is adjusted,
+ * the other needs to be adjusted in a complementary manner.
+ * Ideally we adjust _NUM_B_FRAMES as well but we'll leave it
+ * alone for now */
+ if (ctrl->id == V4L2_CID_MPEG_VIDEO_H264_I_PERIOD) {
+ num_p = ctrl->val - 1 - num_b;
+ update_ctrl.id = V4L2_CID_MPEG_VIDC_VIDEO_NUM_P_FRAMES;
+ update_ctrl.val = num_p;
+ } else if (ctrl->id == V4L2_CID_MPEG_VIDC_VIDEO_NUM_P_FRAMES) {
+ num_p = ctrl->val;
+ update_ctrl.id = V4L2_CID_MPEG_VIDEO_H264_I_PERIOD;
+ update_ctrl.val = num_p + num_b;
+ } else if (ctrl->id == V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES) {
+ num_b = ctrl->val;
+ update_ctrl.id = V4L2_CID_MPEG_VIDEO_H264_I_PERIOD;
+ update_ctrl.val = num_p + num_b;
+ }
+
+ if (update_ctrl.id) {
+ temp_ctrl = TRY_GET_CTRL(update_ctrl.id);
+ temp_ctrl->val = update_ctrl.val;
+ }
+
+ if (num_b) {
u32 max_num_b_frames = MAX_NUM_B_FRAMES;
- property_id =
- HAL_PARAM_VENC_MAX_NUM_B_FRAMES;
+ property_id = HAL_PARAM_VENC_MAX_NUM_B_FRAMES;
pdata = &max_num_b_frames;
rc = call_hfi_op(hdev, session_set_property,
(void *)inst->session, property_id, pdata);
if (rc) {
dprintk(VIDC_ERR,
- "Failed : Setprop MAX_NUM_B_FRAMES"
- "%d", rc);
+ "Failed : Setprop MAX_NUM_B_FRAMES %d",
+ rc);
break;
}
}
- property_id =
- HAL_CONFIG_VENC_INTRA_PERIOD;
+
+ property_id = HAL_CONFIG_VENC_INTRA_PERIOD;
+ intra_period.pframes = num_p;
+ intra_period.bframes = num_b;
pdata = &intra_period;
+
break;
+ }
case V4L2_CID_MPEG_VIDC_VIDEO_REQUEST_IFRAME:
property_id =
HAL_CONFIG_VENC_REQUEST_IFRAME;
request_iframe.enable = true;
pdata = &request_iframe;
break;
+ case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL:
case V4L2_CID_MPEG_VIDEO_BITRATE_MODE:
{
- bool cfr = true, cbr = true;
int final_mode = 0;
+ struct v4l2_ctrl update_ctrl = {.id = 0, .val = 0};
- temp_ctrl = TRY_GET_CTRL(
- V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL);
-
- switch (temp_ctrl->val) {
- case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_OFF:
- /* Let's assume CFR */
- case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_CFR:
- case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_CFR:
- cfr = true;
- break;
- case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_VFR:
- case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_VFR:
- cfr = false;
- break;
- default:
- dprintk(VIDC_WARN, "Unknown framerate mode");
- }
-
- switch (ctrl->val) {
- case V4L2_MPEG_VIDEO_BITRATE_MODE_VBR:
- cbr = false;
- break;
- case V4L2_MPEG_VIDEO_BITRATE_MODE_CBR:
- cbr = true;
- break;
- default:
- dprintk(VIDC_WARN, "Unknown bitrate mode");
- }
-
- if (!cfr && !cbr)
- final_mode =
- V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_VFR;
- else if (!cfr && cbr)
- final_mode =
- V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_VFR;
- else if (cfr && !cbr)
- final_mode =
+ /* V4L2_CID_MPEG_VIDEO_BITRATE_MODE and _RATE_CONTROL
+ * manipulate the same thing. If one control's state
+ * changes, try to mirror the state in the other control's
+ * value */
+ if (ctrl->id == V4L2_CID_MPEG_VIDEO_BITRATE_MODE) {
+ if (ctrl->val == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR) {
+ final_mode = HAL_RATE_CONTROL_VBR_CFR;
+ update_ctrl.val =
V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_CFR;
- else /* ... if (cfr && cbr) */
- final_mode =
+ } else {/* ...if (ctrl->val == _BITRATE_MODE_CBR) */
+ final_mode = HAL_RATE_CONTROL_CBR_CFR;
+ update_ctrl.val =
V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_CFR;
+ }
+
+ update_ctrl.id = V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL;
+
+ } else if (ctrl->id == V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL) {
+ switch (ctrl->val) {
+ case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_OFF:
+ case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_VFR:
+ case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_CFR:
+ update_ctrl.val =
+ V4L2_MPEG_VIDEO_BITRATE_MODE_VBR;
+ case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_VFR:
+ case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_CFR:
+ update_ctrl.val =
+ V4L2_MPEG_VIDEO_BITRATE_MODE_CBR;
+ }
+
+ final_mode = ctrl->val;
+ update_ctrl.id = V4L2_CID_MPEG_VIDEO_BITRATE_MODE;
+ }
+
+ if (update_ctrl.id) {
+ temp_ctrl = TRY_GET_CTRL(update_ctrl.id);
+ temp_ctrl->val = update_ctrl.val;
+ }
property_id = HAL_PARAM_VENC_RATE_CONTROL;
property_val = final_mode;
pdata = &property_val;
+
break;
}
- case V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL:
- property_id = HAL_PARAM_VENC_RATE_CONTROL;
- property_val = ctrl->val;
- pdata = &property_val;
- break;
case V4L2_CID_MPEG_VIDEO_BITRATE:
property_id =
HAL_CONFIG_VENC_TARGET_BITRATE;
diff --git a/drivers/media/platform/msm/vidc/msm_vidc.c b/drivers/media/platform/msm/vidc/msm_vidc.c
index 89fbc2a..f2f0f5d 100644
--- a/drivers/media/platform/msm/vidc/msm_vidc.c
+++ b/drivers/media/platform/msm/vidc/msm_vidc.c
@@ -451,12 +451,12 @@
!b->m.planes[i].length) {
continue;
}
+ mutex_lock(&inst->sync_lock);
temp = get_registered_buf(inst, b, i, &plane);
if (temp && !is_dynamic_output_buffer_mode(b, inst)) {
dprintk(VIDC_DBG,
"This memory region has already been prepared\n");
rc = -EINVAL;
- goto exit;
}
if (temp && is_dynamic_output_buffer_mode(b, inst) &&
@@ -471,12 +471,14 @@
*/
dprintk(VIDC_DBG, "[MAP] Buffer already prepared\n");
rc = buf_ref_get(inst, temp);
- if (rc < 0)
- return rc;
- save_v4l2_buffer(b, temp);
- rc = -EEXIST;
- goto exit;
+ if (rc > 0) {
+ save_v4l2_buffer(b, temp);
+ rc = -EEXIST;
+ }
}
+ mutex_unlock(&inst->sync_lock);
+ if (rc < 0)
+ goto exit;
temp = get_same_fd_buffer(inst, &inst->registered_bufs,
b->m.planes[i].reserved[0], &plane);
diff --git a/drivers/media/platform/msm/vidc/msm_vidc_common.c b/drivers/media/platform/msm/vidc/msm_vidc_common.c
index 780f2c4..bf1c2cf 100644
--- a/drivers/media/platform/msm/vidc/msm_vidc_common.c
+++ b/drivers/media/platform/msm/vidc/msm_vidc_common.c
@@ -510,6 +510,7 @@
"RELEASE REFERENCE EVENT FROM F/W - fd = %d offset = %d\n",
ptr[0], ptr[1]);
+ mutex_lock(&inst->sync_lock);
/* Decrement buffer reference count*/
buf_ref_put(inst, binfo);
@@ -520,6 +521,7 @@
if (unmap_and_deregister_buf(inst, binfo))
dprintk(VIDC_ERR,
"%s: buffer unmap failed\n", __func__);
+ mutex_unlock(&inst->sync_lock);
/*send event to client*/
v4l2_event_queue_fh(&inst->event_handler,
@@ -878,7 +880,7 @@
atomic_inc(&binfo->ref_count);
cnt = atomic_read(&binfo->ref_count);
if (cnt > 2) {
- dprintk(VIDC_ERR, "%s: invalid ref_cnt: %d\n", __func__, cnt);
+ dprintk(VIDC_DBG, "%s: invalid ref_cnt: %d\n", __func__, cnt);
cnt = -EINVAL;
}
dprintk(VIDC_DBG, "REF_GET[%d] fd[0] = %d\n", cnt, binfo->fd[0]);
@@ -905,7 +907,7 @@
else if (cnt == 1)
qbuf_again = true;
else {
- dprintk(VIDC_ERR, "%s: invalid ref_cnt: %d\n", __func__, cnt);
+ dprintk(VIDC_DBG, "%s: invalid ref_cnt: %d\n", __func__, cnt);
cnt = -EINVAL;
}
mutex_unlock(&inst->lock);
@@ -957,12 +959,12 @@
}
if (flags & HAL_BUFFERFLAG_READONLY) {
dprintk(VIDC_DBG,
- "_F_B_D_ fd[0] = %d -> Reference with f/w",
- binfo->fd[0]);
+ "_F_B_D_ fd[0] = %d -> Reference with f/w, addr: 0x%x",
+ binfo->fd[0], device_addr);
} else {
dprintk(VIDC_DBG,
- "_F_B_D_ fd[0] = %d -> FBD_ref_released\n",
- binfo->fd[0]);
+ "_F_B_D_ fd[0] = %d -> FBD_ref_released, addr: 0x%x\n",
+ binfo->fd[0], device_addr);
buf_ref_put(inst, binfo);
}
}
@@ -2616,6 +2618,9 @@
dprintk(VIDC_DBG,
"released buffer held in driver before issuing flush: 0x%x fd[0]: %d\n",
binfo->device_addr[0], binfo->fd[0]);
+ /*delete this buffer info from registered list*/
+ list_del(&binfo->list);
+ kfree(binfo);
/*send event to client*/
v4l2_event_queue_fh(&inst->event_handler,
&buf_event);
@@ -2670,6 +2675,7 @@
}
mutex_lock(&inst->sync_lock);
+ msm_comm_flush_dynamic_buffers(inst);
if (inst->in_reconfig && !ip_flush && op_flush) {
if (!list_empty(&inst->pendingq)) {
/*Execution can never reach here since port reconfig
@@ -2702,8 +2708,6 @@
}
}
- msm_comm_flush_dynamic_buffers(inst);
-
/*Do not send flush in case of session_error */
if (!(inst->state == MSM_VIDC_CORE_INVALID &&
core->state != VIDC_CORE_INVALID))
diff --git a/drivers/media/platform/msm/vidc/msm_vidc_debug.c b/drivers/media/platform/msm/vidc/msm_vidc_debug.c
index 25651c9..5a18265 100644
--- a/drivers/media/platform/msm/vidc/msm_vidc_debug.c
+++ b/drivers/media/platform/msm/vidc/msm_vidc_debug.c
@@ -86,6 +86,18 @@
write_str(&dbg_buf, "irq: %u\n",
call_hfi_op(hdev, get_fw_info, hdev->hfi_device_data,
FW_IRQ));
+ write_str(&dbg_buf, "clock count: %d\n",
+ call_hfi_op(hdev, get_info, hdev->hfi_device_data,
+ DEV_CLOCK_COUNT));
+ write_str(&dbg_buf, "clock enabled: %u\n",
+ call_hfi_op(hdev, get_info, hdev->hfi_device_data,
+ DEV_CLOCK_ENABLED));
+ write_str(&dbg_buf, "power count: %d\n",
+ call_hfi_op(hdev, get_info, hdev->hfi_device_data,
+ DEV_PWR_COUNT));
+ write_str(&dbg_buf, "power enabled: %u\n",
+ call_hfi_op(hdev, get_info, hdev->hfi_device_data,
+ DEV_PWR_ENABLED));
for (i = SYS_MSG_START; i < SYS_MSG_END; i++) {
write_str(&dbg_buf, "completions[%d]: %s\n", i,
completion_done(&core->completions[SYS_MSG_INDEX(i)]) ?
diff --git a/drivers/media/platform/msm/vidc/venus_hfi.c b/drivers/media/platform/msm/vidc/venus_hfi.c
index a5aebd5..4dbda32 100644
--- a/drivers/media/platform/msm/vidc/venus_hfi.c
+++ b/drivers/media/platform/msm/vidc/venus_hfi.c
@@ -829,6 +829,7 @@
}
}
device->clocks_enabled = 1;
+ ++device->clk_cnt;
return 0;
fail_clk_enable:
for (i--; i >= 0; i--) {
@@ -858,6 +859,7 @@
clk_disable(cl->clk);
}
device->clocks_enabled = 0;
+ --device->clk_cnt;
}
static DECLARE_COMPLETION(pc_prep_done);
@@ -899,6 +901,7 @@
venus_hfi_unvote_buses(device, DDR_MEM);
device->power_enabled = 0;
+ --device->pwr_cnt;
already_disabled:
return rc;
}
@@ -949,6 +952,7 @@
goto err_reset_core;
}
device->power_enabled = 1;
+ ++device->pwr_cnt;
return rc;
err_reset_core:
venus_hfi_tzbsp_set_video_state(TZBSP_VIDEO_STATE_SUSPEND);
@@ -2711,6 +2715,7 @@
clk_unprepare(cl->clk);
}
device->clocks_enabled = 0;
+ --device->clk_cnt;
mutex_unlock(&device->clk_pwr_lock);
}
static inline int venus_hfi_enable_clks(struct venus_hfi_device *device)
@@ -2736,6 +2741,7 @@
}
}
device->clocks_enabled = 1;
+ ++device->clk_cnt;
mutex_unlock(&device->clk_pwr_lock);
return rc;
fail_clk_enable:
@@ -3206,6 +3212,7 @@
goto fail_load_fw;
}
device->power_enabled = 1;
+ ++device->pwr_cnt;
mutex_unlock(&device->clk_pwr_lock);
/*Clocks can be enabled only after pil_get since
* gdsc is turned-on in pil_get*/
@@ -3231,6 +3238,7 @@
device->resources.fw.cookie = NULL;
regulator_disable(device->gdsc);
device->power_enabled = 0;
+ --device->pwr_cnt;
mutex_unlock(&device->clk_pwr_lock);
fail_enable_gdsc:
venus_hfi_iommu_detach(device);
@@ -3254,6 +3262,7 @@
subsystem_put(device->resources.fw.cookie);
regulator_disable(device->gdsc);
device->power_enabled = 0;
+ --device->pwr_cnt;
mutex_unlock(&device->clk_pwr_lock);
venus_hfi_interface_queues_release(dev);
venus_hfi_iommu_detach(device);
@@ -3295,6 +3304,37 @@
return rc;
}
+static int venus_hfi_get_info(void *dev, enum dev_info info)
+{
+ int rc = 0;
+ struct venus_hfi_device *device = dev;
+ if (!device) {
+ dprintk(VIDC_ERR, "%s Invalid parameter: %p\n",
+ __func__, device);
+ return -EINVAL;
+ }
+
+ mutex_lock(&device->clk_pwr_lock);
+ switch (info) {
+ case DEV_CLOCK_COUNT:
+ rc = device->clk_cnt;
+ break;
+ case DEV_CLOCK_ENABLED:
+ rc = device->clocks_enabled;
+ break;
+ case DEV_PWR_COUNT:
+ rc = device->pwr_cnt;
+ break;
+ case DEV_PWR_ENABLED:
+ rc = device->power_enabled;
+ break;
+ default:
+ dprintk(VIDC_ERR, "Invalid device info requested");
+ }
+ mutex_unlock(&device->clk_pwr_lock);
+ return rc;
+}
+
int venus_hfi_get_stride_scanline(int color_fmt,
int width, int height, int *stride, int *scanlines) {
*stride = VENUS_Y_STRIDE(color_fmt, width);
@@ -3351,6 +3391,10 @@
hdevice->device_id = device_id;
hdevice->callback = callback;
+ hdevice->clocks_enabled = 0;
+ hdevice->clk_cnt = 0;
+ hdevice->power_enabled = 0;
+ hdevice->pwr_cnt = 0;
hdevice->vidc_workq = create_singlethread_workqueue(
"msm_vidc_workerq_venus");
@@ -3472,6 +3516,7 @@
hdev->load_fw = venus_hfi_load_fw;
hdev->unload_fw = venus_hfi_unload_fw;
hdev->get_fw_info = venus_hfi_get_fw_info;
+ hdev->get_info = venus_hfi_get_info;
hdev->get_stride_scanline = venus_hfi_get_stride_scanline;
hdev->capability_check = venus_hfi_capability_check;
}
diff --git a/drivers/media/platform/msm/vidc/venus_hfi.h b/drivers/media/platform/msm/vidc/venus_hfi.h
index f1d8694..4feda45 100644
--- a/drivers/media/platform/msm/vidc/venus_hfi.h
+++ b/drivers/media/platform/msm/vidc/venus_hfi.h
@@ -207,6 +207,8 @@
u32 register_base;
u32 register_size;
u32 irq;
+ int clk_cnt;
+ int pwr_cnt;
struct venus_resources resources;
struct msm_vidc_platform_resources *res;
struct regulator *gdsc;
diff --git a/drivers/media/platform/msm/vidc/vidc_hfi_api.h b/drivers/media/platform/msm/vidc/vidc_hfi_api.h
index 1c9b71d..63e2036 100644
--- a/drivers/media/platform/msm/vidc/vidc_hfi_api.h
+++ b/drivers/media/platform/msm/vidc/vidc_hfi_api.h
@@ -1045,6 +1045,14 @@
FW_INFO_MAX,
};
+enum dev_info {
+ DEV_CLOCK_COUNT,
+ DEV_CLOCK_ENABLED,
+ DEV_PWR_COUNT,
+ DEV_PWR_ENABLED,
+ DEV_INFO_MAX
+};
+
#define call_hfi_op(q, op, args...) \
(((q) && (q)->op) ? ((q)->op(args)) : 0)
@@ -1098,6 +1106,7 @@
int (*load_fw)(void *dev);
void (*unload_fw)(void *dev);
int (*get_fw_info)(void *dev, enum fw_info info);
+ int (*get_info) (void *dev, enum dev_info info);
int (*get_stride_scanline)(int color_fmt, int width,
int height, int *stride, int *scanlines);
int (*capability_check)(u32 fourcc, u32 width,
diff --git a/drivers/mfd/wcd9xxx-core.c b/drivers/mfd/wcd9xxx-core.c
index d8abc6d..907ce7c 100644
--- a/drivers/mfd/wcd9xxx-core.c
+++ b/drivers/mfd/wcd9xxx-core.c
@@ -544,8 +544,10 @@
{WCD9XXX_IRQ_PA2_STARTUP, false},
{WCD9XXX_IRQ_PA3_STARTUP, false},
{WCD9XXX_IRQ_PA4_STARTUP, false},
+ {WCD9306_IRQ_HPH_PA_OCPR_FAULT, false},
{WCD9XXX_IRQ_PA5_STARTUP, false},
{WCD9XXX_IRQ_MICBIAS1_PRECHARGE, false},
+ {WCD9306_IRQ_HPH_PA_OCPL_FAULT, false},
{WCD9XXX_IRQ_MICBIAS2_PRECHARGE, false},
{WCD9XXX_IRQ_MICBIAS3_PRECHARGE, false},
{WCD9XXX_IRQ_HPH_PA_OCPL_FAULT, false},
diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c
index 1e2d367..293033b 100644
--- a/drivers/mmc/core/core.c
+++ b/drivers/mmc/core/core.c
@@ -2688,13 +2688,19 @@
unsigned long mmc_get_max_frequency(struct mmc_host *host)
{
unsigned long freq;
+ unsigned char timing;
if (host->ops && host->ops->get_max_frequency) {
freq = host->ops->get_max_frequency(host);
goto out;
}
- switch (host->ios.timing) {
+ if (mmc_card_hs400(host->card))
+ timing = MMC_TIMING_MMC_HS400;
+ else
+ timing = host->ios.timing;
+
+ switch (timing) {
case MMC_TIMING_UHS_SDR50:
freq = UHS_SDR50_MAX_DTR;
break;
@@ -2707,6 +2713,9 @@
case MMC_TIMING_UHS_DDR50:
freq = UHS_DDR50_MAX_DTR;
break;
+ case MMC_TIMING_MMC_HS400:
+ freq = MMC_HS400_MAX_DTR;
+ break;
default:
mmc_host_clk_hold(host);
freq = host->ios.clock;
@@ -2747,6 +2756,9 @@
case MMC_TIMING_MMC_HS200:
freq = MMC_HIGH_52_MAX_DTR;
break;
+ case MMC_TIMING_MMC_HS400:
+ freq = MMC_HIGH_52_MAX_DTR;
+ break;
case MMC_TIMING_UHS_DDR50:
freq = UHS_DDR50_MAX_DTR / 2;
break;
diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
index e1609cf..997e14b 100644
--- a/drivers/mmc/core/mmc.c
+++ b/drivers/mmc/core/mmc.c
@@ -1177,6 +1177,26 @@
return err;
}
+int mmc_set_clock_bus_speed(struct mmc_card *card, unsigned long freq)
+{
+ int err;
+
+ if (freq < MMC_HS400_MAX_DTR) {
+ /*
+ * Lower the clock and adjust the timing to be able
+ * to switch to HighSpeed mode
+ */
+ mmc_set_timing(card->host, MMC_TIMING_LEGACY);
+ mmc_set_clock(card->host, MMC_HIGH_26_MAX_DTR);
+
+ err = mmc_select_hs(card, &card->cached_ext_csd);
+ } else {
+ err = mmc_select_hs400(card, &card->cached_ext_csd);
+ }
+
+ return err;
+}
+
/**
* mmc_change_bus_speed() - Change MMC card bus frequency at runtime
* @host: pointer to mmc host structure
@@ -1219,7 +1239,13 @@
if (*freq < host->f_min)
*freq = host->f_min;
- mmc_set_clock(host, (unsigned int) (*freq));
+ if (mmc_card_hs400(card)) {
+ err = mmc_set_clock_bus_speed(card, *freq);
+ if (err)
+ goto out;
+ } else {
+ mmc_set_clock(host, (unsigned int) (*freq));
+ }
if ((mmc_card_hs400(card) || mmc_card_hs200(card))
&& card->host->ops->execute_tuning) {
@@ -1413,6 +1439,7 @@
err = mmc_get_ext_csd(card, &ext_csd);
if (err)
goto free_card;
+ memcpy(&card->cached_ext_csd, ext_csd, sizeof(card->ext_csd));
err = mmc_read_ext_csd(card, ext_csd);
if (err)
goto free_card;
diff --git a/drivers/net/wireless/Kconfig b/drivers/net/wireless/Kconfig
index 5ccdd2a..0a408b1 100644
--- a/drivers/net/wireless/Kconfig
+++ b/drivers/net/wireless/Kconfig
@@ -314,6 +314,16 @@
---help---
Pre-allocate memory for the WLAN driver module
+config WCNSS_REGISTER_DUMP_ON_BITE
+ bool "Enable/disable WCNSS register dump when there is a WCNSS bite"
+ depends on WCNSS_CORE_PRONTO
+ help
+ When Apps recieves a WDOG bite from WCNSS, collecting a register dump
+ of WCNSS is helpful to root cause the failure. WCNSS may not be
+ properly clocked in some WCNSS bite cases, and that may cause unclocked
+ register access failures. So this feature is to enable/disable the
+ register dump on WCNSS WDOG bite.
+
source "drivers/net/wireless/ath/Kconfig"
source "drivers/net/wireless/b43/Kconfig"
source "drivers/net/wireless/b43legacy/Kconfig"
diff --git a/drivers/net/wireless/wcnss/wcnss_wlan.c b/drivers/net/wireless/wcnss/wcnss_wlan.c
index 64d1478..7b743a4 100644
--- a/drivers/net/wireless/wcnss/wcnss_wlan.c
+++ b/drivers/net/wireless/wcnss/wcnss_wlan.c
@@ -648,6 +648,14 @@
}
EXPORT_SYMBOL(wcnss_pronto_log_debug_regs);
+#ifdef CONFIG_WCNSS_REGISTER_DUMP_ON_BITE
+void wcnss_log_debug_regs_on_bite(void)
+{
+ if (wcnss_hardware_type() == WCNSS_PRONTO_HW)
+ wcnss_pronto_log_debug_regs();
+}
+#endif
+
/* interface to reset wcnss by sending the reset interrupt */
void wcnss_reset_intr(void)
{
diff --git a/drivers/usb/gadget/f_diag.c b/drivers/usb/gadget/f_diag.c
index bccc504..effe0fd 100644
--- a/drivers/usb/gadget/f_diag.c
+++ b/drivers/usb/gadget/f_diag.c
@@ -837,17 +837,28 @@
struct dentry *dent_diag;
static void fdiag_debugfs_init(void)
{
+ struct dentry *dent_diag_status;
dent_diag = debugfs_create_dir("usb_diag", 0);
- if (IS_ERR(dent_diag))
+ if (!dent_diag || IS_ERR(dent_diag))
return;
- debugfs_create_file("status", 0444, dent_diag, 0, &debug_fdiag_ops);
+ dent_diag_status = debugfs_create_file("status", 0444, dent_diag, 0,
+ &debug_fdiag_ops);
+
+ if (!dent_diag_status || IS_ERR(dent_diag_status)) {
+ debugfs_remove(dent_diag);
+ dent_diag = NULL;
+ return;
+ }
+}
+
+static void fdiag_debugfs_remove(void)
+{
+ debugfs_remove_recursive(dent_diag);
}
#else
-static void fdiag_debugfs_init(void)
-{
- return;
-}
+static inline void fdiag_debugfs_init(void) {}
+static inline void fdiag_debugfs_remove(void) {}
#endif
static void diag_cleanup(void)
@@ -856,7 +867,7 @@
struct usb_diag_ch *_ch;
unsigned long flags;
- debugfs_remove_recursive(dent_diag);
+ fdiag_debugfs_remove();
list_for_each_safe(act, tmp, &usb_diag_ch_list) {
_ch = list_entry(act, struct usb_diag_ch, list);
diff --git a/drivers/usb/gadget/f_rmnet.c b/drivers/usb/gadget/f_rmnet.c
index 6bfa203..2fa8c63 100644
--- a/drivers/usb/gadget/f_rmnet.c
+++ b/drivers/usb/gadget/f_rmnet.c
@@ -1219,6 +1219,7 @@
for (i = 0; i < nr_rmnet_ports; i++)
kfree(rmnet_ports[i].port);
+ gbam_cleanup();
nr_rmnet_ports = 0;
no_ctrl_smd_ports = 0;
no_ctrl_qti_ports = 0;
diff --git a/drivers/usb/gadget/f_rmnet_smd.c b/drivers/usb/gadget/f_rmnet_smd.c
index 8aec34f..74a8062 100644
--- a/drivers/usb/gadget/f_rmnet_smd.c
+++ b/drivers/usb/gadget/f_rmnet_smd.c
@@ -5,7 +5,7 @@
* Copyright (C) 2003-2004 Robert Schwebel, Benedikt Spranger
* Copyright (C) 2003 Al Borchers (alborchers@steinerpoint.com)
* Copyright (C) 2008 Nokia Corporation
- * Copyright (c) 2010-2012, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2010-2013, 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 as published by
@@ -1267,19 +1267,17 @@
};
struct dentry *dent_smd;
-struct dentry *dent_smd_status;
-
static void rmnet_smd_debugfs_init(struct rmnet_smd_dev *dev)
{
-
+ struct dentry *dent_smd_status;
dent_smd = debugfs_create_dir("usb_rmnet_smd", 0);
- if (IS_ERR(dent_smd))
+ if (!dent_smd || IS_ERR(dent_smd))
return;
dent_smd_status = debugfs_create_file("status", 0444, dent_smd, dev,
&rmnet_smd_debug_stats_ops);
- if (!dent_smd_status) {
+ if (!dent_smd_status || IS_ERR(dent_smd_status)) {
debugfs_remove(dent_smd);
dent_smd = NULL;
return;
@@ -1287,8 +1285,14 @@
return;
}
+
+static void rmnet_smd_debugfs_remove(void)
+{
+ debugfs_remove_recursive(dent_smd);
+}
#else
-static void rmnet_smd_debugfs_init(struct rmnet_smd_dev *dev) {}
+static inline void rmnet_smd_debugfs_init(struct rmnet_smd_dev *dev) {}
+static inline void rmnet_smd_debugfs_remove(void){}
#endif
static void
@@ -1307,7 +1311,9 @@
dev->epout = dev->epin = dev->epnotify = NULL; /* release endpoints */
destroy_workqueue(dev->wq);
- debugfs_remove_recursive(dent_smd);
+
+ rmnet_smd_debugfs_remove();
+
kfree(dev);
}
diff --git a/drivers/usb/gadget/f_rmnet_smd_sdio.c b/drivers/usb/gadget/f_rmnet_smd_sdio.c
index aa6c99a..2fc758d 100644
--- a/drivers/usb/gadget/f_rmnet_smd_sdio.c
+++ b/drivers/usb/gadget/f_rmnet_smd_sdio.c
@@ -5,7 +5,7 @@
* Copyright (C) 2003-2004 Robert Schwebel, Benedikt Spranger
* Copyright (C) 2003 Al Borchers (alborchers@steinerpoint.com)
* Copyright (C) 2008 Nokia Corporation
- * Copyright (c) 2011 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2011,2013 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
@@ -1758,16 +1758,28 @@
static void rmnet_mux_debugfs_init(struct rmnet_mux_dev *dev)
{
-
+ struct dentry *dent_rmnet_mux_status;
dent_rmnet_mux = debugfs_create_dir("usb_rmnet_mux", 0);
- if (IS_ERR(dent_rmnet_mux))
+ if (!dent_rmnet_mux || IS_ERR(dent_rmnet_mux))
return;
- debugfs_create_file("status", 0444, dent_rmnet_mux, dev,
+ dent_rmnet_mux_status = debugfs_create_file("status",
+ 0444, dent_rmnet_mux, dev,
&rmnet_mux_svlte_debug_stats_ops);
+ if (!dent_rmnet_mux_status) {
+ debugfs_remove(dent_rmnet_mux);
+ dent_rmnet_mux = NULL;
+ return;
+ }
+}
+
+static void rmnet_mux_debugfs_remove(void)
+{
+ debugfs_remove_recursive(dent_rmnet_mux);
}
#else
-static void rmnet_mux_debugfs_init(struct rmnet_mux_dev *dev) {}
+static inline void rmnet_mux_debugfs_init(struct rmnet_mux_dev *dev) {}
+static inline void rmnet_mux_debugfs_remove(void) {}
#endif
int usb_rmnet_mux_ctrl_open(struct inode *inode, struct file *fp)
@@ -2037,7 +2049,7 @@
struct rmnet_mux_dev *dev = rmux_dev;
struct rmnet_mux_smd_dev *smd_dev = &dev->smd_dev;
- debugfs_remove_recursive(dent_rmnet_mux);
+ rmnet_mux_debugfs_remove();
misc_deregister(&rmnet_mux_ctrl_dev);
smd_close(smd_dev->smd_data.ch);
destroy_workqueue(dev->wq);
diff --git a/drivers/usb/gadget/u_bam.c b/drivers/usb/gadget/u_bam.c
index b0b2f56..843c207 100644
--- a/drivers/usb/gadget/u_bam.c
+++ b/drivers/usb/gadget/u_bam.c
@@ -1281,22 +1281,30 @@
.write = gbam_reset_stats,
};
+struct dentry *gbam_dent;
static void gbam_debugfs_init(void)
{
- struct dentry *dent;
struct dentry *dfile;
- dent = debugfs_create_dir("usb_rmnet", 0);
- if (IS_ERR(dent))
+ gbam_dent = debugfs_create_dir("usb_rmnet", 0);
+ if (!gbam_dent || IS_ERR(gbam_dent))
return;
- /* TODO: Implement cleanup function to remove created file */
- dfile = debugfs_create_file("status", 0444, dent, 0, &gbam_stats_ops);
- if (!dfile || IS_ERR(dfile))
- debugfs_remove(dent);
+ dfile = debugfs_create_file("status", 0444, gbam_dent, 0,
+ &gbam_stats_ops);
+ if (!dfile || IS_ERR(dfile)) {
+ debugfs_remove(gbam_dent);
+ gbam_dent = NULL;
+ return;
+ }
+}
+static void gbam_debugfs_remove(void)
+{
+ debugfs_remove_recursive(gbam_dent);
}
#else
-static void gam_debugfs_init(void) { }
+static inline void gbam_debugfs_init(void) {}
+static inline void gbam_debugfs_remove(void) {}
#endif
void gbam_disconnect(struct grmnet *gr, u8 port_num, enum transport_type trans)
@@ -1445,7 +1453,6 @@
d->trans = trans;
queue_work(gbam_wq, &port->connect_w);
-
return 0;
}
@@ -1490,6 +1497,7 @@
goto free_bam_ports;
}
}
+
gbam_debugfs_init();
return 0;
@@ -1503,6 +1511,11 @@
return ret;
}
+void gbam_cleanup(void)
+{
+ gbam_debugfs_remove();
+}
+
void gbam_suspend(struct grmnet *gr, u8 port_num, enum transport_type trans)
{
struct gbam_port *port;
diff --git a/drivers/usb/gadget/u_ctrl_hsuart.c b/drivers/usb/gadget/u_ctrl_hsuart.c
index 3443d12..b57e4e3 100644
--- a/drivers/usb/gadget/u_ctrl_hsuart.c
+++ b/drivers/usb/gadget/u_ctrl_hsuart.c
@@ -479,6 +479,7 @@
return ret;
}
+#if defined(CONFIG_DEBUG_FS)
#define DEBUG_BUF_SIZE 1024
static ssize_t ghsuart_ctrl_read_stats(struct file *file, char __user *ubuf,
size_t count, loff_t *ppos)
@@ -558,7 +559,7 @@
ghsuart_ctrl_dfile =
debugfs_create_file("status", S_IRUGO | S_IWUSR,
- ghsuart_ctrl_dent, 0, &gctrl_stats_ops);
+ ghsuart_ctrl_dent, 0, &ghsuart_ctrl_stats_ops);
if (!ghsuart_ctrl_dfile || IS_ERR(ghsuart_ctrl_dfile)) {
debugfs_remove(ghsuart_ctrl_dent);
ghsuart_ctrl_dent = NULL;
@@ -571,6 +572,10 @@
{
debugfs_remove_recursive(ghsuart_ctrl_dent);
}
+#else
+static int ghsuart_ctrl_debugfs_init(void) { return 0; }
+static void ghsuart_ctrl_debugfs_exit(void) {}
+#endif
static int __init ghsuart_ctrl_init(void)
{
diff --git a/drivers/usb/gadget/u_rmnet.h b/drivers/usb/gadget/u_rmnet.h
index 06471a4..6a80529 100644
--- a/drivers/usb/gadget/u_rmnet.h
+++ b/drivers/usb/gadget/u_rmnet.h
@@ -54,6 +54,7 @@
};
int gbam_setup(unsigned int no_bam_port, unsigned int no_bam2bam_port);
+void gbam_cleanup(void);
int gbam_connect(struct grmnet *gr, u8 port_num,
enum transport_type trans, u8 src_connection_idx,
u8 dst_connection_idx);
diff --git a/drivers/usb/gadget/u_serial.c b/drivers/usb/gadget/u_serial.c
index 350e723..299f620c 100644
--- a/drivers/usb/gadget/u_serial.c
+++ b/drivers/usb/gadget/u_serial.c
@@ -4,6 +4,7 @@
* Copyright (C) 2003 Al Borchers (alborchers@steinerpoint.com)
* Copyright (C) 2008 David Brownell
* Copyright (C) 2008 by Nokia Corporation
+ * Copyright (c) 2013, The Linux Foundation. All rights reserved.
*
* This code also borrows from usbserial.c, which is
* Copyright (C) 1999 - 2002 Greg Kroah-Hartman (greg@kroah.com)
@@ -1294,22 +1295,29 @@
.read = debug_read_status,
};
+struct dentry *gs_dent;
static void usb_debugfs_init(struct gs_port *ui_dev, int port_num)
{
- struct dentry *dent;
char buf[48];
snprintf(buf, 48, "usb_serial%d", port_num);
- dent = debugfs_create_dir(buf, 0);
- if (IS_ERR(dent))
+ gs_dent = debugfs_create_dir(buf, 0);
+ if (!gs_dent || IS_ERR(gs_dent))
return;
- debugfs_create_file("readstatus", 0444, dent, ui_dev, &debug_adb_ops);
+ debugfs_create_file("readstatus", 0444, gs_dent, ui_dev,
+ &debug_adb_ops);
debugfs_create_file("reset", S_IRUGO | S_IWUSR,
- dent, ui_dev, &debug_rst_ops);
+ gs_dent, ui_dev, &debug_rst_ops);
+}
+
+static void usb_debugfs_remove(void)
+{
+ debugfs_remove_recursive(gs_dent);
}
#else
-static void usb_debugfs_init(struct gs_port *ui_dev) {}
+static inline void usb_debugfs_init(struct gs_port *ui_dev, int port_num) {}
+static inline void usb_debugfs_remove(void) {}
#endif
/**
@@ -1474,6 +1482,7 @@
}
n_ports = 0;
+ usb_debugfs_remove();
destroy_workqueue(gserial_wq);
tty_unregister_driver(gs_tty_driver);
put_tty_driver(gs_tty_driver);
diff --git a/drivers/video/msm/mdss/mdss.h b/drivers/video/msm/mdss/mdss.h
index 3bf27e2..5857606 100644
--- a/drivers/video/msm/mdss/mdss.h
+++ b/drivers/video/msm/mdss/mdss.h
@@ -69,6 +69,8 @@
struct clk *mdp_clk[MDSS_MAX_CLK];
struct regulator *fs;
struct regulator *vdd_cx;
+ bool batfet_required;
+ struct regulator *batfet;
u32 max_mdp_clk_rate;
struct platform_device *pdev;
diff --git a/drivers/video/msm/mdss/mdss_dsi.c b/drivers/video/msm/mdss/mdss_dsi.c
index b353c96..c94db64 100644
--- a/drivers/video/msm/mdss/mdss_dsi.c
+++ b/drivers/video/msm/mdss/mdss_dsi.c
@@ -751,6 +751,7 @@
mdss_dsi_clk_req(ctrl_pdata, (int)arg);
break;
case MDSS_EVENT_DSI_CMDLIST_KOFF:
+ ctrl_pdata->recovery = (struct mdss_panel_recovery *)arg;
mdss_dsi_cmdlist_commit(ctrl_pdata, 1);
case MDSS_EVENT_PANEL_UPDATE_FPS:
if (arg != NULL) {
diff --git a/drivers/video/msm/mdss/mdss_dsi.h b/drivers/video/msm/mdss/mdss_dsi.h
index 121d6ff..6953d8b 100644
--- a/drivers/video/msm/mdss/mdss_dsi.h
+++ b/drivers/video/msm/mdss/mdss_dsi.h
@@ -307,6 +307,10 @@
DSI_CTRL_MAX,
};
+#define DSI_EV_PLL_UNLOCKED 0x0001
+#define DSI_EV_MDP_FIFO_UNDERFLOW 0x0002
+#define DSI_EV_MDP_BUSY_RELEASE 0x80000000
+
struct mdss_dsi_ctrl_pdata {
int ndx; /* panel_num */
int (*on) (struct mdss_panel_data *pdata);
@@ -339,6 +343,7 @@
int pwm_lpg_chan;
int bklt_max;
int new_fps;
+ int pwm_enabled;
struct pwm_device *pwm_bl;
struct dsi_drv_cm_data shared_pdata;
u32 pclk_rate;
@@ -346,6 +351,7 @@
struct dss_module_power power_data;
u32 dsi_irq_mask;
struct mdss_hw *dsi_hw;
+ struct mdss_panel_recovery *recovery;
struct dsi_panel_cmds on_cmds;
struct dsi_panel_cmds off_cmds;
@@ -388,7 +394,7 @@
void mdp4_dsi_cmd_trigger(void);
void mdss_dsi_cmd_mdp_start(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_cmd_bta_sw_trigger(struct mdss_panel_data *pdata);
-void mdss_dsi_ack_err_status(unsigned char *dsi_base);
+void mdss_dsi_ack_err_status(struct mdss_dsi_ctrl_pdata *ctrl);
int mdss_dsi_clk_ctrl(struct mdss_dsi_ctrl_pdata *ctrl, int enable);
void mdss_dsi_clk_req(struct mdss_dsi_ctrl_pdata *ctrl,
int enable);
diff --git a/drivers/video/msm/mdss/mdss_dsi_host.c b/drivers/video/msm/mdss/mdss_dsi_host.c
index 62bc7e6..845ef10 100644
--- a/drivers/video/msm/mdss/mdss_dsi_host.c
+++ b/drivers/video/msm/mdss/mdss_dsi_host.c
@@ -19,11 +19,13 @@
#include <linux/dma-mapping.h>
#include <linux/slab.h>
#include <linux/iopoll.h>
+#include <linux/kthread.h>
#include <mach/iommu_domains.h>
#include "mdss.h"
#include "mdss_dsi.h"
+#include "mdss_panel.h"
#define VSYNC_PERIOD 17
@@ -44,6 +46,28 @@
.irq_handler = mdss_dsi_isr,
};
+
+#define DSI_EVENT_Q_MAX 4
+
+/* event */
+struct dsi_event_q {
+ struct mdss_dsi_ctrl_pdata *ctrl;
+ u32 todo;
+};
+
+struct mdss_dsi_event {
+ int inited;
+ wait_queue_head_t event_q;
+ u32 event_pndx;
+ u32 event_gndx;
+ struct dsi_event_q todo_list[DSI_EVENT_Q_MAX];
+ spinlock_t event_lock;
+};
+
+static struct mdss_dsi_event dsi_event;
+
+static int dsi_event_thread(void *data);
+
void mdss_dsi_ctrl_init(struct mdss_dsi_ctrl_pdata *ctrl)
{
if (ctrl->shared_pdata.broadcast_enable)
@@ -80,6 +104,13 @@
mutex_init(&ctrl->cmd_mutex);
mdss_dsi_buf_alloc(&ctrl->tx_buf, SZ_4K);
mdss_dsi_buf_alloc(&ctrl->rx_buf, SZ_4K);
+
+
+ if (dsi_event.inited == 0) {
+ kthread_run(dsi_event_thread, (void *)&dsi_event,
+ "mdss_dsi_event");
+ dsi_event.inited = 1;
+ }
}
void mdss_dsi_clk_req(struct mdss_dsi_ctrl_pdata *ctrl, int enable)
@@ -94,6 +125,21 @@
mdss_dsi_clk_ctrl(ctrl, enable);
}
+void mdss_dsi_pll_relock(struct mdss_dsi_ctrl_pdata *ctrl)
+{
+ int i, cnt;
+
+ cnt = ctrl->clk_cnt;
+
+ /* disable dsi clk */
+ for (i = 0; i < cnt; i++)
+ mdss_dsi_clk_ctrl(ctrl, 0);
+
+ /* enable dsi clk */
+ for (i = 0; i < cnt; i++)
+ mdss_dsi_clk_ctrl(ctrl, 1);
+}
+
void mdss_dsi_enable_irq(struct mdss_dsi_ctrl_pdata *ctrl, u32 term)
{
unsigned long flags;
@@ -942,6 +988,50 @@
wmb();
}
+void mdss_dsi_sw_reset_restore(struct mdss_dsi_ctrl_pdata *ctrl)
+{
+ u32 data0, data1;
+
+ data0 = MIPI_INP(ctrl->ctrl_base + 0x0004);
+ data1 = data0;
+ data1 &= ~0x01;
+ MIPI_OUTP(ctrl->ctrl_base + 0x0004, data1);
+ /*
+ * dsi controller need to be disabled before
+ * clocks turned on
+ */
+ wmb(); /* make sure dsi contoller is disabled */
+
+ /* turn esc, byte, dsi, pclk, sclk, hclk on */
+ MIPI_OUTP(ctrl->ctrl_base + 0x11c, 0x23f); /* DSI_CLK_CTRL */
+ wmb(); /* make sure clocks enabled */
+
+ /* dsi controller can only be reset while clocks are running */
+ MIPI_OUTP(ctrl->ctrl_base + 0x118, 0x01);
+ wmb(); /* make sure reset happen */
+ MIPI_OUTP(ctrl->ctrl_base + 0x118, 0x00);
+ wmb(); /* controller out of reset */
+ MIPI_OUTP(ctrl->ctrl_base + 0x0004, data0);
+ wmb(); /* make sure dsi controller enabled again */
+}
+
+void mdss_dsi_err_intr_ctrl(struct mdss_dsi_ctrl_pdata *ctrl, u32 mask,
+ int enable)
+{
+ u32 intr;
+
+ intr = MIPI_INP(ctrl->ctrl_base + 0x0110);
+
+ if (enable)
+ intr |= mask;
+ else
+ intr &= ~mask;
+
+ pr_debug("%s: intr=%x enable=%d\n", __func__, intr, enable);
+
+ MIPI_OUTP(ctrl->ctrl_base + 0x0110, intr); /* DSI_INTL_CTRL */
+}
+
void mdss_dsi_controller_cfg(int enable,
struct mdss_panel_data *pdata)
{
@@ -1072,7 +1162,7 @@
0, timeout_us))
pr_info("%s: DSI status=%x failed\n", __func__, status);
- mdss_dsi_ack_err_status((ctrl_pdata->ctrl_base));
+ mdss_dsi_ack_err_status(ctrl_pdata);
pr_debug("%s: BTA done, status = %d\n", __func__, status);
}
@@ -1746,9 +1836,89 @@
return ret;
}
-void mdss_dsi_ack_err_status(unsigned char *base)
+
+static void dsi_send_events(struct mdss_dsi_ctrl_pdata *ctrl, u32 events)
+{
+ struct dsi_event_q *evq;
+
+ if (!dsi_event.inited)
+ return;
+
+ pr_debug("%s: ev=%x\n", __func__, events);
+
+ spin_lock(&dsi_event.event_lock);
+ evq = &dsi_event.todo_list[dsi_event.event_pndx++];
+ evq->todo = events;
+ evq->ctrl = ctrl;
+ dsi_event.event_pndx %= DSI_EVENT_Q_MAX;
+ wake_up(&dsi_event.event_q);
+ spin_unlock(&dsi_event.event_lock);
+}
+
+static int dsi_event_thread(void *data)
+{
+ struct mdss_dsi_event *ev;
+ struct dsi_event_q *evq;
+ struct mdss_dsi_ctrl_pdata *ctrl;
+ unsigned long flag;
+ struct sched_param param;
+ u32 todo = 0;
+ int ret;
+
+ param.sched_priority = 16;
+ ret = sched_setscheduler_nocheck(current, SCHED_FIFO, ¶m);
+ if (ret)
+ pr_err("%s: set priority failed\n", __func__);
+
+ ev = (struct mdss_dsi_event *)data;
+ /* event */
+ init_waitqueue_head(&ev->event_q);
+ spin_lock_init(&ev->event_lock);
+
+ while (1) {
+ wait_event(ev->event_q, (ev->event_pndx != ev->event_gndx));
+ spin_lock_irqsave(&ev->event_lock, flag);
+ evq = &ev->todo_list[ev->event_gndx++];
+ todo = evq->todo;
+ ctrl = evq->ctrl;
+ evq->todo = 0;
+ ev->event_gndx %= DSI_EVENT_Q_MAX;
+ spin_unlock_irqrestore(&ev->event_lock, flag);
+
+ pr_debug("%s: ev=%x\n", __func__, todo);
+
+ if (todo & DSI_EV_PLL_UNLOCKED)
+ mdss_dsi_pll_relock(ctrl);
+
+ if (todo & DSI_EV_MDP_FIFO_UNDERFLOW) {
+ if (ctrl->recovery) {
+ mdss_dsi_sw_reset_restore(ctrl);
+ ctrl->recovery->fxn(ctrl->recovery->data);
+ }
+ }
+
+ if (todo & DSI_EV_MDP_BUSY_RELEASE) {
+ spin_lock(&ctrl->mdp_lock);
+ ctrl->mdp_busy = false;
+ mdss_dsi_disable_irq_nosync(ctrl, DSI_MDP_TERM);
+ complete(&ctrl->mdp_comp);
+ spin_unlock(&ctrl->mdp_lock);
+
+ /* enable dsi error interrupt */
+ mdss_dsi_err_intr_ctrl(ctrl, DSI_INTR_ERROR_MASK, 1);
+ }
+
+ }
+
+ return 0;
+}
+
+void mdss_dsi_ack_err_status(struct mdss_dsi_ctrl_pdata *ctrl)
{
u32 status;
+ unsigned char *base;
+
+ base = ctrl->ctrl_base;
status = MIPI_INP(base + 0x0068);/* DSI_ACK_ERR_STATUS */
@@ -1758,20 +1928,27 @@
}
}
-void mdss_dsi_timeout_status(unsigned char *base)
+void mdss_dsi_timeout_status(struct mdss_dsi_ctrl_pdata *ctrl)
{
u32 status;
+ unsigned char *base;
+
+ base = ctrl->ctrl_base;
status = MIPI_INP(base + 0x00c0);/* DSI_TIMEOUT_STATUS */
+
if (status & 0x0111) {
MIPI_OUTP(base + 0x00c0, status);
pr_err("%s: status=%x\n", __func__, status);
}
}
-void mdss_dsi_dln0_phy_err(unsigned char *base)
+void mdss_dsi_dln0_phy_err(struct mdss_dsi_ctrl_pdata *ctrl)
{
u32 status;
+ unsigned char *base;
+
+ base = ctrl->ctrl_base;
status = MIPI_INP(base + 0x00b4);/* DSI_DLN0_PHY_ERR */
@@ -1781,44 +1958,70 @@
}
}
-void mdss_dsi_fifo_status(unsigned char *base)
+void mdss_dsi_fifo_status(struct mdss_dsi_ctrl_pdata *ctrl)
{
u32 status;
+ unsigned char *base;
+
+ base = ctrl->ctrl_base;
status = MIPI_INP(base + 0x000c);/* DSI_FIFO_STATUS */
- if (status & 0x44444489) {
+ /* fifo underflow, overflow */
+ if (status & 0xcccc4489) {
MIPI_OUTP(base + 0x000c, status);
pr_err("%s: status=%x\n", __func__, status);
+ if (status & 0x0080) /* CMD_DMA_FIFO_UNDERFLOW */
+ dsi_send_events(ctrl, DSI_EV_MDP_FIFO_UNDERFLOW);
+ }
+}
+
+void mdss_dsi_status(struct mdss_dsi_ctrl_pdata *ctrl)
+{
+ u32 status;
+ unsigned char *base;
+
+ base = ctrl->ctrl_base;
+
+ status = MIPI_INP(base + 0x0008);/* DSI_STATUS */
+
+ if (status & 0x80000000) { /* INTERLEAVE_OP_CONTENTION */
+ MIPI_OUTP(base + 0x0008, status);
+ pr_err("%s: status=%x\n", __func__, status);
}
}
-void mdss_dsi_status(unsigned char *base)
+void mdss_dsi_clk_status(struct mdss_dsi_ctrl_pdata *ctrl)
{
u32 status;
+ unsigned char *base;
- status = MIPI_INP(base + 0x0008);/* DSI_STATUS */
+ base = ctrl->ctrl_base;
+ status = MIPI_INP(base + 0x0120);/* DSI_CLK_STATUS */
- if (status & 0x80000000) {
- MIPI_OUTP(base + 0x0008, status);
+ if (status & 0x10000) { /* DSI_CLK_PLL_UNLOCKED */
+ MIPI_OUTP(base + 0x0120, status);
+ dsi_send_events(ctrl, DSI_EV_PLL_UNLOCKED);
pr_err("%s: status=%x\n", __func__, status);
}
}
void mdss_dsi_error(struct mdss_dsi_ctrl_pdata *ctrl)
{
- unsigned char *base;
- base = ctrl->ctrl_base;
+ /* disable dsi error interrupt */
+ mdss_dsi_err_intr_ctrl(ctrl, DSI_INTR_ERROR_MASK, 0);
/* DSI_ERR_INT_MASK0 */
- mdss_dsi_ack_err_status(base); /* mask0, 0x01f */
- mdss_dsi_timeout_status(base); /* mask0, 0x0e0 */
- mdss_dsi_fifo_status(base); /* mask0, 0x133d00 */
- mdss_dsi_status(base); /* mask0, 0xc0100 */
- mdss_dsi_dln0_phy_err(base); /* mask0, 0x3e00000 */
-}
+ mdss_dsi_clk_status(ctrl); /* Mask0, 0x10000000 */
+ mdss_dsi_fifo_status(ctrl); /* mask0, 0x133d00 */
+ mdss_dsi_ack_err_status(ctrl); /* mask0, 0x01f */
+ mdss_dsi_timeout_status(ctrl); /* mask0, 0x0e0 */
+ mdss_dsi_status(ctrl); /* mask0, 0xc0100 */
+ mdss_dsi_dln0_phy_err(ctrl); /* mask0, 0x3e00000 */
+ dsi_send_events(ctrl, DSI_EV_MDP_BUSY_RELEASE);
+}
irqreturn_t mdss_dsi_isr(int irq, void *ptr)
{
@@ -1846,12 +2049,7 @@
if (isr & DSI_INTR_ERROR) {
pr_err("%s: isr=%x %x", __func__, isr, (int)DSI_INTR_ERROR);
- spin_lock(&ctrl->mdp_lock);
- ctrl->mdp_busy = false;
- mdss_dsi_disable_irq_nosync(ctrl, DSI_MDP_TERM);
- complete(&ctrl->mdp_comp);
mdss_dsi_error(ctrl);
- spin_unlock(&ctrl->mdp_lock);
}
if (isr & DSI_INTR_VIDEO_DONE) {
diff --git a/drivers/video/msm/mdss/mdss_dsi_panel.c b/drivers/video/msm/mdss/mdss_dsi_panel.c
index 262b7bd..33109e1 100644
--- a/drivers/video/msm/mdss/mdss_dsi_panel.c
+++ b/drivers/video/msm/mdss/mdss_dsi_panel.c
@@ -66,6 +66,13 @@
return;
}
+ if (level == 0) {
+ if (ctrl->pwm_enabled)
+ pwm_disable(ctrl->pwm_bl);
+ ctrl->pwm_enabled = 0;
+ return;
+ }
+
duty = level * ctrl->pwm_period;
duty /= ctrl->bklt_max;
@@ -76,6 +83,11 @@
pr_debug("%s: ndx=%d level=%d duty=%d\n", __func__,
ctrl->ndx, level, duty);
+ if (ctrl->pwm_enabled) {
+ pwm_disable(ctrl->pwm_bl);
+ ctrl->pwm_enabled = 0;
+ }
+
ret = pwm_config(ctrl->pwm_bl, duty, ctrl->pwm_period);
if (ret) {
pr_err("%s: pwm_config() failed err=%d.\n", __func__, ret);
@@ -85,6 +97,7 @@
ret = pwm_enable(ctrl->pwm_bl);
if (ret)
pr_err("%s: pwm_enable() failed err=%d\n", __func__, ret);
+ ctrl->pwm_enabled = 1;
}
static char dcs_cmd[2] = {0x54, 0x00}; /* DTYPE_DCS_READ */
@@ -182,14 +195,15 @@
pinfo = &(ctrl_pdata->panel_data.panel_info);
if (enable) {
+ if (gpio_is_valid(ctrl_pdata->disp_en_gpio))
+ gpio_set_value((ctrl_pdata->disp_en_gpio), 1);
+
for (i = 0; i < pdata->panel_info.rst_seq_len; ++i) {
gpio_set_value((ctrl_pdata->rst_gpio),
pdata->panel_info.rst_seq[i]);
if (pdata->panel_info.rst_seq[++i])
usleep(pdata->panel_info.rst_seq[i] * 1000);
}
- if (gpio_is_valid(ctrl_pdata->disp_en_gpio))
- gpio_set_value((ctrl_pdata->disp_en_gpio), 1);
if (gpio_is_valid(ctrl_pdata->mode_gpio)) {
if (pinfo->mode_gpio_state == MODE_GPIO_HIGH)
diff --git a/drivers/video/msm/mdss/mdss_hdmi_edid.c b/drivers/video/msm/mdss/mdss_hdmi_edid.c
index b000e2f..0074873 100644
--- a/drivers/video/msm/mdss/mdss_hdmi_edid.c
+++ b/drivers/video/msm/mdss/mdss_hdmi_edid.c
@@ -29,6 +29,9 @@
#define BUFF_SIZE_3D 128
+/* Support for first 5 EDID blocks */
+#define MAX_EDID_BLOCK_SIZE (0x80 * 5)
+
struct hdmi_edid_sink_data {
u32 disp_mode_list[HDMI_VFRMT_MAX];
u32 disp_3d_mode_list[HDMI_VFRMT_MAX];
@@ -52,6 +55,7 @@
int adb_size;
u8 spkr_alloc_data_block[MAX_SPKR_ALLOC_DATA_BLOCK_SIZE];
int sadb_size;
+ u8 edid_buf[MAX_EDID_BLOCK_SIZE];
struct hdmi_edid_sink_data sink_data;
struct hdmi_edid_init_data init_data;
@@ -352,11 +356,30 @@
} /* hdmi_edid_sysfs_rda_3d_modes */
static DEVICE_ATTR(edid_3d_modes, S_IRUGO, hdmi_edid_sysfs_rda_3d_modes, NULL);
+static ssize_t hdmi_common_rda_edid_raw_data(struct device *dev,
+ struct device_attribute *attr, char *buf)
+{
+ struct hdmi_edid_ctrl *edid_ctrl =
+ hdmi_get_featuredata_from_sysfs_dev(dev, HDMI_TX_FEAT_EDID);
+
+ if (!edid_ctrl) {
+ DEV_ERR("%s: invalid input\n", __func__);
+ return -EINVAL;
+ }
+
+ memcpy(buf, edid_ctrl->edid_buf,
+ sizeof(edid_ctrl->edid_buf));
+
+ return sizeof(edid_ctrl->edid_buf);
+} /* hdmi_common_rda_edid_raw_data */
+static DEVICE_ATTR(edid_raw_data, S_IRUGO, hdmi_common_rda_edid_raw_data, NULL);
+
static struct attribute *hdmi_edid_fs_attrs[] = {
&dev_attr_edid_modes.attr,
&dev_attr_pa.attr,
&dev_attr_scan_info.attr,
&dev_attr_edid_3d_modes.attr,
+ &dev_attr_edid_raw_data.attr,
NULL,
};
@@ -1305,7 +1328,7 @@
int hdmi_edid_read(void *input)
{
/* EDID_BLOCK_SIZE[0x80] Each page size in the EDID ROM */
- u8 edid_buf[0x80 * 4];
+ u8 *edid_buf = NULL;
u32 cea_extension_ver = 0;
u32 num_of_cea_blocks = 0;
u32 ieee_reg_id = 0;
@@ -1319,12 +1342,14 @@
return -EINVAL;
}
+ edid_buf = edid_ctrl->edid_buf;
+
edid_ctrl->pt_scan_info = 0;
edid_ctrl->it_scan_info = 0;
edid_ctrl->ce_scan_info = 0;
edid_ctrl->present_3d = 0;
memset(&edid_ctrl->sink_data, 0, sizeof(edid_ctrl->sink_data));
- memset(edid_buf, 0, sizeof(edid_buf));
+ memset(edid_buf, 0, sizeof(edid_ctrl->edid_buf));
memset(edid_ctrl->audio_data_block, 0,
sizeof(edid_ctrl->audio_data_block));
memset(edid_ctrl->spkr_alloc_data_block, 0,
@@ -1391,7 +1416,7 @@
for (i = 1; i <= num_of_cea_blocks; i++) {
if (!(i % 2)) {
status = hdmi_edid_read_block(
- edid_ctrl, i, edid_buf+0x00);
+ edid_ctrl, i, edid_buf + (0x80 * i));
if (status) {
DEV_ERR("%s: read blk(%d) failed:%d\n",
__func__, i, status);
@@ -1399,7 +1424,7 @@
}
} else {
status = hdmi_edid_read_block(
- edid_ctrl, i, edid_buf+0x80);
+ edid_ctrl, i, edid_buf + (0x80 * i));
if (status) {
DEV_ERR("%s: read blk(%d) failed:%d\n",
__func__, i, status);
diff --git a/drivers/video/msm/mdss/mdss_hdmi_hdcp.c b/drivers/video/msm/mdss/mdss_hdmi_hdcp.c
index 367c918..bf28e8c 100644
--- a/drivers/video/msm/mdss/mdss_hdmi_hdcp.c
+++ b/drivers/video/msm/mdss/mdss_hdmi_hdcp.c
@@ -17,6 +17,7 @@
#include <linux/stat.h>
#include "mdss_hdmi_hdcp.h"
+#include "video/msm_hdmi_hdcp_mgr.h"
#define HDCP_STATE_NAME (hdcp_state_name(hdcp_ctrl->hdcp_state))
@@ -31,7 +32,11 @@
#define HDCP_KEYS_STATE_RESERVED 7
struct hdmi_hdcp_ctrl {
+ u32 auth_retries;
+ u32 tp_msgid;
enum hdmi_hdcp_state hdcp_state;
+ struct HDCP_V2V1_MSG_TOPOLOGY cached_tp;
+ struct HDCP_V2V1_MSG_TOPOLOGY current_tp;
struct delayed_work hdcp_auth_work;
struct work_struct hdcp_int_work;
struct completion r0_checked;
@@ -194,7 +199,7 @@
bool is_match;
bool stale_an = false;
struct dss_io_data *io;
- u8 aksv[5], bksv[5];
+ u8 aksv[5], *bksv = NULL;
u8 an[8];
u8 bcaps;
struct hdmi_tx_ddc_data ddc_data;
@@ -215,6 +220,8 @@
goto error;
}
+ bksv = hdcp_ctrl->current_tp.bksv;
+
io = hdcp_ctrl->init_data.core_io;
/* Fetch aksv from QFPROM, this info should be public. */
@@ -606,11 +613,12 @@
{
int rc, cnt, i;
struct hdmi_tx_ddc_data ddc_data;
- u32 timeout_count, down_stream_devices;
+ u32 timeout_count, down_stream_devices = 0;
+ u32 repeater_cascade_depth = 0;
u8 buf[0xFF];
- u8 ksv_fifo[5 * 127];
+ u8 *ksv_fifo = NULL;
u8 bcaps;
- u16 bstatus, max_devs_exceeded, max_cascade_exceeded;
+ u16 bstatus, max_devs_exceeded = 0, max_cascade_exceeded = 0;
u32 link0_status;
u32 ksv_bytes;
struct dss_io_data *io;
@@ -628,10 +636,13 @@
goto error;
}
+ ksv_fifo = hdcp_ctrl->current_tp.ksv_list;
+
io = hdcp_ctrl->init_data.core_io;
memset(buf, 0, sizeof(buf));
- memset(ksv_fifo, 0, sizeof(ksv_fifo));
+ memset(ksv_fifo, 0,
+ sizeof(hdcp_ctrl->current_tp.ksv_list));
/* Read BCAPS at offset 0x40 */
memset(&ddc_data, 0, sizeof(ddc_data));
@@ -652,6 +663,10 @@
DEV_DBG("%s: %s: BCAPS=%02x (%s)\n", __func__, HDCP_STATE_NAME, bcaps,
(bcaps & BIT(6)) ? "repeater" : "no repeater");
+ /* receiver (0), repeater (1) */
+ hdcp_ctrl->current_tp.ds_type =
+ (bcaps & BIT(6)) >> 6 ? DS_REPEATER : DS_RECEIVER;
+
/* if REPEATER (Bit 6), perform Part2 Authentication */
if (!(bcaps & BIT(6))) {
DEV_INFO("%s: %s: auth part II skipped, no repeater\n",
@@ -717,6 +732,9 @@
goto error;
}
+ /* Cascaded repeater depth */
+ repeater_cascade_depth = (bstatus >> 8) & 0x7;
+
/*
* HDCP Compliance 1B-05:
* Check if no. of devices connected to repeater
@@ -866,9 +884,46 @@
else
DEV_INFO("%s: %s: Authentication Part II successful\n",
__func__, HDCP_STATE_NAME);
+
+ /* Update topology information */
+ hdcp_ctrl->current_tp.dev_count = down_stream_devices;
+ hdcp_ctrl->current_tp.max_cascade_exceeded = max_cascade_exceeded;
+ hdcp_ctrl->current_tp.max_dev_exceeded = max_devs_exceeded;
+ hdcp_ctrl->current_tp.depth = repeater_cascade_depth;
+
return rc;
} /* hdmi_hdcp_authentication_part2 */
+static void hdmi_hdcp_cache_topology(struct hdmi_hdcp_ctrl *hdcp_ctrl)
+{
+ if (!hdcp_ctrl || !hdcp_ctrl->init_data.core_io) {
+ DEV_ERR("%s: invalid input\n", __func__);
+ return;
+ }
+
+ memcpy((void *)&hdcp_ctrl->cached_tp,
+ (void *) &hdcp_ctrl->current_tp,
+ sizeof(hdcp_ctrl->cached_tp));
+}
+
+static void hdmi_hdcp_notify_topology(struct hdmi_hdcp_ctrl *hdcp_ctrl)
+{
+ char a[16], b[16];
+ char *envp[] = {
+ [0] = "HDCP_MGR_EVENT=MSG_READY",
+ [1] = a,
+ [2] = b,
+ NULL,
+ };
+
+ snprintf(envp[1], 16, "%d", (int)DOWN_CHECK_TOPOLOGY);
+ snprintf(envp[2], 16, "%d", (int)HDCP_V1_TX);
+ kobject_uevent_env(hdcp_ctrl->init_data.sysfs_kobj, KOBJ_CHANGE, envp);
+
+ DEV_DBG("%s Event Sent: %s msgID = %s srcID = %s\n", __func__,
+ envp[0], envp[1], envp[2]);
+}
+
static void hdmi_hdcp_int_work(struct work_struct *work)
{
struct hdmi_hdcp_ctrl *hdcp_ctrl = container_of(work,
@@ -928,7 +983,7 @@
goto error;
}
/* Disabling software DDC before going into part3 to make sure
- * there is no Arbitratioon between software and hardware for DDC */
+ * there is no Arbitration between software and hardware for DDC */
DSS_REG_W_ND(io, HDMI_DDC_ARBITRATION , DSS_REG_R(io,
HDMI_DDC_ARBITRATION) | (BIT(4)));
@@ -941,10 +996,14 @@
*/
mutex_lock(hdcp_ctrl->init_data.mutex);
if (HDCP_STATE_AUTHENTICATING == hdcp_ctrl->hdcp_state) {
- if (rc)
+ if (rc) {
hdcp_ctrl->hdcp_state = HDCP_STATE_AUTH_FAIL;
- else
+ } else {
hdcp_ctrl->hdcp_state = HDCP_STATE_AUTHENTICATED;
+ hdcp_ctrl->auth_retries = 0;
+ hdmi_hdcp_cache_topology(hdcp_ctrl);
+ hdmi_hdcp_notify_topology(hdcp_ctrl);
+ }
mutex_unlock(hdcp_ctrl->init_data.mutex);
/* Notify HDMI Tx controller of the result */
@@ -989,10 +1048,38 @@
return 0;
} /* hdmi_hdcp_authenticate */
+/*
+ * Only retries defined times then abort current authenticating process
+ * Send check_topology message to notify any hdcpmanager's client of non-
+ * hdcp authenticated data link so the client can tear down any active secure
+ * playback.
+ * Reduce hdcp link to regular hdmi data link with hdcp disabled so any
+ * un-secure like UI & menu still can be sent over HDMI and display.
+ */
+#define AUTH_RETRIES_TIME (30)
+static int hdmi_msm_if_abort_reauth(struct hdmi_hdcp_ctrl *hdcp_ctrl)
+{
+ int ret = 0;
+
+ if (!hdcp_ctrl) {
+ DEV_ERR("%s: invalid input\n", __func__);
+ return -EINVAL;
+ }
+
+ if (++hdcp_ctrl->auth_retries == AUTH_RETRIES_TIME) {
+ hdmi_hdcp_off(hdcp_ctrl);
+ hdcp_ctrl->auth_retries = 0;
+ ret = -ERANGE;
+ }
+
+ return ret;
+}
+
int hdmi_hdcp_reauthenticate(void *input)
{
struct hdmi_hdcp_ctrl *hdcp_ctrl = (struct hdmi_hdcp_ctrl *)input;
struct dss_io_data *io;
+ u32 ret = 0;
if (!hdcp_ctrl || !hdcp_ctrl->init_data.core_io) {
DEV_ERR("%s: invalid input\n", __func__);
@@ -1001,13 +1088,19 @@
io = hdcp_ctrl->init_data.core_io;
-
if (HDCP_STATE_AUTH_FAIL != hdcp_ctrl->hdcp_state) {
DEV_DBG("%s: %s: invalid state. returning\n", __func__,
HDCP_STATE_NAME);
return 0;
}
+ ret = hdmi_msm_if_abort_reauth(hdcp_ctrl);
+
+ if (ret) {
+ DEV_ERR("%s: abort reauthentication!\n", __func__);
+ return ret;
+ }
+
/*
* Disable HPD circuitry.
* This is needed to reset the HDCP cipher engine so that when we
@@ -1042,7 +1135,7 @@
queue_delayed_work(hdcp_ctrl->init_data.workq,
&hdcp_ctrl->hdcp_auth_work, HZ/2);
- return 0;
+ return ret;
} /* hdmi_hdcp_reauthenticate */
void hdmi_hdcp_off(void *input)
@@ -1192,10 +1285,76 @@
return ret;
} /* hdmi_hdcp_sysfs_rda_hdcp*/
+static ssize_t hdmi_hdcp_sysfs_rda_tp(struct device *dev,
+ struct device_attribute *attr, char *buf)
+{
+ ssize_t ret = 0;
+ struct hdmi_hdcp_ctrl *hdcp_ctrl =
+ hdmi_get_featuredata_from_sysfs_dev(dev, HDMI_TX_FEAT_HDCP);
+
+ if (!hdcp_ctrl) {
+ DEV_ERR("%s: invalid input\n", __func__);
+ return -EINVAL;
+ }
+
+ switch (hdcp_ctrl->tp_msgid) {
+ case DOWN_CHECK_TOPOLOGY:
+ case DOWN_REQUEST_TOPOLOGY:
+ buf[MSG_ID_IDX] = hdcp_ctrl->tp_msgid;
+ buf[RET_CODE_IDX] = HDCP_AUTHED;
+ ret = HEADER_LEN;
+
+ memcpy(buf + HEADER_LEN, &hdcp_ctrl->cached_tp,
+ sizeof(struct HDCP_V2V1_MSG_TOPOLOGY));
+
+ ret += sizeof(struct HDCP_V2V1_MSG_TOPOLOGY);
+
+ /* clear the flag once data is read back to user space*/
+ hdcp_ctrl->tp_msgid = -1;
+ break;
+ default:
+ ret = -EINVAL;
+ }
+
+ return ret;
+} /* hdmi_hdcp_sysfs_rda_tp*/
+
+static ssize_t hdmi_hdcp_sysfs_wta_tp(struct device *dev,
+ struct device_attribute *attr, const char *buf, size_t count)
+{
+ int msgid = 0;
+ ssize_t ret = count;
+ struct hdmi_hdcp_ctrl *hdcp_ctrl =
+ hdmi_get_featuredata_from_sysfs_dev(dev, HDMI_TX_FEAT_HDCP);
+
+ if (!hdcp_ctrl || !buf) {
+ DEV_ERR("%s: invalid input\n", __func__);
+ return -EINVAL;
+ }
+
+ msgid = buf[0];
+
+ switch (msgid) {
+ case DOWN_CHECK_TOPOLOGY:
+ case DOWN_REQUEST_TOPOLOGY:
+ hdcp_ctrl->tp_msgid = msgid;
+ break;
+ /* more cases added here */
+ default:
+ ret = -EINVAL;
+ }
+
+ return ret;
+} /* hdmi_tx_sysfs_wta_hpd */
+
static DEVICE_ATTR(status, S_IRUGO, hdmi_hdcp_sysfs_rda_status, NULL);
+static DEVICE_ATTR(tp, S_IRUGO | S_IWUSR, hdmi_hdcp_sysfs_rda_tp,
+ hdmi_hdcp_sysfs_wta_tp);
+
static struct attribute *hdmi_hdcp_fs_attrs[] = {
&dev_attr_status.attr,
+ &dev_attr_tp.attr,
NULL,
};
diff --git a/drivers/video/msm/mdss/mdss_hdmi_tx.c b/drivers/video/msm/mdss/mdss_hdmi_tx.c
index 7117779..0b64bbb 100644
--- a/drivers/video/msm/mdss/mdss_hdmi_tx.c
+++ b/drivers/video/msm/mdss/mdss_hdmi_tx.c
@@ -126,7 +126,13 @@
}
} /* hdmi_pm_name */
-static u8 hdmi_tx_avi_iframe_lut[][20] = {
+static DEFINE_MUTEX(avi_iframe_lut_lock);
+#define NUM_MODES_AVI 20
+#define SET_ITC_BIT(byte) (byte | 0x80)
+#define CLR_ITC_BIT(byte) (byte & 0x7F)
+#define CONFIG_CN_BITS(bits, byte) ((byte & ~(0x03 << 4)) | (bits << 4))
+
+static u8 hdmi_tx_avi_iframe_lut[][NUM_MODES_AVI] = {
{0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10,
0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10,
0x10, 0x10}, /*00*/
@@ -193,6 +199,55 @@
{20480, 247500} } },
};
+/* To statically config ITC bit from sysfs attribute */
+static int hdmi_tx_config_itc_bit(int itc)
+{
+ int ret = 0, loop = NUM_MODES_AVI;
+
+ if (mutex_lock_interruptible(&avi_iframe_lut_lock)) {
+ ret = -ERESTARTSYS;
+ goto signal_intr;
+ }
+
+ do {
+ --loop;
+ if (itc == 0)
+ hdmi_tx_avi_iframe_lut[2][loop] =
+ CLR_ITC_BIT(hdmi_tx_avi_iframe_lut[2][loop]);
+ if (itc == 1)
+ hdmi_tx_avi_iframe_lut[2][loop] =
+ SET_ITC_BIT(hdmi_tx_avi_iframe_lut[2][loop]);
+ } while (loop);
+
+ mutex_unlock(&avi_iframe_lut_lock);
+
+signal_intr:
+ return ret;
+}
+
+/* To configure CN0_1 bits from sysfs attribute */
+static int hdmi_tx_config_cn_bits(int cns)
+{
+ int ret = 0, loop = NUM_MODES_AVI;
+
+ if (mutex_lock_interruptible(&avi_iframe_lut_lock)) {
+ ret = -ERESTARTSYS;
+ goto signal_intr;
+ }
+
+ do {
+ --loop;
+ hdmi_tx_avi_iframe_lut[4][loop] =
+ CONFIG_CN_BITS(cns, hdmi_tx_avi_iframe_lut[4][loop]);
+ } while (loop);
+
+ mutex_unlock(&avi_iframe_lut_lock);
+
+signal_intr:
+ return ret;
+}
+
+
static bool hdmi_tx_is_cea_format(int mode)
{
bool cea_fmt;
@@ -544,6 +599,58 @@
return ret;
} /* hdmi_tx_sysfs_rda_product_description */
+static ssize_t hdmi_tx_sysfs_wta_avi_itc(struct device *dev,
+ struct device_attribute *attr, const char *buf, size_t count)
+{
+ ssize_t ret = strnlen(buf, PAGE_SIZE);
+ int err = 0;
+ int itc = 0, rc = 0;
+
+ rc = kstrtoint(buf, 10, &itc);
+ if (rc) {
+ DEV_ERR("%s: kstrtoint failed. rc=%d\n", __func__, rc);
+ return rc;
+ }
+
+ if (itc == 0 || itc == 1) {
+ if (hdmi_tx_config_itc_bit(itc))
+ ret = err;
+ else
+ DEV_DBG("%s: '%d is configured'!\n", __func__, itc);
+ } else {
+ DEV_ERR("%s: unknown ITC '%d', should be either 0 or 1\n",
+ __func__, itc);
+ }
+
+ return ret;
+} /* hdmi_tx_sysfs_wta_avi_itc */
+
+static ssize_t hdmi_tx_sysfs_wta_avi_cn0_1(struct device *dev,
+ struct device_attribute *attr, const char *buf, size_t count)
+{
+ ssize_t ret = strnlen(buf, PAGE_SIZE);
+ int err = 0;
+ int cns = 0, rc = 0;
+
+ rc = kstrtoint(buf, 10, &cns);
+ if (rc) {
+ DEV_ERR("%s: kstrtoint failed. rc=%d\n", __func__, rc);
+ return rc;
+ }
+
+ if (cns == 0 || cns == 1 || cns == 2 || cns == 3) {
+ if (hdmi_tx_config_cn_bits(cns))
+ ret = err;
+ else
+ DEV_DBG("%s: '%d is configured'!\n", __func__, cns);
+ } else {
+ DEV_ERR("%s: unknown CN '%d' should be either 0 or 1, 2 ,3\n",
+ __func__, cns);
+ }
+
+ return ret;
+} /* hdmi_tx_sysfs_wta_avi_cn0_1 */
+
static DEVICE_ATTR(connected, S_IRUGO, hdmi_tx_sysfs_rda_connected, NULL);
static DEVICE_ATTR(hpd, S_IRUGO | S_IWUSR, hdmi_tx_sysfs_rda_hpd,
hdmi_tx_sysfs_wta_hpd);
@@ -552,12 +659,16 @@
static DEVICE_ATTR(product_description, S_IRUGO | S_IWUSR,
hdmi_tx_sysfs_rda_product_description,
hdmi_tx_sysfs_wta_product_description);
+static DEVICE_ATTR(avi_itc, S_IWUSR, NULL, hdmi_tx_sysfs_wta_avi_itc);
+static DEVICE_ATTR(avi_cn0_1, S_IWUSR, NULL, hdmi_tx_sysfs_wta_avi_cn0_1);
static struct attribute *hdmi_tx_fs_attrs[] = {
&dev_attr_connected.attr,
&dev_attr_hpd.attr,
&dev_attr_vendor_name.attr,
&dev_attr_product_description.attr,
+ &dev_attr_avi_itc.attr,
+ &dev_attr_avi_cn0_1.attr,
NULL,
};
static struct attribute_group hdmi_tx_fs_attrs_group = {
diff --git a/drivers/video/msm/mdss/mdss_mdp.c b/drivers/video/msm/mdss/mdss_mdp.c
index 4a4684b..db8a098 100644
--- a/drivers/video/msm/mdss/mdss_mdp.c
+++ b/drivers/video/msm/mdss/mdss_mdp.c
@@ -1801,6 +1801,7 @@
struct mdss_data_type *mdata = platform_get_drvdata(pdev);
u32 data;
int rc;
+ struct property *prop = NULL;
rc = of_property_read_u32(pdev->dev.of_node, "qcom,mdss-rot-block-size",
&data);
@@ -1812,6 +1813,9 @@
"qcom,mdss-has-decimation");
mdata->has_wfd_blk = of_property_read_bool(pdev->dev.of_node,
"qcom,mdss-has-wfd-blk");
+ prop = of_find_property(pdev->dev.of_node, "batfet-supply", NULL);
+ mdata->batfet_required = prop ? true : false;
+
return 0;
}
@@ -1983,6 +1987,33 @@
return rc;
}
+void mdss_mdp_batfet_ctrl(struct mdss_data_type *mdata, int enable)
+{
+ if (!mdata->batfet_required)
+ return;
+
+ if (!mdata->batfet) {
+ if (enable) {
+ mdata->batfet = devm_regulator_get(&mdata->pdev->dev,
+ "batfet");
+ if (IS_ERR_OR_NULL(mdata->batfet)) {
+ pr_debug("unable to get batfet reg. rc=%d\n",
+ PTR_RET(mdata->batfet));
+ mdata->batfet = NULL;
+ return;
+ }
+ } else {
+ pr_debug("Batfet regulator disable w/o enable\n");
+ return;
+ }
+ }
+
+ if (enable)
+ regulator_enable(mdata->batfet);
+ else
+ regulator_disable(mdata->batfet);
+}
+
static void mdss_mdp_footswitch_ctrl(struct mdss_data_type *mdata, int on)
{
if (!mdata->fs)
@@ -1993,6 +2024,7 @@
if (!mdata->fs_ena) {
regulator_enable(mdata->fs);
mdss_mdp_cx_ctrl(mdata, true);
+ mdss_mdp_batfet_ctrl(mdata, true);
}
mdata->fs_ena = true;
} else {
@@ -2001,6 +2033,7 @@
if (mdata->fs_ena) {
regulator_disable(mdata->fs);
mdss_mdp_cx_ctrl(mdata, false);
+ mdss_mdp_batfet_ctrl(mdata, false);
}
mdata->fs_ena = false;
}
diff --git a/drivers/video/msm/mdss/mdss_mdp.h b/drivers/video/msm/mdss/mdss_mdp.h
index f9db498..7bf14e6 100644
--- a/drivers/video/msm/mdss/mdss_mdp.h
+++ b/drivers/video/msm/mdss/mdss_mdp.h
@@ -395,6 +395,7 @@
u32 splash_mem_addr;
u32 splash_mem_size;
+ u32 sd_enabled;
};
struct mdss_mdp_perf_params {
@@ -450,6 +451,7 @@
void (*fnc_ptr)(void *), void *arg);
void mdss_mdp_footswitch_ctrl_splash(int on);
+void mdss_mdp_batfet_ctrl(struct mdss_data_type *mdata, int enable);
int mdss_mdp_bus_scale_set_quota(u64 ab_quota, u64 ib_quota);
void mdss_mdp_set_clk_rate(unsigned long min_clk_rate);
unsigned long mdss_mdp_get_clk_rate(u32 clk_idx);
@@ -608,4 +610,5 @@
#define mfd_to_wb(mfd) (((struct mdss_overlay_private *)\
(mfd->mdp.private1))->wb)
+int mdss_mdp_ctl_reset(struct mdss_mdp_ctl *ctl);
#endif /* MDSS_MDP_H */
diff --git a/drivers/video/msm/mdss/mdss_mdp_ctl.c b/drivers/video/msm/mdss/mdss_mdp_ctl.c
index ec7bc11..e50598f 100644
--- a/drivers/video/msm/mdss/mdss_mdp_ctl.c
+++ b/drivers/video/msm/mdss/mdss_mdp_ctl.c
@@ -16,6 +16,8 @@
#include <linux/errno.h>
#include <linux/mutex.h>
#include <linux/platform_device.h>
+#include <linux/dma-mapping.h>
+#include <linux/delay.h>
#include "mdss_fb.h"
#include "mdss_mdp.h"
@@ -1259,6 +1261,41 @@
ctl->roi.x, ctl->roi.y, ctl->roi.w, ctl->roi.h);
}
+/*
+ * mdss_mdp_ctl_reset() - reset mdp ctl path.
+ * @ctl: mdp controller.
+ * this function called when underflow happen,
+ * it will reset mdp ctl path and poll for its completion
+ *
+ * Note: called within atomic context.
+ */
+int mdss_mdp_ctl_reset(struct mdss_mdp_ctl *ctl)
+{
+ u32 status = 1;
+ int cnt = 20;
+
+ mdss_mdp_ctl_write(ctl, MDSS_MDP_REG_CTL_SW_RESET, 1);
+
+ /*
+ * it takes around 30us to have mdp finish resetting its ctl path
+ * poll every 50us so that reset should be completed at 1st poll
+ */
+
+ do {
+ udelay(50);
+ status = mdss_mdp_ctl_read(ctl, MDSS_MDP_REG_CTL_SW_RESET);
+ status &= 0x01;
+ pr_debug("status=%x\n", status);
+ cnt--;
+ if (cnt == 0) {
+ pr_err("timeout\n");
+ return -EAGAIN;
+ }
+ } while (status);
+
+ return 0;
+}
+
static int mdss_mdp_mixer_setup(struct mdss_mdp_ctl *ctl,
struct mdss_mdp_mixer *mixer)
{
diff --git a/drivers/video/msm/mdss/mdss_mdp_hwio.h b/drivers/video/msm/mdss/mdss_mdp_hwio.h
index 213368a..940d6c9 100644
--- a/drivers/video/msm/mdss/mdss_mdp_hwio.h
+++ b/drivers/video/msm/mdss/mdss_mdp_hwio.h
@@ -114,6 +114,7 @@
#define MDSS_MDP_REG_CTL_FLUSH 0x018
#define MDSS_MDP_REG_CTL_START 0x01C
#define MDSS_MDP_REG_CTL_PACK_3D 0x020
+#define MDSS_MDP_REG_CTL_SW_RESET 0x030
#define MDSS_MDP_CTL_OP_VIDEO_MODE (0 << 17)
#define MDSS_MDP_CTL_OP_CMD_MODE (1 << 17)
diff --git a/drivers/video/msm/mdss/mdss_mdp_intf_cmd.c b/drivers/video/msm/mdss/mdss_mdp_intf_cmd.c
index addb9b0..e0717ad 100644
--- a/drivers/video/msm/mdss/mdss_mdp_intf_cmd.c
+++ b/drivers/video/msm/mdss/mdss_mdp_intf_cmd.c
@@ -43,13 +43,13 @@
struct mutex clk_mtx;
spinlock_t clk_lock;
struct work_struct clk_work;
-
/* te config */
u8 tear_check;
u16 height; /* panel height */
u16 vporch; /* vertical porches */
u16 start_threshold;
u32 vclk_line; /* vsync clock per line */
+ struct mdss_panel_recovery recovery;
};
struct mdss_mdp_cmd_ctx mdss_mdp_cmd_ctx_list[MAX_SESSIONS];
@@ -264,6 +264,31 @@
spin_unlock(&ctx->clk_lock);
}
+static void mdss_mdp_cmd_underflow_recovery(void *data)
+{
+ struct mdss_mdp_cmd_ctx *ctx = data;
+ unsigned long flags;
+
+ if (!data) {
+ pr_err("%s: invalid ctx\n", __func__);
+ return;
+ }
+
+ if (!ctx->ctl)
+ return;
+ spin_lock_irqsave(&ctx->clk_lock, flags);
+ if (ctx->koff_cnt) {
+ mdss_mdp_ctl_reset(ctx->ctl);
+ pr_debug("%s: intf_num=%d\n", __func__,
+ ctx->ctl->intf_num);
+ ctx->koff_cnt--;
+ mdss_mdp_irq_disable_nosync(MDSS_MDP_IRQ_PING_PONG_COMP,
+ ctx->pp_num);
+ complete_all(&ctx->pp_comp);
+ }
+ spin_unlock_irqrestore(&ctx->clk_lock, flags);
+}
+
static void mdss_mdp_cmd_pingpong_done(void *arg)
{
struct mdss_mdp_ctl *ctl = arg;
@@ -471,7 +496,8 @@
/*
* tx dcs command if had any
*/
- mdss_mdp_ctl_intf_event(ctl, MDSS_EVENT_DSI_CMDLIST_KOFF, NULL);
+ mdss_mdp_ctl_intf_event(ctl, MDSS_EVENT_DSI_CMDLIST_KOFF,
+ (void *)&ctx->recovery);
mdss_mdp_cmd_clk_on(ctx);
@@ -587,6 +613,9 @@
INIT_WORK(&ctx->clk_work, clk_ctrl_work);
INIT_LIST_HEAD(&ctx->vsync_handlers);
+ ctx->recovery.fxn = mdss_mdp_cmd_underflow_recovery;
+ ctx->recovery.data = ctx;
+
pr_debug("%s: ctx=%p num=%d mixer=%d\n", __func__,
ctx, ctx->pp_num, mixer->num);
diff --git a/drivers/video/msm/mdss/mdss_mdp_intf_video.c b/drivers/video/msm/mdss/mdss_mdp_intf_video.c
index 728269d..a040785 100644
--- a/drivers/video/msm/mdss/mdss_mdp_intf_video.c
+++ b/drivers/video/msm/mdss/mdss_mdp_intf_video.c
@@ -330,6 +330,7 @@
mdss_mdp_set_intr_callback(MDSS_MDP_IRQ_INTF_UNDER_RUN, ctl->intf_num,
NULL, NULL);
+ mdss_mdp_ctl_reset(ctl);
ctx->ref_cnt--;
ctl->priv_data = NULL;
diff --git a/drivers/video/msm/mdss/mdss_mdp_overlay.c b/drivers/video/msm/mdss/mdss_mdp_overlay.c
index 52b8b6a..1584925 100644
--- a/drivers/video/msm/mdss/mdss_mdp_overlay.c
+++ b/drivers/video/msm/mdss/mdss_mdp_overlay.c
@@ -27,7 +27,7 @@
#include <mach/iommu_domains.h>
#include <mach/event_timer.h>
#include <mach/msm_bus.h>
-
+#include <mach/scm.h>
#include "mdss.h"
#include "mdss_debug.h"
#include "mdss_fb.h"
@@ -42,12 +42,38 @@
#define PP_CLK_CFG_OFF 0
#define PP_CLK_CFG_ON 1
+#define MEM_PROTECT_SD_CTRL 0xF
+
+struct sd_ctrl_req {
+ unsigned int enable;
+} __attribute__ ((__packed__));
+
static atomic_t ov_active_panels = ATOMIC_INIT(0);
static int mdss_mdp_overlay_free_fb_pipe(struct msm_fb_data_type *mfd);
static int mdss_mdp_overlay_fb_parse_dt(struct msm_fb_data_type *mfd);
static int mdss_mdp_overlay_off(struct msm_fb_data_type *mfd);
static int mdss_mdp_overlay_splash_parse_dt(struct msm_fb_data_type *mfd);
+static int mdss_mdp_overlay_sd_ctrl(struct msm_fb_data_type *mfd,
+ unsigned int enable)
+{
+ struct sd_ctrl_req request;
+ unsigned int resp = -1;
+ int ret = 0;
+ pr_debug("sd_ctrl %u\n", enable);
+
+ request.enable = enable;
+
+ ret = scm_call(SCM_SVC_MP, MEM_PROTECT_SD_CTRL,
+ &request, sizeof(request), &resp, sizeof(resp));
+ pr_debug("scm_call MEM_PROTECT_SD_CTRL(%u): ret=%d, resp=%x",
+ enable, ret, resp);
+ if (ret)
+ return ret;
+
+ return resp;
+}
+
static int mdss_mdp_overlay_get(struct msm_fb_data_type *mfd,
struct mdp_overlay *req)
{
@@ -777,8 +803,11 @@
int rc;
struct mdss_overlay_private *mdp5_data = mfd_to_mdp5_data(mfd);
- if (mdp5_data->ctl->power_on)
+ if (mdp5_data->ctl->power_on) {
+ if (!mdp5_data->mdata->batfet)
+ mdss_mdp_batfet_ctrl(mdp5_data->mdata, true);
return 0;
+ }
pr_debug("starting fb%d overlay\n", mfd->index);
@@ -833,6 +862,7 @@
struct mdss_mdp_ctl *ctl = mfd_to_ctl(mfd);
struct mdss_mdp_ctl *tmp;
int ret;
+ int sd_in_pipe = 0;
if (ctl->shared_lock)
mutex_lock(ctl->shared_lock);
@@ -848,6 +878,24 @@
mutex_unlock(ctl->shared_lock);
return ret;
}
+ /*
+ * check if there is a secure display session
+ */
+ list_for_each_entry(pipe, &mdp5_data->pipes_used, used_list) {
+ if (pipe->flags & MDP_SECURE_DISPLAY_OVERLAY_SESSION) {
+ sd_in_pipe |= 1;
+ pr_debug("Secure pipe: %u : %08X\n",
+ pipe->num, pipe->flags);
+ }
+ }
+ /*
+ * If there is no secure display session and sd_enabled, disable the
+ * secure display session
+ */
+ if (!sd_in_pipe && mdp5_data->sd_enabled) {
+ if (0 == mdss_mdp_overlay_sd_ctrl(mfd, 0))
+ mdp5_data->sd_enabled = 0;
+ }
if (data)
mdss_mdp_set_roi(ctl, data);
@@ -855,6 +903,16 @@
list_for_each_entry(pipe, &mdp5_data->pipes_used, used_list) {
struct mdss_mdp_data *buf;
/*
+ * When secure display is enabled, if there is a non secure
+ * display pipe, skip that
+ */
+ if ((mdp5_data->sd_enabled) &&
+ !(pipe->flags & MDP_SECURE_DISPLAY_OVERLAY_SESSION)) {
+ pr_warn("Non secure pipe during secure display: %u: %08X, skip\n",
+ pipe->num, pipe->flags);
+ continue;
+ }
+ /*
* When external is connected and no dedicated wfd is present,
* reprogram DMA pipe before kickoff to clear out any previous
* block mode configuration.
@@ -920,6 +978,16 @@
ret = mdss_mdp_display_wait4comp(mdp5_data->ctl);
+ if (ret == 0) {
+ mutex_lock(&mfd->lock);
+ if (!mdp5_data->sd_enabled && (sd_in_pipe == 1)) {
+ ret = mdss_mdp_overlay_sd_ctrl(mfd, 1);
+ if (ret == 0)
+ mdp5_data->sd_enabled = 1;
+ }
+ mutex_unlock(&mfd->lock);
+ }
+
mdss_fb_update_notify_update(mfd);
commit_fail:
mdss_mdp_overlay_cleanup(mfd);
@@ -1147,6 +1215,7 @@
pr_debug("ov queue pnum=%d\n", pipe->num);
flags = (pipe->flags & MDP_SECURE_OVERLAY_SESSION);
+ flags |= (pipe->flags & MDP_SECURE_DISPLAY_OVERLAY_SESSION);
src_data = &pipe->back_buf;
if (src_data->num_planes) {
diff --git a/drivers/video/msm/mdss/mdss_panel.h b/drivers/video/msm/mdss/mdss_panel.h
index 25f1e7c..75fc095 100644
--- a/drivers/video/msm/mdss/mdss_panel.h
+++ b/drivers/video/msm/mdss/mdss_panel.h
@@ -85,6 +85,11 @@
bool init_done;
};
+struct mdss_panel_recovery {
+ void (*fxn)(void *ctx);
+ void *data;
+};
+
/**
* enum mdss_intf_events - Different events generated by MDP core
*
@@ -120,8 +125,8 @@
* @MDSS_EVENT_PANEL_CLK_CTRL: panel clock control
- 0 clock disable
- 1 clock enable
- * @MDSS_EVENT_DSI_CMDLIST_KOFF: kickoff sending dcs command from command list
* @MDSS_EVENT_ENABLE_PARTIAL_UPDATE: Event to update ROI of the panel.
+ * @MDSS_EVENT_DSI_CMDLIST_KOFF: acquire dsi_mdp_busy lock before kickoff.
*/
enum mdss_intf_events {
MDSS_EVENT_RESET = 1,
diff --git a/include/linux/mfd/wcd9xxx/core.h b/include/linux/mfd/wcd9xxx/core.h
index c2ad2b4..85be7c3 100644
--- a/include/linux/mfd/wcd9xxx/core.h
+++ b/include/linux/mfd/wcd9xxx/core.h
@@ -64,8 +64,10 @@
WCD9XXX_IRQ_PA2_STARTUP,
WCD9XXX_IRQ_PA3_STARTUP,
WCD9XXX_IRQ_PA4_STARTUP,
+ WCD9306_IRQ_HPH_PA_OCPR_FAULT = WCD9XXX_IRQ_PA4_STARTUP,
WCD9XXX_IRQ_PA5_STARTUP,
WCD9XXX_IRQ_MICBIAS1_PRECHARGE,
+ WCD9306_IRQ_HPH_PA_OCPL_FAULT = WCD9XXX_IRQ_MICBIAS1_PRECHARGE,
WCD9XXX_IRQ_MICBIAS2_PRECHARGE,
WCD9XXX_IRQ_MICBIAS3_PRECHARGE,
/* INTR_REG 2 */
diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h
index 9d15908..d0ad3e4 100644
--- a/include/linux/mmc/card.h
+++ b/include/linux/mmc/card.h
@@ -391,6 +391,7 @@
unsigned int idle_timeout;
struct notifier_block reboot_notify;
bool issue_long_pon;
+ u8 cached_ext_csd;
};
/*
diff --git a/include/linux/msm_mdp.h b/include/linux/msm_mdp.h
index 077b204..0c08421 100644
--- a/include/linux/msm_mdp.h
+++ b/include/linux/msm_mdp.h
@@ -187,6 +187,7 @@
#define MDP_BACKEND_COMPOSITION 0x00040000
#define MDP_BORDERFILL_SUPPORTED 0x00010000
#define MDP_SECURE_OVERLAY_SESSION 0x00008000
+#define MDP_SECURE_DISPLAY_OVERLAY_SESSION 0x00002000
#define MDP_OV_PIPE_FORCE_DMA 0x00004000
#define MDP_MEMORY_ID_TYPE_FB 0x00001000
#define MDP_BWC_EN 0x00000400
diff --git a/include/linux/wcnss_wlan.h b/include/linux/wcnss_wlan.h
index 717bd73..39357e0 100644
--- a/include/linux/wcnss_wlan.h
+++ b/include/linux/wcnss_wlan.h
@@ -79,6 +79,13 @@
int wcnss_xo_auto_detect_enabled(void);
u32 wcnss_get_wlan_rx_buff_count(void);
int wcnss_wlan_iris_xo_mode(void);
+#ifdef CONFIG_WCNSS_REGISTER_DUMP_ON_BITE
+void wcnss_log_debug_regs_on_bite(void);
+#else
+static inline void wcnss_log_debug_regs_on_bite(void)
+{
+}
+#endif
#define wcnss_wlan_get_drvdata(dev) dev_get_drvdata(dev)
#define wcnss_wlan_set_drvdata(dev, data) dev_set_drvdata((dev), (data))
diff --git a/include/scsi/scsi.h b/include/scsi/scsi.h
index cc37cd8..8e3aced 100644
--- a/include/scsi/scsi.h
+++ b/include/scsi/scsi.h
@@ -10,6 +10,7 @@
#include <linux/types.h>
#include <linux/scatterlist.h>
+#include <linux/device.h>
struct scsi_cmnd;
diff --git a/include/video/Kbuild b/include/video/Kbuild
index 53e13cb..fce6fd1 100644
--- a/include/video/Kbuild
+++ b/include/video/Kbuild
@@ -2,3 +2,4 @@
header-y += sisfb.h
header-y += uvesafb.h
header-y += msm_hdmi_modes.h
+header-y += msm_hdmi_hdcp_mgr.h
diff --git a/include/video/msm_hdmi_hdcp_mgr.h b/include/video/msm_hdmi_hdcp_mgr.h
new file mode 100644
index 0000000..7b8e7f5
--- /dev/null
+++ b/include/video/msm_hdmi_hdcp_mgr.h
@@ -0,0 +1,66 @@
+/* Copyright (c) 2013, 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.
+ */
+
+#ifndef MSM_HDMI_HDCP_MGR_H
+#define MSM_HDMI_HDCP_MGR_H
+
+enum DS_TYPE { /* type of downstream device */
+ DS_UNKNOWN,
+ DS_RECEIVER,
+ DS_REPEATER,
+};
+
+enum {
+ MSG_ID_IDX,
+ RET_CODE_IDX,
+ HEADER_LEN,
+};
+
+enum RET_CODE {
+ HDCP_NOT_AUTHED,
+ HDCP_AUTHED,
+ HDCP_DISABLE,
+};
+
+enum MSG_ID { /* List of functions expected to be called after it */
+ DOWN_CHECK_TOPOLOGY,
+ UP_REQUEST_TOPOLOGY,
+ UP_SEND_TOPOLOGY,
+ DOWN_REQUEST_TOPOLOGY,
+ MSG_NUM,
+};
+
+enum SOURCE_ID {
+ HDCP_V1_TX,
+ HDCP_V1_RX,
+ HDCP_V2_RX,
+ HDCP_V2_TX,
+ SRC_NUM,
+};
+
+/*
+ * how to parse sysfs params buffer
+ * from hdcp_tx driver.
+ */
+
+struct HDCP_V2V1_MSG_TOPOLOGY {
+ /* indicates downstream's type */
+ uint32_t ds_type;
+ uint8_t bksv[5];
+ uint8_t dev_count;
+ uint8_t depth;
+ uint8_t ksv_list[5 * 127];
+ uint32_t max_cascade_exceeded;
+ uint32_t max_dev_exceeded;
+};
+
+#endif /* MSM_HDMI_HDCP_MGR_H */
diff --git a/sound/core/pcm_lib.c b/sound/core/pcm_lib.c
index 06d617b..db94741 100644
--- a/sound/core/pcm_lib.c
+++ b/sound/core/pcm_lib.c
@@ -1672,6 +1672,11 @@
switch (runtime->access) {
case SNDRV_PCM_ACCESS_MMAP_INTERLEAVED:
case SNDRV_PCM_ACCESS_RW_INTERLEAVED:
+ if ((UINT_MAX/width) < info->channel) {
+ snd_printd("%s: integer overflow while multiply\n",
+ __func__);
+ return -EINVAL;
+ }
info->first = info->channel * width;
info->step = runtime->channels * width;
break;
@@ -1679,6 +1684,12 @@
case SNDRV_PCM_ACCESS_RW_NONINTERLEAVED:
{
size_t size = runtime->dma_bytes / runtime->channels;
+
+ if ((size > 0) && ((UINT_MAX/(size * 8)) < info->channel)) {
+ snd_printd("%s: integer overflow while multiply\n",
+ __func__);
+ return -EINVAL;
+ }
info->first = info->channel * size * 8;
info->step = width;
break;
diff --git a/sound/core/pcm_native.c b/sound/core/pcm_native.c
index 8bba8d7..7504576 100644
--- a/sound/core/pcm_native.c
+++ b/sound/core/pcm_native.c
@@ -448,7 +448,8 @@
runtime->silence_threshold = 0;
runtime->silence_size = 0;
runtime->boundary = runtime->buffer_size;
- while (runtime->boundary * 2 <= LONG_MAX - runtime->buffer_size)
+ while (runtime->boundary * 2 * runtime->channels <=
+ LONG_MAX - runtime->buffer_size)
runtime->boundary *= 2;
snd_pcm_timer_resolution_change(substream);
diff --git a/sound/soc/codecs/msm8x10-wcd.c b/sound/soc/codecs/msm8x10-wcd.c
index 4c20bb9..942d095 100644
--- a/sound/soc/codecs/msm8x10-wcd.c
+++ b/sound/soc/codecs/msm8x10-wcd.c
@@ -2612,12 +2612,6 @@
0xE0, 0xE0);
}
-static int msm8x10_wcd_get_jack_detect_irq(
- struct snd_soc_codec *codec)
-{
- return MSM8X10_WCD_IRQ_MBHC_HS_DET;
-}
-
static struct wcd9xxx_cfilt_mode msm8x10_wcd_switch_cfilt_mode(
struct wcd9xxx_mbhc *mbhc, bool fast)
{
@@ -2642,14 +2636,6 @@
mbhc->mbhc_bias_regs.ctl_reg, 0x60, 0x00);
}
-static void msm8x10_wcd_free_irq(struct wcd9xxx_mbhc *mbhc)
-{
- struct msm8x10_wcd *msm8x10_wcd = mbhc->codec->control_data;
- struct wcd9xxx_core_resource *core_res =
- &msm8x10_wcd->wcd9xxx_res;
- wcd9xxx_free_irq(core_res, MSM8X10_WCD_IRQ_MBHC_HS_DET, mbhc);
-}
-
enum wcd9xxx_cdc_type msm8x10_wcd_get_cdc_type(void)
{
return WCD9XXX_CDC_TYPE_HELICON;
@@ -2707,10 +2693,8 @@
.enable_mux_bias_block = msm8x10_wcd_enable_mux_bias_block,
.cfilt_fast_mode = msm8x10_wcd_put_cfilt_fast_mode,
.codec_specific_cal = msm8x10_wcd_codec_specific_cal_setup,
- .jack_detect_irq = msm8x10_wcd_get_jack_detect_irq,
.switch_cfilt_mode = msm8x10_wcd_switch_cfilt_mode,
.select_cfilt = msm8x10_wcd_select_cfilt,
- .free_irq = msm8x10_wcd_free_irq,
.get_cdc_type = msm8x10_wcd_get_cdc_type,
.enable_clock_gate = msm8x10_wcd_mbhc_clk_gate,
.enable_mbhc_txfe = msm8x10_wcd_mbhc_txfe,
@@ -2819,6 +2803,17 @@
.priority = -INT_MAX,
};
+static const struct wcd9xxx_mbhc_intr cdc_intr_ids = {
+ .poll_plug_rem = MSM8X10_WCD_IRQ_MBHC_REMOVAL,
+ .shortavg_complete = MSM8X10_WCD_IRQ_MBHC_SHORT_TERM,
+ .potential_button_press = MSM8X10_WCD_IRQ_MBHC_PRESS,
+ .button_release = MSM8X10_WCD_IRQ_MBHC_RELEASE,
+ .dce_est_complete = MSM8X10_WCD_IRQ_MBHC_POTENTIAL,
+ .insertion = MSM8X10_WCD_IRQ_MBHC_INSERTION,
+ .hph_left_ocp = MSM8X10_WCD_IRQ_HPH_PA_OCPL_FAULT,
+ .hph_right_ocp = MSM8X10_WCD_IRQ_HPH_PA_OCPR_FAULT,
+ .hs_jack_switch = MSM8X10_WCD_IRQ_MBHC_HS_DET,
+};
static int msm8x10_wcd_codec_probe(struct snd_soc_codec *codec)
{
@@ -2896,7 +2891,7 @@
ret = wcd9xxx_mbhc_init(&msm8x10_wcd_priv->mbhc,
&msm8x10_wcd_priv->resmgr,
- codec, NULL, &mbhc_cb,
+ codec, NULL, &mbhc_cb, &cdc_intr_ids,
HELICON_MCLK_CLK_9P6MHZ, false);
if (ret) {
pr_err("%s: Failed to initialize mbhc\n", __func__);
diff --git a/sound/soc/codecs/wcd9306.c b/sound/soc/codecs/wcd9306.c
index 17ed0d3..4857593 100644
--- a/sound/soc/codecs/wcd9306.c
+++ b/sound/soc/codecs/wcd9306.c
@@ -97,8 +97,6 @@
#define TAPAN_SLIM_IRQ_UNDERFLOW (1 << 1)
#define TAPAN_SLIM_IRQ_PORT_CLOSED (1 << 2)
-#define TAPAN_IRQ_MBHC_JACK_SWITCH 21
-
enum tapan_codec_type {
WCD9306,
WCD9302,
@@ -5086,11 +5084,6 @@
snd_soc_update_bits(codec, WCD9XXX_A_TX_7_MBHC_EN, 0xE0, 0xE0);
}
-static int tapan_get_jack_detect_irq(struct snd_soc_codec *codec)
-{
- return TAPAN_IRQ_MBHC_JACK_SWITCH;
-}
-
static struct wcd9xxx_cfilt_mode tapan_codec_switch_cfilt_mode(
struct wcd9xxx_mbhc *mbhc,
bool fast)
@@ -5116,14 +5109,6 @@
snd_soc_update_bits(codec, mbhc->mbhc_bias_regs.ctl_reg, 0x60, 0x00);
}
-static void tapan_free_irq(struct wcd9xxx_mbhc *mbhc)
-{
- struct wcd9xxx *wcd9xxx = mbhc->codec->control_data;
- struct wcd9xxx_core_resource *core_res =
- &wcd9xxx->core_res;
- wcd9xxx_free_irq(core_res, WCD9306_IRQ_MBHC_JACK_SWITCH, mbhc);
-}
-
enum wcd9xxx_cdc_type tapan_get_cdc_type(void)
{
return WCD9XXX_CDC_TYPE_TAPAN;
@@ -5382,10 +5367,8 @@
.enable_mux_bias_block = tapan_enable_mux_bias_block,
.cfilt_fast_mode = tapan_put_cfilt_fast_mode,
.codec_specific_cal = tapan_codec_specific_cal_setup,
- .jack_detect_irq = tapan_get_jack_detect_irq,
.switch_cfilt_mode = tapan_codec_switch_cfilt_mode,
.select_cfilt = tapan_select_cfilt,
- .free_irq = tapan_free_irq,
.get_cdc_type = tapan_get_cdc_type,
.setup_zdet = tapan_setup_zdet,
.compute_impedance = tapan_compute_impedance,
@@ -5426,6 +5409,18 @@
return 0;
}
+static const struct wcd9xxx_mbhc_intr cdc_intr_ids = {
+ .poll_plug_rem = WCD9XXX_IRQ_MBHC_REMOVAL,
+ .shortavg_complete = WCD9XXX_IRQ_MBHC_SHORT_TERM,
+ .potential_button_press = WCD9XXX_IRQ_MBHC_PRESS,
+ .button_release = WCD9XXX_IRQ_MBHC_RELEASE,
+ .dce_est_complete = WCD9XXX_IRQ_MBHC_POTENTIAL,
+ .insertion = WCD9XXX_IRQ_MBHC_INSERTION,
+ .hph_left_ocp = WCD9306_IRQ_HPH_PA_OCPL_FAULT,
+ .hph_right_ocp = WCD9306_IRQ_HPH_PA_OCPR_FAULT,
+ .hs_jack_switch = WCD9306_IRQ_MBHC_JACK_SWITCH,
+};
+
static int tapan_post_reset_cb(struct wcd9xxx *wcd9xxx)
{
int ret = 0;
@@ -5473,7 +5468,7 @@
rco_clk_rate = TAPAN_MCLK_CLK_9P6MHZ;
ret = wcd9xxx_mbhc_init(&tapan->mbhc, &tapan->resmgr, codec, NULL,
- &mbhc_cb, rco_clk_rate,
+ &mbhc_cb, &cdc_intr_ids, rco_clk_rate,
TAPAN_CDC_ZDET_SUPPORTED);
if (ret)
pr_err("%s: mbhc init failed %d\n", __func__, ret);
@@ -5679,7 +5674,7 @@
rco_clk_rate = TAPAN_MCLK_CLK_9P6MHZ;
ret = wcd9xxx_mbhc_init(&tapan->mbhc, &tapan->resmgr, codec, NULL,
- &mbhc_cb, rco_clk_rate,
+ &mbhc_cb, &cdc_intr_ids, rco_clk_rate,
TAPAN_CDC_ZDET_SUPPORTED);
if (ret) {
diff --git a/sound/soc/codecs/wcd9320.c b/sound/soc/codecs/wcd9320.c
index 2beda38..5656887 100644
--- a/sound/soc/codecs/wcd9320.c
+++ b/sound/soc/codecs/wcd9320.c
@@ -1127,6 +1127,125 @@
static const struct snd_kcontrol_new class_h_dsm_mux =
SOC_DAPM_ENUM("CLASS_H_DSM MUX Mux", class_h_dsm_enum);
+static const char *const taiko_conn_mad_text[] = {
+ "ADC_MB", "ADC1", "ADC2", "ADC3", "ADC4", "ADC5", "ADC6", "NOTUSED1",
+ "DMIC1", "DMIC2", "DMIC3", "DMIC4", "DMIC5", "DMIC6", "NOTUSED2",
+ "NOTUSED3"};
+
+static const struct soc_enum taiko_conn_mad_enum =
+ SOC_ENUM_SINGLE_EXT(ARRAY_SIZE(taiko_conn_mad_text),
+ taiko_conn_mad_text);
+
+
+static int taiko_mad_input_get(struct snd_kcontrol *kcontrol,
+ struct snd_ctl_elem_value *ucontrol)
+{
+ u8 taiko_mad_input;
+ struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol);
+
+ taiko_mad_input = snd_soc_read(codec, TAIKO_A_CDC_CONN_MAD);
+
+ taiko_mad_input = taiko_mad_input & 0x0F;
+
+ ucontrol->value.integer.value[0] = taiko_mad_input;
+
+ pr_debug("%s: taiko_mad_input = %s\n", __func__,
+ taiko_conn_mad_text[taiko_mad_input]);
+
+ return 0;
+}
+
+static int taiko_mad_input_put(struct snd_kcontrol *kcontrol,
+ struct snd_ctl_elem_value *ucontrol)
+{
+ u8 taiko_mad_input;
+ struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol);
+ struct snd_soc_card *card = codec->card;
+ char mad_amic_input_widget[6];
+ u32 adc;
+ const char *mad_input_widget;
+ u32 mic_bias_found = 0;
+ u32 i;
+ int ret = 0;
+
+ taiko_mad_input = ucontrol->value.integer.value[0];
+
+ pr_debug("%s: taiko_mad_input = %s\n", __func__,
+ taiko_conn_mad_text[taiko_mad_input]);
+
+ if (!strcmp(taiko_conn_mad_text[taiko_mad_input], "NOTUSED1") ||
+ !strcmp(taiko_conn_mad_text[taiko_mad_input], "NOTUSED2") ||
+ !strcmp(taiko_conn_mad_text[taiko_mad_input], "NOTUSED3") ||
+ !strcmp(taiko_conn_mad_text[taiko_mad_input], "ADC_MB")) {
+ pr_info("%s: taiko mad input is set to unsupported input = %s\n",
+ __func__, taiko_conn_mad_text[taiko_mad_input]);
+ return -EINVAL;
+ }
+
+ if (strnstr(taiko_conn_mad_text[taiko_mad_input],
+ "ADC", sizeof("ADC"))) {
+ ret = kstrtouint(strpbrk(taiko_conn_mad_text[taiko_mad_input]
+ , "123456"), 10, &adc);
+ if ((ret < 0) || (adc > 6)) {
+ pr_err("%s: Invalid ADC = %s\n", __func__,
+ taiko_conn_mad_text[taiko_mad_input]);
+ ret = -EINVAL;
+ }
+
+ snprintf(mad_amic_input_widget, 6, "%s%u", "AMIC", adc);
+
+ mad_input_widget = mad_amic_input_widget;
+ pr_debug("%s: taiko amic input widget = %s\n", __func__,
+ mad_amic_input_widget);
+ } else {
+ /* DMIC type input widget*/
+ mad_input_widget = taiko_conn_mad_text[taiko_mad_input];
+ }
+
+ pr_debug("%s: taiko input widget = %s\n", __func__, mad_input_widget);
+
+ for (i = 0; i < card->num_dapm_routes; i++) {
+
+ if (!strncmp(card->dapm_routes[i].sink,
+ mad_input_widget, strlen(mad_input_widget))) {
+
+ if (strnstr(card->dapm_routes[i].source,
+ "MIC BIAS1", sizeof("MIC BIAS1"))) {
+ mic_bias_found = 1;
+ break;
+ } else if (strnstr(card->dapm_routes[i].source,
+ "MIC BIAS2", sizeof("MIC BIAS2"))) {
+ mic_bias_found = 2;
+ break;
+ } else if (strnstr(card->dapm_routes[i].source,
+ "MIC BIAS3", sizeof("MIC BIAS3"))) {
+ mic_bias_found = 3;
+ break;
+ } else if (strnstr(card->dapm_routes[i].source,
+ "MIC BIAS4", sizeof("MIC BIAS4"))) {
+ mic_bias_found = 4;
+ break;
+ }
+ }
+ }
+
+ if (mic_bias_found) {
+ pr_debug("%s: source mic bias = %s. sink = %s\n", __func__,
+ card->dapm_routes[i].source,
+ card->dapm_routes[i].sink);
+
+ snd_soc_update_bits(codec, TAIKO_A_CDC_CONN_MAD,
+ 0x0F, taiko_mad_input);
+ snd_soc_update_bits(codec, TAIKO_A_MAD_ANA_CTRL,
+ 0x07, mic_bias_found);
+ return 0;
+ } else {
+ pr_err("%s: mic bias source not found for input = %s\n",
+ __func__, mad_input_widget);
+ return -EINVAL;
+ }
+}
+
static const struct snd_kcontrol_new taiko_snd_controls[] = {
@@ -1275,6 +1394,9 @@
SOC_SINGLE_EXT("COMP2 Switch", SND_SOC_NOPM, COMPANDER_2, 1, 0,
taiko_get_compander, taiko_set_compander),
+ SOC_ENUM_EXT("MAD Input", taiko_conn_mad_enum,
+ taiko_mad_input_get, taiko_mad_input_put),
+
};
static int taiko_pa_gain_get(struct snd_kcontrol *kcontrol,
@@ -2498,8 +2620,6 @@
return -EINVAL;
}
- snd_soc_update_bits(codec, TAIKO_A_CDC_CONN_MAD,
- 0x0F, mad_cal->microphone_info.input_microphone);
snd_soc_write(codec, TAIKO_A_CDC_MAD_MAIN_CTL_2,
mad_cal->microphone_info.cycle_time);
snd_soc_update_bits(codec, TAIKO_A_CDC_MAD_MAIN_CTL_1, 0xFF << 3,
@@ -6065,6 +6185,9 @@
/* Program the 0.85 volt VBG_REFERENCE */
{TAIKO_A_BIAS_CURR_CTL_2, 0xFF, 0x04},
+
+ /* set MAD input MIC to DMIC1 */
+ {TAIKO_A_CDC_CONN_MAD, 0x0F, 0x08},
};
static void taiko_codec_init_reg(struct snd_soc_codec *codec)
@@ -6368,6 +6491,18 @@
.compute_impedance = taiko_compute_impedance,
};
+static const struct wcd9xxx_mbhc_intr cdc_intr_ids = {
+ .poll_plug_rem = WCD9XXX_IRQ_MBHC_REMOVAL,
+ .shortavg_complete = WCD9XXX_IRQ_MBHC_SHORT_TERM,
+ .potential_button_press = WCD9XXX_IRQ_MBHC_PRESS,
+ .button_release = WCD9XXX_IRQ_MBHC_RELEASE,
+ .dce_est_complete = WCD9XXX_IRQ_MBHC_POTENTIAL,
+ .insertion = WCD9XXX_IRQ_MBHC_INSERTION,
+ .hph_left_ocp = WCD9XXX_IRQ_HPH_PA_OCPL_FAULT,
+ .hph_right_ocp = WCD9XXX_IRQ_HPH_PA_OCPR_FAULT,
+ .hs_jack_switch = WCD9320_IRQ_MBHC_JACK_SWITCH,
+};
+
static int taiko_post_reset_cb(struct wcd9xxx *wcd9xxx)
{
int ret = 0;
@@ -6413,7 +6548,8 @@
ret = wcd9xxx_mbhc_init(&taiko->mbhc, &taiko->resmgr, codec,
taiko_enable_mbhc_micbias,
- &mbhc_cb, rco_clk_rate, true);
+ &mbhc_cb, &cdc_intr_ids,
+ rco_clk_rate, true);
if (ret)
pr_err("%s: mbhc init failed %d\n", __func__, ret);
else
@@ -6602,7 +6738,8 @@
/* init and start mbhc */
ret = wcd9xxx_mbhc_init(&taiko->mbhc, &taiko->resmgr, codec,
taiko_enable_mbhc_micbias,
- &mbhc_cb, rco_clk_rate, true);
+ &mbhc_cb, &cdc_intr_ids,
+ rco_clk_rate, true);
if (ret) {
pr_err("%s: mbhc init failed %d\n", __func__, ret);
goto err_init;
diff --git a/sound/soc/codecs/wcd9xxx-mbhc.c b/sound/soc/codecs/wcd9xxx-mbhc.c
index eea4316..2ecebcd 100644
--- a/sound/soc/codecs/wcd9xxx-mbhc.c
+++ b/sound/soc/codecs/wcd9xxx-mbhc.c
@@ -118,8 +118,6 @@
/* RX_HPH_CNP_WG_TIME increases by 0.24ms */
#define WCD9XXX_WG_TIME_FACTOR_US 240
-#define WCD9XXX_IRQ_MBHC_JACK_SWITCH_DEFAULT 28
-
#define WCD9XXX_V_CS_HS_MAX 500
#define WCD9XXX_V_CS_NO_MIC 5
#define WCD9XXX_MB_MEAS_DELTA_MAX_MV 80
@@ -570,7 +568,7 @@
* reset retry counter as PA is turned off signifying
* start of new OCP detection session
*/
- if (WCD9XXX_IRQ_HPH_PA_OCPL_FAULT)
+ if (mbhc->intr_ids->hph_left_ocp)
mbhc->hphlocp_cnt = 0;
else
mbhc->hphrocp_cnt = 0;
@@ -581,13 +579,13 @@
static void hphrocp_off_report(struct wcd9xxx_mbhc *mbhc, u32 jack_status)
{
__hphocp_off_report(mbhc, SND_JACK_OC_HPHR,
- WCD9XXX_IRQ_HPH_PA_OCPR_FAULT);
+ mbhc->intr_ids->hph_right_ocp);
}
static void hphlocp_off_report(struct wcd9xxx_mbhc *mbhc, u32 jack_status)
{
__hphocp_off_report(mbhc, SND_JACK_OC_HPHL,
- WCD9XXX_IRQ_HPH_PA_OCPL_FAULT);
+ mbhc->intr_ids->hph_left_ocp);
}
static void wcd9xxx_get_mbhc_micbias_regs(struct wcd9xxx_mbhc *mbhc,
@@ -972,7 +970,8 @@
short bias_value;
struct snd_soc_codec *codec = mbhc->codec;
- wcd9xxx_disable_irq(mbhc->resmgr->core_res, WCD9XXX_IRQ_MBHC_POTENTIAL);
+ wcd9xxx_disable_irq(mbhc->resmgr->core_res,
+ mbhc->intr_ids->dce_est_complete);
if (noreldetection)
wcd9xxx_turn_onoff_rel_detection(codec, false);
@@ -1018,7 +1017,8 @@
if (noreldetection)
wcd9xxx_turn_onoff_rel_detection(codec, true);
- wcd9xxx_enable_irq(mbhc->resmgr->core_res, WCD9XXX_IRQ_MBHC_POTENTIAL);
+ wcd9xxx_enable_irq(mbhc->resmgr->core_res,
+ mbhc->intr_ids->dce_est_complete);
return bias_value;
}
@@ -1056,6 +1056,27 @@
mbhc->mbhc_data.micb_mv);
}
+/* To enable/disable bandgap and RC oscillator */
+static void wcd9xxx_mbhc_ctrl_clk_bandgap(struct wcd9xxx_mbhc *mbhc,
+ bool enable)
+{
+ if (enable) {
+ WCD9XXX_BG_CLK_LOCK(mbhc->resmgr);
+ wcd9xxx_resmgr_get_bandgap(mbhc->resmgr,
+ WCD9XXX_BANDGAP_AUDIO_MODE);
+ wcd9xxx_resmgr_get_clk_block(mbhc->resmgr,
+ WCD9XXX_CLK_RCO);
+ WCD9XXX_BG_CLK_UNLOCK(mbhc->resmgr);
+ } else {
+ WCD9XXX_BG_CLK_LOCK(mbhc->resmgr);
+ wcd9xxx_resmgr_put_clk_block(mbhc->resmgr,
+ WCD9XXX_CLK_RCO);
+ wcd9xxx_resmgr_put_bandgap(mbhc->resmgr,
+ WCD9XXX_BANDGAP_AUDIO_MODE);
+ WCD9XXX_BG_CLK_UNLOCK(mbhc->resmgr);
+ }
+}
+
/* called only from interrupt which is under codec_resource_lock acquisition */
static short wcd9xxx_mbhc_setup_hs_polling(struct wcd9xxx_mbhc *mbhc,
bool is_cs_enable)
@@ -1093,15 +1114,6 @@
__func__);
}
- /*
- * Request BG and clock.
- * These will be released by wcd9xxx_cleanup_hs_polling
- */
- WCD9XXX_BG_CLK_LOCK(mbhc->resmgr);
- wcd9xxx_resmgr_get_bandgap(mbhc->resmgr, WCD9XXX_BANDGAP_AUDIO_MODE);
- wcd9xxx_resmgr_get_clk_block(mbhc->resmgr, WCD9XXX_CLK_RCO);
- WCD9XXX_BG_CLK_UNLOCK(mbhc->resmgr);
-
snd_soc_update_bits(codec, WCD9XXX_A_CLK_BUFF_EN1, 0x05, 0x01);
/* Make sure CFILT is in fast mode, save current mode */
@@ -1212,11 +1224,6 @@
wcd9xxx_shutdown_hs_removal_detect(mbhc);
- /* Release clock and BG requested by wcd9xxx_mbhc_setup_hs_polling */
- WCD9XXX_BG_CLK_LOCK(mbhc->resmgr);
- wcd9xxx_resmgr_put_clk_block(mbhc->resmgr, WCD9XXX_CLK_RCO);
- wcd9xxx_resmgr_put_bandgap(mbhc->resmgr, WCD9XXX_BANDGAP_MBHC_MODE);
- WCD9XXX_BG_CLK_UNLOCK(mbhc->resmgr);
/* Disable external voltage source to micbias if present */
if (mbhc->mbhc_cb && mbhc->mbhc_cb->enable_mb_source)
@@ -1691,6 +1698,7 @@
BUG_ON(NUM_DCE_PLUG_INS_DETECT < 4);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, true);
rt[0].swap_gnd = false;
rt[0].vddio = false;
rt[0].hwvalue = true;
@@ -1719,6 +1727,7 @@
type = wcd9xxx_cs_find_plug_type(mbhc, rt, ARRAY_SIZE(rt), highhph,
mbhc->event_state);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, false);
pr_debug("%s: plug_type:%d\n", __func__, type);
return type;
@@ -1759,6 +1768,8 @@
*/
(void) wcd9xxx_pull_down_micbias(mbhc,
WCD9XXX_MICBIAS_PULLDOWN_SETTLE_US);
+
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, true);
rt[0].hphl_status = wcd9xxx_hphl_status(mbhc);
rt[0].dce = wcd9xxx_mbhc_setup_hs_polling(mbhc, false);
rt[0].swap_gnd = false;
@@ -1798,6 +1809,7 @@
type = wcd9xxx_find_plug_type(mbhc, rt, ARRAY_SIZE(rt),
mbhc->event_state);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, false);
pr_debug("%s: leave\n", __func__);
return type;
}
@@ -1945,7 +1957,7 @@
snd_soc_update_bits(codec, mbhc->resmgr->reg_addr->micb_4_mbhc,
0x3, mbhc->mbhc_cfg->micbias);
- wcd9xxx_enable_irq(mbhc->resmgr->core_res, WCD9XXX_IRQ_MBHC_INSERTION);
+ wcd9xxx_enable_irq(mbhc->resmgr->core_res, mbhc->intr_ids->insertion);
snd_soc_update_bits(codec, WCD9XXX_A_CDC_MBHC_INT_CTL, 0x1, 0x1);
pr_debug("%s: leave\n", __func__);
@@ -1986,6 +1998,8 @@
* only report the mic line
*/
wcd9xxx_report_plug(mbhc, 1, SND_JACK_HEADSET);
+ /* Button detection required RC oscillator */
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, true);
msleep(100);
/* if PA is already on, switch micbias source to VDDIO */
@@ -2320,6 +2334,9 @@
* extension cable is still plugged in
* report it as LINEOUT device
*/
+ if (mbhc->hph_status == SND_JACK_HEADSET)
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc,
+ false);
wcd9xxx_report_plug(mbhc, 1, SND_JACK_LINEOUT);
wcd9xxx_cleanup_hs_polling(mbhc);
wcd9xxx_enable_hs_detect(mbhc, 1,
@@ -2338,6 +2355,7 @@
wcd9xxx_switch_micbias(mbhc, 0);
wcd9xxx_report_plug(mbhc, 0, SND_JACK_HEADSET);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, false);
wcd9xxx_cleanup_hs_polling(mbhc);
wcd9xxx_enable_hs_detect(mbhc, 1, MBHC_USE_MB_TRIGGER |
MBHC_USE_HPHL_TRIGGER,
@@ -2414,7 +2432,7 @@
pr_debug("%s: enter\n", __func__);
WCD9XXX_BCL_LOCK(mbhc->resmgr);
- wcd9xxx_disable_irq(mbhc->resmgr->core_res, WCD9XXX_IRQ_MBHC_INSERTION);
+ wcd9xxx_disable_irq(mbhc->resmgr->core_res, mbhc->intr_ids->insertion);
is_mb_trigger = !!(snd_soc_read(codec, mbhc->mbhc_bias_regs.mbhc_reg) &
0x10);
@@ -2481,7 +2499,7 @@
snd_soc_update_bits(codec, mbhc->mbhc_bias_regs.mbhc_reg, 0x90, 0x00);
snd_soc_update_bits(codec, WCD9XXX_A_MBHC_HPH, 0x13, 0x00);
snd_soc_update_bits(codec, mbhc->mbhc_bias_regs.ctl_reg, 0x01, 0x00);
- wcd9xxx_disable_irq_sync(core_res, WCD9XXX_IRQ_MBHC_INSERTION);
+ wcd9xxx_disable_irq_sync(core_res, mbhc->intr_ids->insertion);
wcd9xxx_mbhc_detect_plug_type(mbhc);
wcd9xxx_unlock_sleep(core_res);
}
@@ -2876,6 +2894,7 @@
is_removed = true;
} else if (mbhc->current_plug == PLUG_TYPE_HEADSET) {
wcd9xxx_pause_hs_polling(mbhc);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, false);
wcd9xxx_cleanup_hs_polling(mbhc);
wcd9xxx_report_plug(mbhc, 0, SND_JACK_HEADSET);
is_removed = true;
@@ -3373,7 +3392,7 @@
0x10, 0x10);
} else {
wcd9xxx_disable_irq(mbhc->resmgr->core_res,
- WCD9XXX_IRQ_HPH_PA_OCPL_FAULT);
+ mbhc->intr_ids->hph_left_ocp);
mbhc->hph_status |= SND_JACK_OC_HPHL;
wcd9xxx_jack_report(mbhc, &mbhc->headset_jack,
mbhc->hph_status,
@@ -3403,7 +3422,7 @@
0x10);
} else {
wcd9xxx_disable_irq(mbhc->resmgr->core_res,
- WCD9XXX_IRQ_HPH_PA_OCPR_FAULT);
+ mbhc->intr_ids->hph_right_ocp);
mbhc->hph_status |= SND_JACK_OC_HPHR;
wcd9xxx_jack_report(mbhc, &mbhc->headset_jack,
mbhc->hph_status, WCD9XXX_JACK_MASK);
@@ -3483,7 +3502,8 @@
struct snd_soc_codec *codec = mbhc->codec;
pr_debug("%s: enter\n", __func__);
- wcd9xxx_disable_irq(mbhc->resmgr->core_res, WCD9XXX_IRQ_MBHC_POTENTIAL);
+ wcd9xxx_disable_irq(mbhc->resmgr->core_res,
+ mbhc->intr_ids->dce_est_complete);
wcd9xxx_turn_onoff_rel_detection(codec, false);
/* t_dce and t_sta are updated by wcd9xxx_update_mbhc_clk_rate() */
@@ -3623,7 +3643,8 @@
if (mbhc->mbhc_cb && mbhc->mbhc_cb->enable_mb_source)
mbhc->mbhc_cb->enable_mb_source(codec, false);
- wcd9xxx_enable_irq(mbhc->resmgr->core_res, WCD9XXX_IRQ_MBHC_POTENTIAL);
+ wcd9xxx_enable_irq(mbhc->resmgr->core_res,
+ mbhc->intr_ids->dce_est_complete);
wcd9xxx_turn_onoff_rel_detection(codec, true);
pr_debug("%s: leave\n", __func__);
@@ -3689,14 +3710,7 @@
static int wcd9xxx_setup_jack_detect_irq(struct wcd9xxx_mbhc *mbhc)
{
int ret = 0;
- struct snd_soc_codec *codec = mbhc->codec;
void *core_res = mbhc->resmgr->core_res;
- int jack_irq;
-
- if (mbhc->mbhc_cb && mbhc->mbhc_cb->jack_detect_irq)
- jack_irq = mbhc->mbhc_cb->jack_detect_irq(codec);
- else
- jack_irq = WCD9XXX_IRQ_MBHC_JACK_SWITCH_DEFAULT;
if (mbhc->mbhc_cfg->gpio) {
ret = request_threaded_irq(mbhc->mbhc_cfg->gpio_irq, NULL,
@@ -3719,13 +3733,14 @@
snd_soc_update_bits(mbhc->codec, WCD9XXX_A_RX_HPH_OCP_CTL,
1 << 1, 1 << 1);
- ret = wcd9xxx_request_irq(core_res, jack_irq,
+ ret = wcd9xxx_request_irq(core_res,
+ mbhc->intr_ids->hs_jack_switch,
wcd9xxx_mech_plug_detect_irq,
"Jack Detect",
mbhc);
if (ret)
pr_err("%s: Failed to request insert detect irq %d\n",
- __func__, jack_irq);
+ __func__, mbhc->intr_ids->hs_jack_switch);
}
return ret;
@@ -3755,9 +3770,9 @@
snd_soc_update_bits(codec, WCD9XXX_A_RX_HPH_OCP_CTL, 0x10,
0x10);
wcd9xxx_enable_irq(mbhc->resmgr->core_res,
- WCD9XXX_IRQ_HPH_PA_OCPL_FAULT);
+ mbhc->intr_ids->hph_left_ocp);
wcd9xxx_enable_irq(mbhc->resmgr->core_res,
- WCD9XXX_IRQ_HPH_PA_OCPR_FAULT);
+ mbhc->intr_ids->hph_right_ocp);
/* Initialize mechanical mbhc */
ret = wcd9xxx_setup_jack_detect_irq(mbhc);
@@ -4348,16 +4363,13 @@
*/
mutex_lock(&codec->mutex);
- WCD9XXX_BG_CLK_LOCK(mbhc->resmgr);
/*
* Fast(mbhc) mode bandagap doesn't need to be enabled explicitly
* since fast mode is set by MBHC hardware when override is on.
* Enable bandgap mode to avoid unnecessary RCO disable and enable
* during clock source change.
*/
- wcd9xxx_resmgr_get_bandgap(mbhc->resmgr, WCD9XXX_BANDGAP_AUDIO_MODE);
- wcd9xxx_resmgr_get_clk_block(mbhc->resmgr, WCD9XXX_CLK_RCO);
- WCD9XXX_BG_CLK_UNLOCK(mbhc->resmgr);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, true);
wcd9xxx_turn_onoff_override(mbhc, true);
pr_debug("%s: Setting impedance detection\n", __func__);
@@ -4405,10 +4417,7 @@
mutex_unlock(&codec->mutex);
- WCD9XXX_BG_CLK_LOCK(mbhc->resmgr);
- wcd9xxx_resmgr_put_bandgap(mbhc->resmgr, WCD9XXX_BANDGAP_AUDIO_MODE);
- wcd9xxx_resmgr_put_clk_block(mbhc->resmgr, WCD9XXX_CLK_RCO);
- WCD9XXX_BG_CLK_UNLOCK(mbhc->resmgr);
+ wcd9xxx_mbhc_ctrl_clk_bandgap(mbhc, false);
wcd9xxx_turn_onoff_override(mbhc, false);
mbhc->mbhc_cb->compute_impedance(l, r, zl, zr);
@@ -4447,7 +4456,9 @@
int wcd9xxx_mbhc_init(struct wcd9xxx_mbhc *mbhc, struct wcd9xxx_resmgr *resmgr,
struct snd_soc_codec *codec,
int (*micbias_enable_cb) (struct snd_soc_codec*, bool),
- const struct wcd9xxx_mbhc_cb *mbhc_cb, int rco_clk_rate,
+ const struct wcd9xxx_mbhc_cb *mbhc_cb,
+ const struct wcd9xxx_mbhc_intr *mbhc_cdc_intr_ids,
+ int rco_clk_rate,
bool impedance_det_en)
{
int ret;
@@ -4474,9 +4485,15 @@
mbhc->micbias_enable_cb = micbias_enable_cb;
mbhc->rco_clk_rate = rco_clk_rate;
mbhc->mbhc_cb = mbhc_cb;
+ mbhc->intr_ids = mbhc_cdc_intr_ids;
mbhc->impedance_detect = impedance_det_en;
impedance_detect_en = impedance_det_en ? 1 : 0;
+ if (mbhc->intr_ids == NULL) {
+ pr_err("%s: Interrupt mapping not provided\n", __func__);
+ return -EINVAL;
+ }
+
if (mbhc->headset_jack.jack == NULL) {
ret = snd_soc_jack_new(codec, "Headset Jack", WCD9XXX_JACK_MASK,
&mbhc->headset_jack);
@@ -4520,62 +4537,62 @@
wcd9xxx_init_debugfs(mbhc);
core_res = mbhc->resmgr->core_res;
- ret = wcd9xxx_request_irq(core_res, WCD9XXX_IRQ_MBHC_INSERTION,
+ ret = wcd9xxx_request_irq(core_res, mbhc->intr_ids->insertion,
wcd9xxx_hs_insert_irq,
"Headset insert detect", mbhc);
if (ret) {
pr_err("%s: Failed to request irq %d, ret = %d\n", __func__,
- WCD9XXX_IRQ_MBHC_INSERTION, ret);
+ mbhc->intr_ids->insertion, ret);
goto err_insert_irq;
}
- wcd9xxx_disable_irq(core_res, WCD9XXX_IRQ_MBHC_INSERTION);
+ wcd9xxx_disable_irq(core_res, mbhc->intr_ids->insertion);
- ret = wcd9xxx_request_irq(core_res, WCD9XXX_IRQ_MBHC_REMOVAL,
+ ret = wcd9xxx_request_irq(core_res, mbhc->intr_ids->poll_plug_rem,
wcd9xxx_hs_remove_irq,
"Headset remove detect", mbhc);
if (ret) {
pr_err("%s: Failed to request irq %d\n", __func__,
- WCD9XXX_IRQ_MBHC_REMOVAL);
+ mbhc->intr_ids->poll_plug_rem);
goto err_remove_irq;
}
- ret = wcd9xxx_request_irq(core_res, WCD9XXX_IRQ_MBHC_POTENTIAL,
+ ret = wcd9xxx_request_irq(core_res, mbhc->intr_ids->dce_est_complete,
wcd9xxx_dce_handler, "DC Estimation detect",
mbhc);
if (ret) {
pr_err("%s: Failed to request irq %d\n", __func__,
- WCD9XXX_IRQ_MBHC_POTENTIAL);
+ mbhc->intr_ids->dce_est_complete);
goto err_potential_irq;
}
- ret = wcd9xxx_request_irq(core_res, WCD9XXX_IRQ_MBHC_RELEASE,
+ ret = wcd9xxx_request_irq(core_res, mbhc->intr_ids->button_release,
wcd9xxx_release_handler,
"Button Release detect", mbhc);
if (ret) {
pr_err("%s: Failed to request irq %d\n", __func__,
- WCD9XXX_IRQ_MBHC_RELEASE);
+ mbhc->intr_ids->button_release);
goto err_release_irq;
}
- ret = wcd9xxx_request_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPL_FAULT,
+ ret = wcd9xxx_request_irq(core_res, mbhc->intr_ids->hph_left_ocp,
wcd9xxx_hphl_ocp_irq, "HPH_L OCP detect",
mbhc);
if (ret) {
pr_err("%s: Failed to request irq %d\n", __func__,
- WCD9XXX_IRQ_HPH_PA_OCPL_FAULT);
+ mbhc->intr_ids->hph_left_ocp);
goto err_hphl_ocp_irq;
}
- wcd9xxx_disable_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPL_FAULT);
+ wcd9xxx_disable_irq(core_res, mbhc->intr_ids->hph_left_ocp);
- ret = wcd9xxx_request_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPR_FAULT,
+ ret = wcd9xxx_request_irq(core_res, mbhc->intr_ids->hph_right_ocp,
wcd9xxx_hphr_ocp_irq, "HPH_R OCP detect",
mbhc);
if (ret) {
pr_err("%s: Failed to request irq %d\n", __func__,
- WCD9XXX_IRQ_HPH_PA_OCPR_FAULT);
+ mbhc->intr_ids->hph_right_ocp);
goto err_hphr_ocp_irq;
}
- wcd9xxx_disable_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPR_FAULT);
+ wcd9xxx_disable_irq(core_res, mbhc->intr_ids->hph_right_ocp);
wcd9xxx_regmgr_cond_register(resmgr, 1 << WCD9XXX_COND_HPH_MIC |
1 << WCD9XXX_COND_HPH);
@@ -4584,15 +4601,15 @@
return ret;
err_hphr_ocp_irq:
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPL_FAULT, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->hph_left_ocp, mbhc);
err_hphl_ocp_irq:
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_RELEASE, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->button_release, mbhc);
err_release_irq:
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_POTENTIAL, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->dce_est_complete, mbhc);
err_potential_irq:
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_REMOVAL, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->poll_plug_rem, mbhc);
err_remove_irq:
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_INSERTION, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->insertion, mbhc);
err_insert_irq:
wcd9xxx_resmgr_unregister_notifier(mbhc->resmgr, &mbhc->nblock);
@@ -4609,22 +4626,15 @@
wcd9xxx_regmgr_cond_deregister(mbhc->resmgr, 1 << WCD9XXX_COND_HPH_MIC |
1 << WCD9XXX_COND_HPH);
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_RELEASE, mbhc);
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_POTENTIAL, mbhc);
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_REMOVAL, mbhc);
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_MBHC_INSERTION, mbhc);
-
- if (mbhc->mbhc_cb && mbhc->mbhc_cb->free_irq)
- mbhc->mbhc_cb->free_irq(mbhc);
- else
- wcd9xxx_free_irq(core_res, WCD9320_IRQ_MBHC_JACK_SWITCH,
- mbhc);
-
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPL_FAULT, mbhc);
- wcd9xxx_free_irq(core_res, WCD9XXX_IRQ_HPH_PA_OCPR_FAULT, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->button_release, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->dce_est_complete, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->poll_plug_rem, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->insertion, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->hs_jack_switch, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->hph_left_ocp, mbhc);
+ wcd9xxx_free_irq(core_res, mbhc->intr_ids->hph_right_ocp, mbhc);
wcd9xxx_resmgr_unregister_notifier(mbhc->resmgr, &mbhc->nblock);
-
wcd9xxx_cleanup_debugfs(mbhc);
}
EXPORT_SYMBOL(wcd9xxx_mbhc_deinit);
diff --git a/sound/soc/codecs/wcd9xxx-mbhc.h b/sound/soc/codecs/wcd9xxx-mbhc.h
index 91280e4..9d0afe9 100644
--- a/sound/soc/codecs/wcd9xxx-mbhc.h
+++ b/sound/soc/codecs/wcd9xxx-mbhc.h
@@ -236,16 +236,26 @@
u8 reg_mask;
};
+struct wcd9xxx_mbhc_intr {
+ int poll_plug_rem;
+ int shortavg_complete;
+ int potential_button_press;
+ int button_release;
+ int dce_est_complete;
+ int insertion;
+ int hph_left_ocp;
+ int hph_right_ocp;
+ int hs_jack_switch;
+};
+
struct wcd9xxx_mbhc_cb {
void (*enable_mux_bias_block) (struct snd_soc_codec *);
void (*cfilt_fast_mode) (struct snd_soc_codec *, struct wcd9xxx_mbhc *);
void (*codec_specific_cal) (struct snd_soc_codec *,
struct wcd9xxx_mbhc *);
- int (*jack_detect_irq) (struct snd_soc_codec *);
struct wcd9xxx_cfilt_mode (*switch_cfilt_mode) (struct wcd9xxx_mbhc *,
bool);
void (*select_cfilt) (struct snd_soc_codec *, struct wcd9xxx_mbhc *);
- void (*free_irq) (struct wcd9xxx_mbhc *);
enum wcd9xxx_cdc_type (*get_cdc_type) (void);
void (*enable_clock_gate) (struct snd_soc_codec *, bool);
int (*setup_zdet) (struct wcd9xxx_mbhc *,
@@ -327,6 +337,9 @@
bool update_z;
+ /* Holds codec specific interrupt mapping */
+ const struct wcd9xxx_mbhc_intr *intr_ids;
+
#ifdef CONFIG_DEBUG_FS
struct dentry *debugfs_poke;
struct dentry *debugfs_mbhc;
@@ -395,6 +408,7 @@
struct snd_soc_codec *codec,
int (*micbias_enable_cb) (struct snd_soc_codec*, bool),
const struct wcd9xxx_mbhc_cb *mbhc_cb,
+ const struct wcd9xxx_mbhc_intr *mbhc_cdc_intr_ids,
int rco_clk_rate,
bool impedance_det_en);
void wcd9xxx_mbhc_deinit(struct wcd9xxx_mbhc *mbhc);
diff --git a/sound/soc/msm/msm-pcm-hostless.c b/sound/soc/msm/msm-pcm-hostless.c
index 789749f..0f3573b 100644
--- a/sound/soc/msm/msm-pcm-hostless.c
+++ b/sound/soc/msm/msm-pcm-hostless.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2011-2013, 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
@@ -18,7 +18,21 @@
#include <sound/soc.h>
#include <sound/pcm.h>
-static struct snd_pcm_ops msm_pcm_hostless_ops = {};
+
+static int msm_pcm_hostless_prepare(struct snd_pcm_substream *substream)
+{
+ if (!substream) {
+ pr_err("%s: invalid params\n", __func__);
+ return -EINVAL;
+ }
+ if (pm_qos_request_active(&substream->latency_pm_qos_req))
+ pm_qos_remove_request(&substream->latency_pm_qos_req);
+ return 0;
+}
+
+static struct snd_pcm_ops msm_pcm_hostless_ops = {
+ .prepare = msm_pcm_hostless_prepare
+};
static struct snd_soc_platform_driver msm_soc_hostless_platform = {
.ops = &msm_pcm_hostless_ops,
diff --git a/sound/soc/msm/qdsp6v2/q6afe.c b/sound/soc/msm/qdsp6v2/q6afe.c
index 59113fe..09ecd75 100644
--- a/sound/soc/msm/qdsp6v2/q6afe.c
+++ b/sound/soc/msm/qdsp6v2/q6afe.c
@@ -648,7 +648,7 @@
ret = get_hw_delay(RX_CAL, &delay_entry);
if (ret != 0) {
- pr_warn("%s: Failed to get hw delay info\n", __func__);
+ pr_debug("%s: Failed to get hw delay info\n", __func__);
goto fail_cmd;
}
index = q6audio_get_port_index(port_id);