summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Documentation/devicetree/bindings/media/dra7-radio.txt16
-rw-r--r--Documentation/devicetree/bindings/power/coproc/ti-coproc.txt35
-rw-r--r--Documentation/devicetree/bindings/sound/davinci-evm-audio.txt2
-rw-r--r--arch/arm/boot/dts/am57xx-beagle-x15.dts5
-rw-r--r--arch/arm/boot/dts/dra7-evm-lcd10.dts13
-rw-r--r--arch/arm/boot/dts/dra7-evm.dts153
-rw-r--r--arch/arm/boot/dts/dra7.dtsi44
-rw-r--r--arch/arm/boot/dts/dra72-evm.dts95
-rw-r--r--arch/arm/boot/dts/dra72x.dtsi28
-rw-r--r--arch/arm/boot/dts/dra74x.dtsi28
-rw-r--r--arch/arm/boot/dts/dra7xx-evm-lcd10.dtsi19
-rw-r--r--arch/arm/boot/dts/dra7xx-evm-lcd7.dtsi103
-rw-r--r--arch/arm/mach-omap2/omap_hwmod_7xx_data.c124
-rw-r--r--drivers/clk/ti/clk-7xx.c2
-rw-r--r--drivers/gpio/gpio-mcp23s08.c9
-rw-r--r--drivers/gpu/drm/drm_prime.c7
-rw-r--r--drivers/gpu/drm/omapdrm/omap_drv.c12
-rw-r--r--drivers/input/touchscreen/Kconfig13
-rw-r--r--drivers/input/touchscreen/Makefile1
-rw-r--r--drivers/input/touchscreen/ldc3001_ts.c526
-rw-r--r--drivers/media/platform/Kconfig11
-rw-r--r--drivers/media/radio/Kconfig16
-rw-r--r--drivers/media/radio/Makefile1
-rw-r--r--drivers/media/radio/dra7xx_radio.c106
-rw-r--r--drivers/media/radio/dra7xx_radio_helper.c63
-rw-r--r--drivers/power/Kconfig1
-rw-r--r--drivers/power/Makefile1
-rw-r--r--drivers/power/coproc/Kconfig7
-rw-r--r--drivers/power/coproc/Makefile2
-rw-r--r--drivers/power/coproc/ti-coproc.c229
-rw-r--r--drivers/usb/dwc3/debugfs.c11
-rw-r--r--drivers/usb/dwc3/dwc3-omap.c30
-rw-r--r--firmware/Makefile3
-rw-r--r--firmware/vpdma-1b8.bin.ihex252
-rw-r--r--include/linux/usb/drd.h9
-rw-r--r--include/uapi/drm/drm.h1
-rw-r--r--include/uapi/linux/videodev2.h2
-rw-r--r--sound/soc/davinci/davinci-evm.c6
-rw-r--r--sound/soc/davinci/davinci-mcasp.c18
-rw-r--r--sound/soc/davinci/davinci-mcasp.h4
-rw-r--r--ti_config_fragments/baseport.cfg3
-rw-r--r--ti_config_fragments/connectivity.cfg1
-rwxr-xr-xti_config_fragments/linux_config.sh12
-rw-r--r--ti_config_fragments/radio.cfg9
44 files changed, 1946 insertions, 87 deletions
diff --git a/Documentation/devicetree/bindings/media/dra7-radio.txt b/Documentation/devicetree/bindings/media/dra7-radio.txt
new file mode 100644
index 00000000000..a61e3a829cb
--- /dev/null
+++ b/Documentation/devicetree/bindings/media/dra7-radio.txt
@@ -0,0 +1,16 @@
+Texas Instruments DRA7xx Radio Helper
+
+Radio Helper is a dummy device on top of the devices such as McAsp
+that needs to be configured for Radio playback.
+The corresponding platform driver configures these devices as
+required.
+
+Top node:
+Required properties:
+ - compatible: "ti,dra7xx_radio"
+ - gpios: List of the gpios that needs to be configured
+
+child nodes:
+ - compatible: "ti,dra7xx_radio_subdev"
+ - ti,hwmods: Name of the hwmod associated to the underlying devices
+ - status: Device status
diff --git a/Documentation/devicetree/bindings/power/coproc/ti-coproc.txt b/Documentation/devicetree/bindings/power/coproc/ti-coproc.txt
new file mode 100644
index 00000000000..d60c1f2df57
--- /dev/null
+++ b/Documentation/devicetree/bindings/power/coproc/ti-coproc.txt
@@ -0,0 +1,35 @@
+Texas Instruments co-processor driver
+
+A co-processor device is a non-cpu processor found on an SoC.
+
+This document describes the clock and voltage configuration
+used by co-processors/devices typically found on Texas Instrument SoCs.
+
+Required properties
+- compatible: should be
+ "ti,coproc"
+- clocks: <functional clock>, <dpll clock>
+ dpll clock is optional
+- clock-names: "fclk", "dpll"
+ if you change names here, go chnage the driver too
+- clock-target-frequency: Mention your target frequency here
+- operating-points: all OPPs applicable for this device/coprocessor
+- coproc-voltdm: phandle of the Voltage domain associated with this device/coproc
+- voltage-tolerance: Specify a voltage tolerance allowed for this voltage domain
+as per datamanual limits
+
+Example:
+iva_coproc {
+ compatible = "ti,coproc";
+ clocks = <&dpll_iva_m2_ck>, <&dpll_iva_ck>;
+ clock-names = "fclk", "dpll";
+ clock-target-frequency = <532000000>;
+ operating-points = <
+ 388200 1055000
+ 430000 1150000
+ 532000 1250000
+ >;
+ coproc-voltdm = <&voltdm_ivahd>;
+ voltage-tolerance = <1>;
+};
+
diff --git a/Documentation/devicetree/bindings/sound/davinci-evm-audio.txt b/Documentation/devicetree/bindings/sound/davinci-evm-audio.txt
index 75601465368..495ceb1b9da 100644
--- a/Documentation/devicetree/bindings/sound/davinci-evm-audio.txt
+++ b/Documentation/devicetree/bindings/sound/davinci-evm-audio.txt
@@ -19,6 +19,8 @@ Optional properties:
- Either codec-clock-rate or the codec-clock reference has to be defined. If
the both are defined the driver attempts to set referenced clock to the
defined rate and takes the rate from the clock reference.
+- ti,always-on: Keep analog codec always on to minimize artifacts. Use it
+ if power is not a concern.
Board connectors:
diff --git a/arch/arm/boot/dts/am57xx-beagle-x15.dts b/arch/arm/boot/dts/am57xx-beagle-x15.dts
index 5c6f6a08198..506162dce9b 100644
--- a/arch/arm/boot/dts/am57xx-beagle-x15.dts
+++ b/arch/arm/boot/dts/am57xx-beagle-x15.dts
@@ -711,6 +711,11 @@
voltage-tolerance = <1>;
};
+&gpu {
+ gpu0-voltdm = <&voltdm_gpu>;
+ voltage-tolerance = <1>;
+};
+
&mac {
status = "okay";
pinctrl-names = "default", "sleep";
diff --git a/arch/arm/boot/dts/dra7-evm-lcd10.dts b/arch/arm/boot/dts/dra7-evm-lcd10.dts
index 361c20f3d72..54216e81d6a 100644
--- a/arch/arm/boot/dts/dra7-evm-lcd10.dts
+++ b/arch/arm/boot/dts/dra7-evm-lcd10.dts
@@ -9,6 +9,15 @@
#include "dra7-evm.dts"
#include "dra7xx-evm-lcd10.dtsi"
-&tlv320aic3106 {
- reg = <0x19>;
+/* override pinmux for tsc irq line on dra74x */
+&tsc_pins {
+ pinctrl-single,pins = <
+ 0x420 (PIN_INPUT_PULLDOWN | MUX_MODE14) /* gpio1_2 */
+ >;
+};
+
+&ldc3001 {
+ interrupt-parent = <&gpio1>;
+ interrupts = <2 IRQ_TYPE_LEVEL_HIGH>;
+ pinctrl-0 = <&tsc_pins>;
};
diff --git a/arch/arm/boot/dts/dra7-evm.dts b/arch/arm/boot/dts/dra7-evm.dts
index f00db0cb668..9bb768a29a4 100644
--- a/arch/arm/boot/dts/dra7-evm.dts
+++ b/arch/arm/boot/dts/dra7-evm.dts
@@ -53,6 +53,13 @@
reusable;
status = "okay";
};
+
+ /* Required by cmem driver used by radio */
+ cmem_radio: cmem@95400000 {
+ reg = <0x95400000 0x400000>;
+ no-map;
+ status = "okay";
+ };
};
extcon1: dra7x_usbid_extcon1 {
@@ -176,12 +183,19 @@
};
};
+ ocp {
+ gpu: gpu@0x56000000 {
+ gpu0-voltdm = <&voltdm_gpu>;
+ };
+ };
+
primary_sound: primary_sound {
compatible = "ti,dra7xx-evm-audio";
ti,model = "DRA7xx-EVM";
+ ti,always-on;
ti,audio-codec = <&tlv320aic3106>;
ti,mcasp-controller = <&mcasp3>;
- ti,codec-clock-rate = <5644800>;
+ ti,codec-clock-rate = <11289600>;
clocks = <&atl_clkin2_ck>;
clock-names = "mclk";
ti,audio-routing =
@@ -195,6 +209,14 @@
"LINE1L", "Line In",
"LINE1R", "Line In";
};
+
+ radio {
+ compatible = "ti,dra7xx_radio";
+ gpios = <&gpio6 20 0>;
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&radio_pins>;
+ };
};
&dra7_pmx_core {
@@ -480,6 +502,21 @@
>;
};
+ mcasp2_pins: pinmux_mcasp2_pins {
+ pinctrl-single,pins = <
+ 0x02F4 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_aclkx */
+ 0x02F8 (PIN_INPUT_SLEW | MUX_MODE0) /* mcasp2_afsx */
+ 0x0304 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr0 */
+ 0x0308 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr1 */
+ 0x030C (PIN_INPUT_SLEW | MUX_MODE0) /* mcasp2_axr2 */
+ 0x0310 (PIN_INPUT_SLEW | MUX_MODE0) /* mcasp2_axr3 */
+ 0x0314 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr4 */
+ 0x0318 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr5 */
+ 0x031c (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr6 */
+ 0x0320 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr7 */
+ >;
+ };
+
mcasp3_pins: pinmux_mcasp3_pins {
pinctrl-single,pins = <
0x324 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* mcasp3_aclkx */
@@ -497,6 +534,23 @@
0x330 (PIN_OFF_NONE)
>;
};
+
+ mcasp6_pins: pinmux_mcasp6_pins {
+ pinctrl-single,pins = <
+ 0x2d4 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* mcasp6_axr0 */
+ 0x2d8 (PIN_INPUT_PULLDOWN | MUX_MODE1) /* mcasp6_axr1 */
+ 0x2dc (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* mcasp6_clkx */
+ 0x2e0 (PIN_INPUT_PULLDOWN | MUX_MODE1) /* mcasp6_fsx */
+ >;
+ };
+
+ radio_pins: pinmux_radio_pins {
+ pinctrl-single,pins = <
+ 0x0334 (PIN_INPUT | MUX_MODE4) /* i2c4_sda */
+ 0x0338 (PIN_INPUT | MUX_MODE4) /* i2c4_scl */
+ 0x02A0 (PIN_INPUT | MUX_MODE14) /* gpio6_20 */
+ >;
+ };
};
&i2c1 {
@@ -638,64 +692,6 @@
#interrupt-cells = <2>;
};
- mxt244: touchscreen@4a {
- compatible = "atmel,mXT244";
- status = "okay";
- reg = <0x4a>;
- interrupts = <GIC_SPI 114 IRQ_TYPE_LEVEL_HIGH>;
- pinctrl-0 = <&tsc_pins>;
-
- atmel,config = <
- /* MXT244_GEN_COMMAND(6) */
- 0x00 0x00 0x00 0x00 0x00 0x00
- /* MXT244_GEN_POWER(7) */
- 0x20 0xff 0x32
- /* MXT244_GEN_ACQUIRE(8) */
- 0x0a 0x00 0x05 0x00 0x00 0x00 0x09 0x23
- /* MXT244_TOUCH_MULTI(9) */
- 0x00 0x00 0x00 0x13 0x0b 0x00 0x00 0x00 0x02 0x00
- 0x00 0x01 0x01 0x0e 0x0a 0x0a 0x0a 0x0a 0x00 0x00
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- 0x00
- /* MXT244_TOUCH_KEYARRAY(15) */
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- 0x00
- /* MXT244_COMMSCONFIG_T18(2) */
- 0x00 0x00
- /* MXT244_SPT_GPIOPWM(19) */
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- 0x00 0x00 0x00 0x00 0x00 0x00
- /* MXT244_PROCI_GRIPFACE(20) */
- 0x07 0x00 0x00 0x00 0x00 0x00 0x00 0x50 0x28 0x04
- 0x0f 0x0a
- /* MXT244_PROCG_NOISE(22) */
- 0x05 0x00 0x00 0x00 0x00 0x00 0x00 0x03 0x23 0x00
- 0x00 0x05 0x0f 0x19 0x23 0x2d 0x03
- /* MXT244_TOUCH_PROXIMITY(23) */
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- 0x00 0x00 0x00 0x00 0x00
- /* MXT244_PROCI_ONETOUCH(24) */
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- /* MXT244_SPT_SELFTEST(25) */
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- 0x00 0x00 0x00 0x00
- /* MXT244_PROCI_TWOTOUCH(27) */
- 0x00 0x00 0x00 0x00 0x00 0x00 0x00
- /* MXT244_SPT_CTECONFIG(28) */
- 0x00 0x00 0x02 0x08 0x10 0x00
- >;
-
- atmel,x_line = <18>;
- atmel,y_line = <12>;
- atmel,x_size = <800>;
- atmel,y_size = <480>;
- atmel,blen = <0x01>;
- atmel,threshold = <30>;
- atmel,voltage = <2800000>;
- atmel,orient = <0x4>;
- };
-
tlv320aic3106: tlv320aic3106@18 {
compatible = "ti,tlv320aic3106";
reg = <0x18>;
@@ -1116,12 +1112,33 @@
status = "okay";
+ atl1 {
+ bws = <DRA7_ATL_WS_MCASP2_FSX>;
+ aws = <DRA7_ATL_WS_MCASP6_FSX>;
+ };
+
atl2 {
bws = <DRA7_ATL_WS_MCASP2_FSX>;
aws = <DRA7_ATL_WS_MCASP3_FSX>;
};
};
+&mcasp2 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&mcasp2_pins>;
+
+ fck_parent = "atl_clkin2_ck";
+
+ status = "okay";
+
+ op-mode = <0>; /* MCASP_IIS_MODE */
+ tdm-slots = <2>;
+ /* 8 serializer */
+ serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
+ 1 1 1 1 1 1 1 1
+ >;
+};
+
&mcasp3 {
pinctrl-names = "default", "sleep";
pinctrl-0 = <&mcasp3_pins>;
@@ -1138,3 +1155,21 @@
1 2 0 0
>;
};
+
+&mcasp6 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&mcasp6_pins>;
+
+ fck_parent = "atl_clkin1_ck";
+
+ status = "okay";
+
+ op-mode = <0>; /* MCASP_IIS_MODE */
+ tdm-slots = <8>;
+ /* 4 serializer */
+ serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
+ 1 2 0 0
+ >;
+ tx-num-evt = <8>;
+ rx-num-evt = <8>;
+};
diff --git a/arch/arm/boot/dts/dra7.dtsi b/arch/arm/boot/dts/dra7.dtsi
index e65b69238d3..6486cf0ee98 100644
--- a/arch/arm/boot/dts/dra7.dtsi
+++ b/arch/arm/boot/dts/dra7.dtsi
@@ -825,6 +825,22 @@
status = "disabled";
};
+ gpu: gpu@0x56000000 {
+ compatible = "ti,omap4-gpu";
+ reg = <0x56000000 0xffff>;
+ interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>;
+ ti,hwmods = "gpu";
+ operating-points = <
+ /* kHz uV */
+ 425600 1090000
+ 532000 1280000
+ >;
+ clocks = <&dpll_core_h14x2_ck>, <&dpll_per_h14x2_ck>,
+ <&dpll_gpu_m2_ck>, <&gpu_core_gclk_mux>,
+ <&gpu_hyd_gclk_mux>;
+ clock-names = "core", "per", "gpu", "gpu_core", "gpu_hyd";
+ };
+
i2c1: i2c@48070000 {
compatible = "ti,omap4-i2c";
reg = <0x48070000 0x100>;
@@ -1828,6 +1844,18 @@
status = "disabled";
};
+ mcasp2: mcasp@48464000 {
+ compatible = "ti,dra7-mcasp-audio";
+ ti,hwmods = "mcasp2";
+ reg = <0x48464000 0x2000>;
+ reg-names = "mpu";
+ dmas = <&sdma 131 &dmacb>, <&sdma 130 &dmacb>;
+ dma-names = "tx", "rx";
+ clocks = <&mcasp2_ahclkx_mux>;
+ clock-names = "fck";
+ status = "disabled";
+ };
+
mcasp3: mcasp@48468000 {
compatible = "ti,dra7-mcasp-audio";
ti,hwmods = "mcasp3";
@@ -1843,6 +1871,22 @@
status = "disabled";
};
+ mcasp6: mcasp@48474000 {
+ compatible = "ti,dra7-mcasp-audio";
+ ti,hwmods = "mcasp6";
+ reg = <0x48474000 0x2000>,
+ <0x4844c000 0x1000>;
+ reg-names = "mpu","dat";
+ interrupts = <GIC_SPI 157 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 156 IRQ_TYPE_LEVEL_HIGH>;
+ interrupt-names = "tx", "rx";
+ dmas = <&sdma 139 &dmacb>, <&sdma 138 &dmacb>;
+ dma-names = "tx", "rx";
+ clocks = <&mcasp6_ahclkx_mux>;
+ clock-names = "fck";
+ status = "disabled";
+ };
+
vip1: vip@0x48970000 {
compatible = "ti,vip1";
reg = <0x48970000 0x10000>,
diff --git a/arch/arm/boot/dts/dra72-evm.dts b/arch/arm/boot/dts/dra72-evm.dts
index fe8c3e7ca88..c747dd63ebd 100644
--- a/arch/arm/boot/dts/dra72-evm.dts
+++ b/arch/arm/boot/dts/dra72-evm.dts
@@ -96,6 +96,13 @@
reusable;
status = "okay";
};
+
+ /* Required by cmem driver used by radio */
+ cmem_radio: cmem@95400000 {
+ reg = <0x95400000 0x400000>;
+ no-map;
+ status = "okay";
+ };
};
extcon1: dra7x_usbid_extcon1 {
@@ -138,9 +145,10 @@
primary_sound: primary_sound {
compatible = "ti,dra7xx-evm-audio";
ti,model = "DRA7xx-EVM";
+ ti,always-on;
ti,audio-codec = <&tlv320aic3106>;
ti,mcasp-controller = <&mcasp3>;
- ti,codec-clock-rate = <5644800>;
+ ti,codec-clock-rate = <11289600>;
clocks = <&atl_clkin2_ck>;
clock-names = "mclk";
ti,audio-routing =
@@ -154,6 +162,14 @@
"LINE1L", "Line In",
"LINE1R", "Line In";
};
+
+ radio {
+ compatible = "ti,dra7xx_radio";
+ gpios = <&gpio6 20 0>;
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&radio_pins>;
+ };
};
&dra7_pmx_core {
@@ -310,6 +326,21 @@
>;
};
+ mcasp2_pins: pinmux_mcasp2_pins {
+ pinctrl-single,pins = <
+ 0x02F4 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_aclkx */
+ 0x02F8 (PIN_INPUT_SLEW | MUX_MODE0) /* mcasp2_afsx */
+ 0x0304 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr0 */
+ 0x0308 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr1 */
+ 0x030C (PIN_INPUT_SLEW | MUX_MODE0) /* mcasp2_axr2 */
+ 0x0310 (PIN_INPUT_SLEW | MUX_MODE0) /* mcasp2_axr3 */
+ 0x0314 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr4 */
+ 0x0318 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr5 */
+ 0x031c (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr6 */
+ 0x0320 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp2_axr7 */
+ >;
+ };
+
mcasp3_pins: pinmux_mcasp3_pins {
pinctrl-single,pins = <
0x324 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* mcasp3_aclkx */
@@ -328,6 +359,15 @@
>;
};
+ mcasp6_pins: pinmux_mcasp6_pins {
+ pinctrl-single,pins = <
+ 0x2d4 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* mcasp6_axr0 */
+ 0x2d8 (PIN_INPUT_PULLDOWN | MUX_MODE1) /* mcasp6_axr1 */
+ 0x2dc (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* mcasp6_clkx */
+ 0x2e0 (PIN_INPUT_PULLDOWN | MUX_MODE1) /* mcasp6_fsx */
+ >;
+ };
+
usb1_pins: pinmux_usb1_pins {
pinctrl-single,pins = <
0x280 (PIN_INPUT_SLEW | MUX_MODE0) /* usb1_drvvbus */
@@ -340,6 +380,12 @@
>;
};
+ tsc_pins: pinmux_tsc_pins {
+ pinctrl-single,pins = <
+ 0x3D4 (PIN_INPUT_PULLUP | MUX_MODE14) /* dcan1_rx -> gpio1_15 */
+ >;
+ };
+
qspi1_pins: pinmux_qspi1_pins {
pinctrl-single,pins = <
0x74 (PIN_OUTPUT | MUX_MODE1) /* gpmc_a13.qspi1_rtclk */
@@ -365,6 +411,14 @@
0x418 (MUX_MODE15) /* wakeup0.off */
>;
};
+
+ radio_pins: pinmux_radio_pins {
+ pinctrl-single,pins = <
+ 0x0334 (PIN_INPUT | MUX_MODE4) /* i2c4_sda */
+ 0x0338 (PIN_INPUT | MUX_MODE4) /* i2c4_scl */
+ 0x02A0 (PIN_INPUT | MUX_MODE14) /* gpio6_20 */
+ >;
+ };
};
&i2c1 {
@@ -810,12 +864,33 @@
status = "okay";
+ atl1 {
+ bws = <DRA7_ATL_WS_MCASP2_FSX>;
+ aws = <DRA7_ATL_WS_MCASP6_FSX>;
+ };
+
atl2 {
bws = <DRA7_ATL_WS_MCASP2_FSX>;
aws = <DRA7_ATL_WS_MCASP3_FSX>;
};
};
+&mcasp2 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&mcasp2_pins>;
+
+ fck_parent = "atl_clkin2_ck";
+
+ status = "okay";
+
+ op-mode = <0>; /* MCASP_IIS_MODE */
+ tdm-slots = <2>;
+ /* 8 serializer */
+ serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
+ 1 1 1 1 1 1 1 1
+ >;
+};
+
&mcasp3 {
pinctrl-names = "default", "sleep";
pinctrl-0 = <&mcasp3_pins>;
@@ -833,6 +908,24 @@
>;
};
+&mcasp6 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&mcasp6_pins>;
+
+ fck_parent = "atl_clkin1_ck";
+
+ status = "okay";
+
+ op-mode = <0>; /* MCASP_IIS_MODE */
+ tdm-slots = <8>;
+ /* 4 serializer */
+ serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
+ 1 2 0 0
+ >;
+ tx-num-evt = <8>;
+ rx-num-evt = <8>;
+};
+
&omap_dwc3_1 {
extcon = <&extcon1>;
};
diff --git a/arch/arm/boot/dts/dra72x.dtsi b/arch/arm/boot/dts/dra72x.dtsi
index b5eb3266663..3001c518c76 100644
--- a/arch/arm/boot/dts/dra72x.dtsi
+++ b/arch/arm/boot/dts/dra72x.dtsi
@@ -38,6 +38,34 @@
};
};
+ iva_coproc {
+ compatible = "ti,coproc";
+ clocks = <&dpll_iva_m2_ck>, <&dpll_iva_ck>;
+ clock-names = "fclk", "dpll";
+ clock-target-frequency = <532000000>;
+ operating-points = <
+ 388200 1055000
+ 430000 1150000
+ 532000 1250000
+ >;
+ coproc-voltdm = <&voltdm_ivahd>;
+ voltage-tolerance = <1>;
+ };
+
+ dsp_coproc {
+ compatible = "ti,coproc";
+ clocks = <&dpll_dsp_m2_ck>, <&dpll_dsp_ck>;
+ clock-names = "fclk", "dpll";
+ clock-target-frequency = <700000000>;
+ operating-points = <
+ 600000 1055000
+ 700000 1150000
+ 700000 1250000
+ >;
+ coproc-voltdm = <&voltdm_dspeve>;
+ voltage-tolerance = <1>;
+ };
+
thermal-zones {
#include "omap5-cpu-thermal.dtsi"
};
diff --git a/arch/arm/boot/dts/dra74x.dtsi b/arch/arm/boot/dts/dra74x.dtsi
index 8a36afcd925..e43fc2bd8eb 100644
--- a/arch/arm/boot/dts/dra74x.dtsi
+++ b/arch/arm/boot/dts/dra74x.dtsi
@@ -43,6 +43,34 @@
};
};
+ iva_coproc {
+ compatible = "ti,coproc";
+ clocks = <&dpll_iva_m2_ck>, <&dpll_iva_ck>;
+ clock-names = "fclk", "dpll";
+ clock-target-frequency = <532000000>;
+ operating-points = <
+ 388200 1055000
+ 430000 1150000
+ 532000 1250000
+ >;
+ coproc-voltdm = <&voltdm_ivahd>;
+ voltage-tolerance = <1>;
+ };
+
+ dsp_coproc {
+ compatible = "ti,coproc";
+ clocks = <&dpll_dsp_m2_ck>, <&dpll_dsp_ck>;
+ clock-names = "fclk", "dpll";
+ clock-target-frequency = <700000000>;
+ operating-points = <
+ 600000 1055000
+ 700000 1150000
+ 700000 1250000
+ >;
+ coproc-voltdm = <&voltdm_dspeve>;
+ voltage-tolerance = <1>;
+ };
+
thermal-zones {
#include "omap5-cpu-thermal.dtsi"
};
diff --git a/arch/arm/boot/dts/dra7xx-evm-lcd10.dtsi b/arch/arm/boot/dts/dra7xx-evm-lcd10.dtsi
index 1580a2c3147..46033410b66 100644
--- a/arch/arm/boot/dts/dra7xx-evm-lcd10.dtsi
+++ b/arch/arm/boot/dts/dra7xx-evm-lcd10.dtsi
@@ -26,6 +26,25 @@
};
};
};
+
+ ldc3001:ldc3001@18 {
+ compatible = "lgphilips,ldc3001";
+ status = "okay";
+ reg = <0x18>;
+ interrupt-parent = <&gpio1>;
+ interrupts = <15 IRQ_TYPE_LEVEL_HIGH>;
+ pinctrl-0 = <&tsc_pins>;
+ max-touch-points = <10>;
+ res-x = <1280>;
+ res-y = <800>;
+ };
+
+
+};
+
+/* audio codec i2c address moved to 0x19 for 10" display config */
+&tlv320aic3106 {
+ reg = <0x19>;
};
&dss {
diff --git a/arch/arm/boot/dts/dra7xx-evm-lcd7.dtsi b/arch/arm/boot/dts/dra7xx-evm-lcd7.dtsi
index ded5ea579f1..bf5612f98ed 100644
--- a/arch/arm/boot/dts/dra7xx-evm-lcd7.dtsi
+++ b/arch/arm/boot/dts/dra7xx-evm-lcd7.dtsi
@@ -6,8 +6,105 @@
* published by the Free Software Foundation.
*/
-#include "dra7xx-evm-lcd10.dtsi"
+/ {
+ aliases {
+ display0 = &tlc59108;
+ display1 = &hdmi0;
+ };
+};
+
+/* 7" display and tsc hooked to i2c1 */
+&i2c1 {
+ /* TLC chip for LCD panel power and backlight */
+ tlc59108: tlc59108@40 {
+ compatible = "ti,tlc59108-tfcs9700";
+ reg = <0x40>;
+ enable-gpios = <&pcf_lcd 13 GPIO_ACTIVE_LOW>; /* P15, CON_LCD_PWR_DN */
+
+ port {
+ tlc_in: endpoint {
+ remote-endpoint = <&dpi_out>;
+ };
+ };
+ };
+
+
+
+
+ mxt244: touchscreen@4a {
+ compatible = "atmel,mXT244";
+ status = "okay";
+ reg = <0x4a>;
+ interrupts = <GIC_SPI 114 IRQ_TYPE_LEVEL_HIGH>;
+ pinctrl-0 = <&tsc_pins>;
+
+ atmel,config = <
+ /* MXT244_GEN_COMMAND(6) */
+ 0x00 0x00 0x00 0x00 0x00 0x00
+ /* MXT244_GEN_POWER(7) */
+ 0x20 0xff 0x32
+ /* MXT244_GEN_ACQUIRE(8) */
+ 0x0a 0x00 0x05 0x00 0x00 0x00 0x09 0x23
+ /* MXT244_TOUCH_MULTI(9) */
+ 0x00 0x00 0x00 0x13 0x0b 0x00 0x00 0x00 0x02 0x00
+ 0x00 0x01 0x01 0x0e 0x0a 0x0a 0x0a 0x0a 0x00 0x00
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ 0x00
+ /* MXT244_TOUCH_KEYARRAY(15) */
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ 0x00
+ /* MXT244_COMMSCONFIG_T18(2) */
+ 0x00 0x00
+ /* MXT244_SPT_GPIOPWM(19) */
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ 0x00 0x00 0x00 0x00 0x00 0x00
+ /* MXT244_PROCI_GRIPFACE(20) */
+ 0x07 0x00 0x00 0x00 0x00 0x00 0x00 0x50 0x28 0x04
+ 0x0f 0x0a
+ /* MXT244_PROCG_NOISE(22) */
+ 0x05 0x00 0x00 0x00 0x00 0x00 0x00 0x03 0x23 0x00
+ 0x00 0x05 0x0f 0x19 0x23 0x2d 0x03
+ /* MXT244_TOUCH_PROXIMITY(23) */
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ 0x00 0x00 0x00 0x00 0x00
+ /* MXT244_PROCI_ONETOUCH(24) */
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ /* MXT244_SPT_SELFTEST(25) */
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ 0x00 0x00 0x00 0x00
+ /* MXT244_PROCI_TWOTOUCH(27) */
+ 0x00 0x00 0x00 0x00 0x00 0x00 0x00
+ /* MXT244_SPT_CTECONFIG(28) */
+ 0x00 0x00 0x02 0x08 0x10 0x00
+ >;
+
+ atmel,x_line = <18>;
+ atmel,y_line = <12>;
+ atmel,x_size = <800>;
+ atmel,y_size = <480>;
+ atmel,blen = <0x01>;
+ atmel,threshold = <30>;
+ atmel,voltage = <2800000>;
+ atmel,orient = <0x4>;
+ };
+};
+
+&dss {
+ pinctrl-names = "default";
+ pinctrl-0 = <&vout1_pins>;
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port {
+ reg = <0>;
-&tlc59108 {
- compatible = "ti,tlc59108-tfcs9700";
+ dpi_out: endpoint {
+ remote-endpoint = <&tlc_in>;
+ data-lines = <24>;
+ };
+ };
+ };
};
diff --git a/arch/arm/mach-omap2/omap_hwmod_7xx_data.c b/arch/arm/mach-omap2/omap_hwmod_7xx_data.c
index 5ae755c6c69..75df5757869 100644
--- a/arch/arm/mach-omap2/omap_hwmod_7xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_7xx_data.c
@@ -1114,6 +1114,40 @@ static struct omap_hwmod dra7xx_gpmc_hwmod = {
};
/*
+ * 'gpu' class
+ * 2d/3d graphics accelerator
+ */
+
+static struct omap_hwmod_class_sysconfig dra7xx_gpu_sysc = {
+ .rev_offs = 0x0000,
+ .sysc_offs = 0x0010,
+ .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
+ .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
+ SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
+ MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
+ .sysc_fields = &omap_hwmod_sysc_type2,
+};
+
+static struct omap_hwmod_class dra7xx_gpu_hwmod_class = {
+ .name = "gpu",
+ .sysc = &dra7xx_gpu_sysc,
+};
+
+static struct omap_hwmod dra7xx_gpu_hwmod = {
+ .name = "gpu",
+ .class = &dra7xx_gpu_hwmod_class,
+ .clkdm_name = "gpu_clkdm",
+ .main_clk = "gpu_core_gclk_mux",
+ .prcm = {
+ .omap4 = {
+ .clkctrl_offs = DRA7XX_CM_GPU_GPU_CLKCTRL_OFFSET,
+ .context_offs = DRA7XX_RM_GPU_GPU_CONTEXT_OFFSET,
+ .modulemode = MODULEMODE_SWCTRL,
+ },
+ },
+};
+
+/*
* 'hdq1w' class
*
*/
@@ -1620,6 +1654,22 @@ static struct omap_hwmod_class dra7xx_mcasp_hwmod_class = {
.sysc = &dra7xx_mcasp_sysc,
};
+/* mcasp2 */
+static struct omap_hwmod dra7xx_mcasp2_hwmod = {
+ .name = "mcasp2",
+ .class = &dra7xx_mcasp_hwmod_class,
+ .clkdm_name = "l4per2_clkdm",
+ .main_clk = "mcasp2_ahclkx_mux",
+ .flags = HWMOD_SWSUP_SIDLE_ACT,
+ .prcm = {
+ .omap4 = {
+ .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP2_CLKCTRL_OFFSET,
+ .context_offs = DRA7XX_RM_L4PER2_MCASP2_CONTEXT_OFFSET,
+ .modulemode = MODULEMODE_SWCTRL,
+ },
+ },
+};
+
/* mcasp3 */
static struct omap_hwmod dra7xx_mcasp3_hwmod = {
.name = "mcasp3",
@@ -1636,6 +1686,22 @@ static struct omap_hwmod dra7xx_mcasp3_hwmod = {
},
};
+/* mcasp6 */
+static struct omap_hwmod dra7xx_mcasp6_hwmod = {
+ .name = "mcasp6",
+ .class = &dra7xx_mcasp_hwmod_class,
+ .clkdm_name = "l4per2_clkdm",
+ .main_clk = "mcasp6_ahclkx_mux",
+ .flags = HWMOD_SWSUP_SIDLE_ACT,
+ .prcm = {
+ .omap4 = {
+ .clkctrl_offs = DRA7XX_CM_L4PER2_MCASP6_CLKCTRL_OFFSET,
+ .context_offs = DRA7XX_RM_L4PER2_MCASP6_CONTEXT_OFFSET,
+ .modulemode = MODULEMODE_SWCTRL,
+ },
+ },
+};
+
/*
* 'mmc' class
*
@@ -3246,6 +3312,14 @@ static struct omap_hwmod_ocp_if dra7xx_l3_main_1__sha0 = {
.user = OCP_USER_MPU | OCP_USER_SDMA,
};
+/* l4_per2 -> mcasp2 */
+static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp2 = {
+ .master = &dra7xx_l4_per2_hwmod,
+ .slave = &dra7xx_mcasp2_hwmod,
+ .clk = "l3_iclk_div",
+ .user = OCP_USER_MPU,
+};
+
/* l4_per2 -> mcasp3 */
static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp3 = {
.master = &dra7xx_l4_per2_hwmod,
@@ -3254,6 +3328,14 @@ static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp3 = {
.user = OCP_USER_MPU | OCP_USER_SDMA,
};
+/* l4_per2 -> mcasp6 */
+static struct omap_hwmod_ocp_if dra7xx_l4_per2__mcasp6 = {
+ .master = &dra7xx_l4_per2_hwmod,
+ .slave = &dra7xx_mcasp6_hwmod,
+ .clk = "l3_iclk_div",
+ .user = OCP_USER_MPU | OCP_USER_SDMA,
+};
+
static struct omap_hwmod_addr_space dra7xx_elm_addrs[] = {
{
.pa_start = 0x48078000,
@@ -3354,6 +3436,45 @@ static struct omap_hwmod_ocp_if dra7xx_l3_main_1__gpmc = {
.user = OCP_USER_MPU | OCP_USER_SDMA,
};
+static struct omap_hwmod_addr_space dra7xx_gpu_addrs[] = {
+ {
+ .name = "klio",
+ .pa_start = 0x56000000,
+ .pa_end = 0x56001fff,
+ },
+ {
+ .name = "hydra2",
+ .pa_start = 0x56004000,
+ .pa_end = 0x56004fff,
+ },
+ {
+ .name = "klio_0",
+ .pa_start = 0x56008000,
+ .pa_end = 0x56009fff,
+ },
+ {
+ .name = "klio_1",
+ .pa_start = 0x5600c000,
+ .pa_end = 0x5600dfff,
+ },
+ {
+ .name = "klio_hl",
+ .pa_start = 0x5600fe00,
+ .pa_end = 0x5600ffff,
+ .flags = ADDR_TYPE_RT
+ },
+ { }
+};
+
+/* l3_main_1 -> gpu */
+static struct omap_hwmod_ocp_if dra7xx_l3_main_1__gpu = {
+ .master = &dra7xx_l3_main_1_hwmod,
+ .slave = &dra7xx_gpu_hwmod,
+ .clk = "l3_iclk_div",
+ .addr = dra7xx_gpu_addrs,
+ .user = OCP_USER_MPU | OCP_USER_SDMA,
+};
+
static struct omap_hwmod_addr_space dra7xx_hdq1w_addrs[] = {
{
.pa_start = 0x480b2000,
@@ -4106,7 +4227,9 @@ static struct omap_hwmod_ocp_if *dra7xx_hwmod_ocp_ifs[] __initdata = {
&dra7xx_l3_main_1__hdmi,
&dra7xx_l3_main_1__aes,
&dra7xx_l3_main_1__sha0,
+ &dra7xx_l4_per2__mcasp2,
&dra7xx_l4_per2__mcasp3,
+ &dra7xx_l4_per2__mcasp6,
&dra7xx_l4_per1__elm,
&dra7xx_l4_wkup__gpio1,
&dra7xx_l4_per1__gpio2,
@@ -4117,6 +4240,7 @@ static struct omap_hwmod_ocp_if *dra7xx_hwmod_ocp_ifs[] __initdata = {
&dra7xx_l4_per1__gpio7,
&dra7xx_l4_per1__gpio8,
&dra7xx_l3_main_1__gpmc,
+ &dra7xx_l3_main_1__gpu,
&dra7xx_l4_per1__hdq1w,
&dra7xx_l4_per1__i2c1,
&dra7xx_l4_per1__i2c2,
diff --git a/drivers/clk/ti/clk-7xx.c b/drivers/clk/ti/clk-7xx.c
index 3c218280e23..470da754743 100644
--- a/drivers/clk/ti/clk-7xx.c
+++ b/drivers/clk/ti/clk-7xx.c
@@ -22,7 +22,7 @@
#define DRA7_DPLL_DSP_GFCLK_NOMFREQ 600000000
#define DRA7_DPLL_EVE_GCLK_NOMFREQ 400000000
-#define DRA7_ATL_DEFFREQ 5644800
+#define DRA7_ATL_DEFFREQ 11289600
static struct ti_dt_clk dra7xx_clks[] = {
DT_CLK(NULL, "atl_clkin0_ck", "atl_clkin0_ck"),
diff --git a/drivers/gpio/gpio-mcp23s08.c b/drivers/gpio/gpio-mcp23s08.c
index aa379971d70..e9178de8ec1 100644
--- a/drivers/gpio/gpio-mcp23s08.c
+++ b/drivers/gpio/gpio-mcp23s08.c
@@ -584,6 +584,7 @@ static int mcp23s08_probe_one(struct mcp23s08 *mcp, struct device *dev,
unsigned base, unsigned pullups)
{
int status;
+ u32 init_dir = 0, init_val = 0;
bool mirror = false;
mutex_init(&mcp->lock);
@@ -672,6 +673,14 @@ static int mcp23s08_probe_one(struct mcp23s08 *mcp, struct device *dev,
if (status < 0)
goto fail;
+ if (of_property_read_u32(mcp->chip.of_node,
+ "init-dir", &init_dir) == 0)
+ status = mcp->ops->write(mcp, MCP_IODIR, init_dir);
+
+ if (of_property_read_u32(mcp->chip.of_node,
+ "init-val", &init_val) == 0)
+ status = mcp->ops->write(mcp, MCP_OLAT, init_val);
+
status = mcp->ops->read_regs(mcp, 0, mcp->cache, ARRAY_SIZE(mcp->cache));
if (status < 0)
goto fail;
diff --git a/drivers/gpu/drm/drm_prime.c b/drivers/gpu/drm/drm_prime.c
index 56805c39c90..b87deb725d4 100644
--- a/drivers/gpu/drm/drm_prime.c
+++ b/drivers/gpu/drm/drm_prime.c
@@ -573,11 +573,12 @@ int drm_prime_handle_to_fd_ioctl(struct drm_device *dev, void *data,
return -ENOSYS;
/* check flags are valid */
- if (args->flags & ~DRM_CLOEXEC)
+ if (args->flags & ~(DRM_CLOEXEC|DRM_RDWR))
return -EINVAL;
- /* we only want to pass DRM_CLOEXEC which is == O_CLOEXEC */
- flags = args->flags & DRM_CLOEXEC;
+ /* we only want to pass DRM_CLOEXEC which is == O_CLOEXEC
+ and DRM_RDWR which is O_RDWR */
+ flags = args->flags & (DRM_CLOEXEC|DRM_RDWR);
return dev->driver->prime_handle_to_fd(dev, file_priv,
args->handle, flags, &args->fd);
diff --git a/drivers/gpu/drm/omapdrm/omap_drv.c b/drivers/gpu/drm/omapdrm/omap_drv.c
index 15e4fe5d0d7..7cb1c8f4c7a 100644
--- a/drivers/gpu/drm/omapdrm/omap_drv.c
+++ b/drivers/gpu/drm/omapdrm/omap_drv.c
@@ -439,12 +439,12 @@ static int ioctl_gem_info(struct drm_device *dev, void *data,
}
static const struct drm_ioctl_desc ioctls[DRM_COMMAND_END - DRM_COMMAND_BASE] = {
- DRM_IOCTL_DEF_DRV(OMAP_GET_PARAM, ioctl_get_param, DRM_UNLOCKED|DRM_AUTH),
+ DRM_IOCTL_DEF_DRV(OMAP_GET_PARAM, ioctl_get_param, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW),
DRM_IOCTL_DEF_DRV(OMAP_SET_PARAM, ioctl_set_param, DRM_UNLOCKED|DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY),
- DRM_IOCTL_DEF_DRV(OMAP_GEM_NEW, ioctl_gem_new, DRM_UNLOCKED|DRM_AUTH),
- DRM_IOCTL_DEF_DRV(OMAP_GEM_CPU_PREP, ioctl_gem_cpu_prep, DRM_UNLOCKED|DRM_AUTH),
- DRM_IOCTL_DEF_DRV(OMAP_GEM_CPU_FINI, ioctl_gem_cpu_fini, DRM_UNLOCKED|DRM_AUTH),
- DRM_IOCTL_DEF_DRV(OMAP_GEM_INFO, ioctl_gem_info, DRM_UNLOCKED|DRM_AUTH),
+ DRM_IOCTL_DEF_DRV(OMAP_GEM_NEW, ioctl_gem_new, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW),
+ DRM_IOCTL_DEF_DRV(OMAP_GEM_CPU_PREP, ioctl_gem_cpu_prep, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW),
+ DRM_IOCTL_DEF_DRV(OMAP_GEM_CPU_FINI, ioctl_gem_cpu_fini, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW),
+ DRM_IOCTL_DEF_DRV(OMAP_GEM_INFO, ioctl_gem_info, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW),
};
/*
@@ -646,7 +646,7 @@ static const struct file_operations omapdriver_fops = {
static struct drm_driver omap_drm_driver = {
.driver_features =
- DRIVER_HAVE_IRQ | DRIVER_MODESET | DRIVER_GEM | DRIVER_PRIME,
+ DRIVER_HAVE_IRQ | DRIVER_MODESET | DRIVER_GEM | DRIVER_PRIME | DRIVER_RENDER,
.load = dev_load,
.unload = dev_unload,
.open = dev_open,
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
index 07e9e82029d..1ce12346f6f 100644
--- a/drivers/input/touchscreen/Kconfig
+++ b/drivers/input/touchscreen/Kconfig
@@ -609,6 +609,19 @@ config TOUCHSCREEN_WM831X
To compile this driver as a module, choose M here: the
module will be called wm831x-ts.
+
+config TOUCHSCREEN_LDC3001
+ tristate "LDC3001 ROIC based Touch screen controllers"
+ depends on I2C
+ help
+ Say Y here if you have a LDC3001 plus LGD STM32F103
+ MCU based touchscreen controller.
+
+ If unsure, say N.
+
+ To compile this driver as a module, choose M here: the
+ module will be called ldc3001_ts.
+
config TOUCHSCREEN_WM97XX
tristate "Support for WM97xx AC97 touchscreen controllers"
depends on AC97_BUS
diff --git a/drivers/input/touchscreen/Makefile b/drivers/input/touchscreen/Makefile
index 62801f21334..10f25bead11 100644
--- a/drivers/input/touchscreen/Makefile
+++ b/drivers/input/touchscreen/Makefile
@@ -37,6 +37,7 @@ obj-$(CONFIG_TOUCHSCREEN_ILI210X) += ili210x.o
obj-$(CONFIG_TOUCHSCREEN_INEXIO) += inexio.o
obj-$(CONFIG_TOUCHSCREEN_INTEL_MID) += intel-mid-touch.o
obj-$(CONFIG_TOUCHSCREEN_LPC32XX) += lpc32xx_ts.o
+obj-$(CONFIG_TOUCHSCREEN_LDC3001) += ldc3001_ts.o
obj-$(CONFIG_TOUCHSCREEN_MAX11801) += max11801_ts.o
obj-$(CONFIG_TOUCHSCREEN_MC13783) += mc13783_ts.o
obj-$(CONFIG_TOUCHSCREEN_MCS5000) += mcs5000_ts.o
diff --git a/drivers/input/touchscreen/ldc3001_ts.c b/drivers/input/touchscreen/ldc3001_ts.c
new file mode 100644
index 00000000000..f6a83972b81
--- /dev/null
+++ b/drivers/input/touchscreen/ldc3001_ts.c
@@ -0,0 +1,526 @@
+/*
+ * LDC3001 Touch Screen driver
+ *
+ * Copyright (C) 2013-2014 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation version 2.
+ *
+ * This program is distributed "as is" WITHOUT ANY WARRANTY of any
+ * kind, whether express or implied; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+
+#include <linux/module.h>
+#include <linux/init.h>
+#include <linux/kthread.h>
+#include <linux/firmware.h>
+#include <linux/i2c.h>
+#include <linux/input/mt.h>
+#include <linux/interrupt.h>
+#include <linux/slab.h>
+#include <linux/gpio.h>
+#include <linux/of.h>
+#include <linux/of_gpio.h>
+#include <linux/of_device.h>
+#include <linux/of_irq.h>
+#include <linux/regmap.h>
+
+
+#define TSC_READ_LEN 1
+#define DEFAULT_READ_LEN 2 /* corresponds to the ID bit-field */
+#define TP_READ_SIZE 3 /* co-ordinates size in bytes */
+#define MAX_PAYLOAD_SIZE(mt_points) ((mt_points * TP_READ_SIZE) \
+ + DEFAULT_READ_LEN)
+
+/* MACROS to decode data from the i2c messages */
+#define GET_X_POS(msg) (((((msg)[0] >> 4) & 0x0f) << 8) \
+ | ((msg)[1]))
+
+#define GET_Y_POS(msg) ((((msg)[0] & 0x0f)) << 8 | ((msg)[2]))
+
+#define GET_INDICES(msg) ((((msg)[0] & 0x00ff) \
+ | (((msg)[1]) & 0x30) << 4))
+
+/* i2c offsets for the tsc */
+#define TOUCH_DATA_ADDR 0xFA
+#define TOUCH_DATA_COUNT_ADDR 0xF5
+
+/* defines a touch */
+struct touch_point {
+ u8 touch_id;
+ u8 state;
+ int x_pos;
+ int y_pos;
+};
+
+/* platform data for the LGPhilips LDC3001 TSC */
+struct ldc3001_platform_data {
+ unsigned int x_size;
+ unsigned int y_size;
+ unsigned int num_mt_slots;
+};
+
+/* each client has this additional data */
+struct ldc3001_data {
+ struct i2c_client *client;
+ struct input_dev *input_dev;
+ char phys[64]; /* device physical location */
+ const struct ldc3001_platform_data *pdata;
+ unsigned int irq;
+ u8 *message;
+ struct touch_point *tps;
+ u8 cur_index;
+ u16 tp_fields;
+};
+
+static ssize_t ldc3001_fw_version_show(struct device *dev,
+ struct device_attribute *attr, char *buf) {
+ /* FIXME: read TLC to get TS version */
+ return scnprintf(buf, PAGE_SIZE, "1.04\n");
+
+}
+static DEVICE_ATTR(fw_version, S_IRUGO, ldc3001_fw_version_show, NULL);
+
+static struct attribute *ldc3001_attrs[] = {
+ &dev_attr_fw_version.attr,
+ NULL
+};
+
+static const struct attribute_group ldc3001_attr_group = {
+ .attrs = ldc3001_attrs,
+};
+
+#ifdef CONFIG_PM_SLEEP
+static int ldc3001_i2c_ts_suspend(struct device *dev)
+{
+ dev_dbg(dev, "%s\n", __func__);
+ return 0;
+}
+
+static int ldc3001_i2c_ts_resume(struct device *dev)
+{
+ dev_dbg(dev, "%s\n", __func__);
+
+ return 0;
+}
+
+static SIMPLE_DEV_PM_OPS(ldc3001_dev_pm_ops,
+ ldc3001_i2c_ts_suspend, ldc3001_i2c_ts_resume);
+
+#endif
+
+#ifdef DEBUG
+static void dump_touch_data(u8 *message, int len)
+{
+
+ print_hex_dump(KERN_ERR, " \t", DUMP_PREFIX_NONE, 16, 1,
+ message, len, false);
+}
+
+static u16 get_touch_fields(struct ldc3001_data *data)
+{
+ u8 *message = data->message;
+
+ pr_info("Bit field is %u\n", GET_INDICES(message));
+ return GET_INDICES(message);
+}
+
+/*
+ * index - index to the read message
+ * touch_idx - touch_idx tracking id
+ */
+
+static void get_tpos(struct ldc3001_data *data, u8 index, u8 touch_idx)
+{
+ u16 x, y;
+ u8 *message = &data->message[index*TP_READ_SIZE + DEFAULT_READ_LEN];
+
+ data->tps[index].x_pos = GET_X_POS(msg);
+ data->tps[index].y_pos = GET_Y_POS(msg);
+ data->tps[index].touch_id = touch_idx;
+
+ pr_info("x %x\n", data->tps[index].x_pos);
+ pr_info("y %x\n", data->tps[index].y_pos);
+
+}
+
+static int ldc3001_write_reg(struct i2c_client *client, u16 reg, u16 len,
+ const void *val)
+{
+ u8 *buf;
+ size_t count;
+ int ret;
+
+ count = len + 2;
+ buf = kmalloc(count, GFP_KERNEL);
+ if (!buf)
+ return -ENOMEM;
+
+ /* pack the 16 bit reg value to byte data */
+ buf[0] = reg & 0xff;
+ buf[1] = (reg >> 8) & 0xff;
+ memcpy(&buf[2], val, len);
+
+ ret = i2c_master_send(client, buf, count);
+ if (ret == count) {
+ ret = 0;
+ } else {
+ if (ret >= 0)
+ ret = -EIO;
+ dev_err(&client->dev, "%s: i2c send failed (%d)\n",
+ __func__, ret);
+ }
+
+ kfree(buf);
+ return ret;
+}
+#endif
+
+static int ldc3001_read_reg(struct i2c_client *client,
+ u16 reg, u16 len, void *val)
+{
+ struct i2c_msg xfer[2];
+ u8 buf[2];
+ int ret;
+
+ /* pack the 16 bit reg value to byte data */
+ buf[0] = reg & 0xff;
+ buf[1] = (reg >> 8) & 0xff;
+
+ /* Write register */
+ xfer[0].addr = client->addr;
+ xfer[0].flags = 0;
+ xfer[0].len = 2;
+ xfer[0].buf = buf;
+
+ /* Read data */
+ xfer[1].addr = client->addr;
+ xfer[1].flags = I2C_M_RD;
+ xfer[1].len = len;
+ xfer[1].buf = val;
+
+ ret = i2c_transfer(client->adapter, xfer, 2);
+ if (ret == 2) {
+ ret = 0;
+ } else {
+ if (ret >= 0)
+ ret = -EIO;
+ dev_err(&client->dev, "%s: i2c transfer failed (%d)\n",
+ __func__, ret);
+ }
+
+ return ret;
+}
+
+
+static int ldc3001_ts_read_data(struct ldc3001_data *data, int len)
+{
+ int error;
+ struct i2c_client *client = data->client;
+
+ error = ldc3001_read_reg(client, TOUCH_DATA_ADDR, len, data->message);
+ if (error)
+ dev_err(&client->dev, "i2c_read failed %x\n", error);
+
+ return error;
+}
+
+static int ldc3001_ts_read_len(struct ldc3001_data *data)
+{
+ int error;
+ u8 len = 0;
+
+ struct i2c_client *client = data->client;
+
+ error = ldc3001_read_reg(client, TOUCH_DATA_COUNT_ADDR, TSC_READ_LEN,
+ &len);
+ if (error)
+ dev_err(&client->dev, "i2c_read len failed %x\n", error);
+
+ return len;
+}
+
+
+
+static void ldc3001_input_touchevent(struct ldc3001_data *data)
+{
+ u16 touch_index = 0;
+ u8 i, msg_index = 0;
+ int num_mt_slots = data->pdata->num_mt_slots;
+ struct input_dev *input_dev = data->input_dev;
+ u8 *message = data->message;
+
+ /* get valid touch ids */
+ touch_index = GET_INDICES(message);
+
+ /* loop through all tps to process changes */
+ for (i = 0; i < num_mt_slots; i++) {
+
+ /* tracking id has a touch event */
+ if (touch_index & (1 << i)) {
+ message =
+ &data->message[msg_index * TP_READ_SIZE + DEFAULT_READ_LEN];
+
+ /* decode the x and y co-ordinates */
+ data->tps[i].x_pos = GET_X_POS(message);
+ data->tps[i].y_pos = GET_Y_POS(message);
+
+ /* update state and move to the next message */
+ data->tps[i].state = 1;
+ msg_index++;
+
+ /* report the touch event */
+ input_mt_slot(input_dev, i);
+ input_mt_report_slot_state(input_dev,
+ MT_TOOL_FINGER, data->tps[i].state);
+ input_report_abs(input_dev, ABS_MT_POSITION_X,
+ data->tps[i].x_pos);
+ input_report_abs(input_dev, ABS_MT_POSITION_Y,
+ data->tps[i].y_pos);
+
+ } else if (data->tps[i].state == 1) {
+ /* this is a pen release event */
+ data->tps[i].state = 0;
+ input_mt_slot(input_dev, i);
+ input_mt_report_slot_state(input_dev, MT_TOOL_FINGER,
+ data->tps[i].state);
+ }
+ }
+
+ /* send sync event */
+ input_mt_report_pointer_emulation(data->input_dev, false);
+ input_sync(input_dev);
+}
+
+
+static irqreturn_t ldc3001_ts_interrupt(int irq, void *dev_id)
+{
+ struct ldc3001_data *data = (struct ldc3001_data *)dev_id;
+ int read_len;
+
+ /* FIXME: need to figure out why this is required */
+ disable_irq_nosync(irq);
+
+ read_len = ldc3001_ts_read_len(data);
+
+ /* reset touchid fields */
+ data->message[0] = 0x0;
+ data->message[1] = 0x0;
+
+ if (read_len > DEFAULT_READ_LEN)
+ /* fill the message array with data read from tsc */
+ ldc3001_ts_read_data(data, read_len);
+
+ ldc3001_input_touchevent(data);
+ enable_irq(irq);
+
+ return IRQ_HANDLED;
+}
+
+int ldc3001_of_populate(struct i2c_client *client,
+ struct ldc3001_platform_data *pdata)
+{
+ struct device_node *node = client->dev.of_node;
+ unsigned int val;
+ int ret = -EINVAL;
+
+ ret = of_property_read_u32(node, "res-x", &val);
+ if (ret)
+ goto error;
+ pdata->x_size = val;
+
+ ret = of_property_read_u32(node, "res-y", &val);
+ if (ret)
+ goto error;
+
+ pdata->y_size = val;
+
+ ret = of_property_read_u32(node, "max-touch-points", &val);
+ if (ret)
+ goto error;
+
+ pdata->num_mt_slots = val;
+
+error:
+ return ret;
+}
+
+static const struct of_device_id ldc3001_dt_ids[] = {
+ { .compatible = "lgphilips,ldc3001"},
+ { /* sentinel */ }
+};
+
+static int ldc3001_probe(struct i2c_client *client,
+ const struct i2c_device_id *idev_id)
+{
+ struct device_node *node = client->dev.of_node;
+ struct ldc3001_platform_data *pdata;
+ struct ldc3001_data *data;
+ struct input_dev *input_dev;
+ const struct of_device_id *match;
+ int error;
+
+ match = of_match_device(of_match_ptr(ldc3001_dt_ids), &client->dev);
+ if (match) {
+ pdata = devm_kzalloc(&client->dev,
+ sizeof(struct ldc3001_platform_data), GFP_KERNEL);
+ if (!pdata)
+ return -ENOMEM;
+
+ /* get dt values to populate platform data */
+ error = ldc3001_of_populate(client, pdata);
+ if (error)
+ return -EINVAL;
+
+ } else {
+ pdata = client->dev.platform_data;
+ if (!pdata) {
+ dev_err(&client->dev, "platform data not populated\n");
+ return -EINVAL;
+ }
+ }
+
+ data = devm_kzalloc(&client->dev,
+ sizeof(struct ldc3001_data), GFP_KERNEL);
+
+ if (!data) {
+ error = -ENOMEM;
+ goto err_exit;
+ }
+
+ data->tps = devm_kzalloc(&client->dev,
+ sizeof(struct touch_point) * pdata->num_mt_slots, GFP_KERNEL);
+
+ if (!data->tps) {
+ error = -ENOMEM;
+ goto err_exit;
+ }
+
+ data->message = devm_kzalloc(&client->dev,
+ (sizeof(u8) * MAX_PAYLOAD_SIZE(pdata->num_mt_slots)),
+ GFP_KERNEL);
+ if (!data->message) {
+ error = -ENOMEM;
+ goto err_exit;
+ }
+
+ input_dev = devm_input_allocate_device(&client->dev);
+
+ if (!input_dev) {
+ error = -ENOMEM;
+ goto err_exit;
+ }
+
+ input_dev->name = "LDC 3001 TouchScreen Controller";
+
+ snprintf(data->phys, sizeof(data->phys), "i2c-%u-%04x/input0",
+ client->adapter->nr, client->addr);
+
+ input_dev->phys = data->phys;
+
+ input_dev->dev.parent = &client->dev;
+ data->client = client;
+ data->input_dev = input_dev;
+ data->pdata = pdata;
+
+ input_set_drvdata(input_dev, data);
+ i2c_set_clientdata(client, data);
+
+ /*TODO: Need to poke the tlc chip to read revision of the TSC chip */
+
+ __set_bit(EV_ABS, input_dev->evbit);
+ __set_bit(EV_KEY, input_dev->evbit);
+ __set_bit(BTN_TOUCH, input_dev->keybit);
+
+ /* For single touch */
+ input_set_abs_params(input_dev, ABS_X,
+ 0, pdata->x_size, 0, 0);
+ input_set_abs_params(input_dev, ABS_Y,
+ 0, pdata->y_size, 0, 0);
+
+ /* For multi touch */
+ error = input_mt_init_slots(input_dev, pdata->num_mt_slots, 0);
+
+ if (error)
+ goto err_exit;
+
+ input_set_abs_params(input_dev, ABS_MT_POSITION_X,
+ 0, pdata->x_size, 0, 0);
+ input_set_abs_params(input_dev, ABS_MT_POSITION_Y,
+ 0, pdata->y_size, 0, 0);
+
+ data->irq = irq_of_parse_and_map(node, 0);
+ if (data->irq) {
+ error = devm_request_threaded_irq(&client->dev, data->irq,
+ NULL, ldc3001_ts_interrupt,
+ IRQF_ONESHOT | IRQF_TRIGGER_HIGH,
+ dev_name(&client->dev), data);
+
+ if (error) {
+ dev_err(&client->dev, "failed to register interrupt\n");
+ goto cleanup_exit;
+ }
+ } else {
+ dev_err(&client->dev,
+ "failed registering irq = %d\n", data->irq);
+ error = -EINVAL;
+ goto cleanup_exit;
+ }
+
+ error = input_register_device(input_dev);
+ if (error)
+ input_free_device(input_dev);
+ else {
+ error = sysfs_create_group(&client->dev.kobj,
+ &ldc3001_attr_group);
+ return error;
+ }
+
+cleanup_exit:
+ input_mt_destroy_slots(input_dev);
+err_exit:
+ return error;
+}
+
+static int ldc3001_remove(struct i2c_client *client)
+{
+
+ struct ldc3001_data *data =
+ (struct ldc3001_data *)i2c_get_clientdata(client);
+ struct input_dev *input_dev = data->input_dev;
+
+ sysfs_remove_group(&client->dev.kobj, &ldc3001_attr_group);
+ input_unregister_device(input_dev);
+
+ return 0;
+}
+
+static const struct i2c_device_id ldc3001_i2c_id[] = {
+ {"ldc3001", 0},
+ { }
+};
+
+MODULE_DEVICE_TABLE(i2c, ldc3001_i2c_id);
+
+static struct i2c_driver ldc3001_i2c_driver = {
+ .driver = {
+ .owner = THIS_MODULE,
+ .name = "ldc3001",
+ .pm = &ldc3001_dev_pm_ops,
+ .of_match_table = ldc3001_dt_ids,
+ },
+ .probe = ldc3001_probe,
+ .remove = ldc3001_remove,
+ .id_table = ldc3001_i2c_id,
+};
+
+module_i2c_driver(ldc3001_i2c_driver);
+
+MODULE_AUTHOR("Subramaniam Chanderashekarapuram <subramaniam.ca@ti.com>");
+MODULE_DESCRIPTION("LDC3001 I2C Touchscreen driver");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("i2c:ldc3001");
diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
index f3e78e1fb4d..aee0f2d4c31 100644
--- a/drivers/media/platform/Kconfig
+++ b/drivers/media/platform/Kconfig
@@ -255,6 +255,17 @@ config VIDEO_TI_VPDMA_HELPER
it provides a mem2mem, mem2device, device2mem DMA specifically
for transfering and manipulating video data.
+config VIDEO_TI_VPDMA_LOAD_FW
+ bool "Load VPDMA F/W from Kernel"
+ depends on VIDEO_TI_VPDMA_HELPER
+ default n
+ ---help---
+ TI SoC's Video Port Direct Memory Access module
+ needs a firmware to be loaded. This can be loaded from
+ user space via udev event or it can be loaded from kernel itself
+ Say 'y' if you want the Video devices to be initialized early
+ in the bootup sequence.
+
menuconfig V4L_TEST_DRIVERS
bool "Media test drivers"
depends on MEDIA_CAMERA_SUPPORT
diff --git a/drivers/media/radio/Kconfig b/drivers/media/radio/Kconfig
index 192f36f2f4a..984042de4bb 100644
--- a/drivers/media/radio/Kconfig
+++ b/drivers/media/radio/Kconfig
@@ -19,6 +19,22 @@ config RADIO_SI470X
bool "Silicon Labs Si470x FM Radio Receiver support"
depends on VIDEO_V4L2
+config DRA7XX_RADIO_HELPER
+ tristate "TI DRA7xx Radio Helper/Configuration Driver"
+ depends on VIDEO_V4L2
+ default y
+ ---help---
+ This is a helper/configuration driver for radio integration for
+ the dra7xx based socs. This driver does basic initialization
+ and configuration required to use the radio.
+
+ Say Y here if you want to enable Radio helper for DRA7xx
+ platform.
+
+ To compile this driver as a module, choose M here: the
+ module will be called dra7xx-radio.
+
+
source "drivers/media/radio/si470x/Kconfig"
config RADIO_SI4713
diff --git a/drivers/media/radio/Makefile b/drivers/media/radio/Makefile
index 120e791199b..61a38bee025 100644
--- a/drivers/media/radio/Makefile
+++ b/drivers/media/radio/Makefile
@@ -33,6 +33,7 @@ obj-$(CONFIG_RADIO_WL1273) += radio-wl1273.o
obj-$(CONFIG_RADIO_WL128X) += wl128x/
obj-$(CONFIG_RADIO_TEA575X) += tea575x.o
obj-$(CONFIG_USB_RAREMONO) += radio-raremono.o
+obj-$(CONFIG_DRA7XX_RADIO_HELPER) += dra7xx_radio.o dra7xx_radio_helper.o
shark2-objs := radio-shark2.o radio-tea5777.o
diff --git a/drivers/media/radio/dra7xx_radio.c b/drivers/media/radio/dra7xx_radio.c
new file mode 100644
index 00000000000..bf12b15f971
--- /dev/null
+++ b/drivers/media/radio/dra7xx_radio.c
@@ -0,0 +1,106 @@
+/*
+ * TI DRA7xx Radio Helper Driver
+ *
+ * Copyright (C) 2013-2014 Texas Instruments Incorporated - http://www.ti.com/
+ * Author: Ravikumar Kattekola <rk@ti.com>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed "as is" WITHOUT ANY WARRANTY of any
+ * kind, whether express or implied; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <linux/of.h>
+#include <linux/init.h>
+#include <linux/gpio.h>
+#include <linux/module.h>
+#include <linux/clk.h>
+#include <linux/platform_device.h>
+#include <linux/pm_runtime.h>
+#include <linux/of_gpio.h>
+#include <linux/of_platform.h>
+
+struct dra7_radio_priv {
+ int gpio;
+};
+
+static int dra7xx_radio_probe(struct platform_device *pdev)
+{
+ struct device_node *np = pdev->dev.of_node;
+ struct device_node *child = NULL;
+ struct dra7_radio_priv *priv;
+ int ret = 0;
+
+ if (!np)
+ return -ENODEV;
+
+ if (of_find_property(np, "gpios", NULL)) {
+ priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL);
+ if (!priv)
+ return -ENOMEM;
+ dev_set_drvdata(&pdev->dev, priv);
+
+ priv->gpio = of_get_gpio(np, 0);
+ if (gpio_is_valid(priv->gpio)) {
+ ret = gpio_request_one(priv->gpio, GPIOF_OUT_INIT_HIGH,
+ "xref3_clk");
+ } else {
+ dev_err(&pdev->dev, "failed to parse gpio\n");
+ return -EINVAL;
+ }
+ }
+ do {
+ child = of_get_next_available_child(np, child);
+ if (child && of_device_is_compatible(child,
+ "ti,dra7xx_radio_subdev"))
+ of_platform_device_create(child, NULL, &pdev->dev);
+ } while (child);
+
+ pr_info("DRA7xx Radio probe done\n");
+ return ret;
+}
+
+static int dra7xx_radio_remove(struct platform_device *pdev)
+{
+ struct device_node *np = pdev->dev.of_node;
+ struct device_node *child = NULL;
+ struct dra7_radio_priv *priv;
+
+ if (of_find_property(np, "gpios", NULL)) {
+ priv = dev_get_drvdata(&pdev->dev);
+ gpio_free(priv->gpio);
+ }
+ do {
+ child = of_get_next_available_child(np, child);
+ if (child && of_device_is_compatible(child,
+ "ti,dra7xx_radio_subdev"))
+ of_find_device_by_node(child);
+ } while (child);
+ return 0;
+}
+
+static const struct of_device_id dra7xx_radio_of_match[] = {
+ { .compatible = "ti,dra7xx_radio", },
+ { /* sentinel */ },
+};
+MODULE_DEVICE_TABLE(of, dra7xx_radio_of_match);
+
+static struct platform_driver dra7xx_radio_driver = {
+ .driver = {
+ .of_match_table = of_match_ptr(dra7xx_radio_of_match),
+ .name = "dra7xx_radio",
+ .owner = THIS_MODULE,
+ },
+ .probe = dra7xx_radio_probe,
+ .remove = dra7xx_radio_remove,
+};
+
+module_platform_driver(dra7xx_radio_driver);
+
+MODULE_DESCRIPTION("DRA7xx Radio Helper Driver");
+MODULE_LICENSE("GPL v2");
+MODULE_ALIAS("platform:dra7xx_radio");
+MODULE_AUTHOR("Texas Instrument Inc.");
diff --git a/drivers/media/radio/dra7xx_radio_helper.c b/drivers/media/radio/dra7xx_radio_helper.c
new file mode 100644
index 00000000000..e193a2efc9a
--- /dev/null
+++ b/drivers/media/radio/dra7xx_radio_helper.c
@@ -0,0 +1,63 @@
+/*
+ * TI DRA7xx Radio Helper Sub-driver
+ *
+ * Copyright (C) 2013-2014 Texas Instruments Incorporated - http://www.ti.com/
+ * Author: Ravikumar Kattekola <rk@ti.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed "as is" WITHOUT ANY WARRANTY of any
+ * kind, whether express or implied; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <linux/of.h>
+#include <linux/init.h>
+#include <linux/gpio.h>
+#include <linux/module.h>
+#include <linux/clk.h>
+#include <linux/platform_device.h>
+#include <linux/pm_runtime.h>
+#include <linux/of_gpio.h>
+#include <linux/of_platform.h>
+
+static int dra7xx_radio_subdev_probe(struct platform_device *pdev)
+{
+ pm_runtime_enable(&pdev->dev);
+ pm_runtime_get_sync(&pdev->dev);
+ pr_info("%s: Probe done\n", pdev->name);
+ return 0;
+}
+
+static int dra7xx_radio_subdev_remove(struct platform_device *pdev)
+{
+ pm_runtime_put_sync(&pdev->dev);
+ pm_runtime_disable(&pdev->dev);
+ return 0;
+}
+
+static const struct of_device_id dra7xx_radio_subdev_of_match[] = {
+ { .compatible = "ti,dra7xx_radio_subdev", },
+ { /* sentinel */ },
+};
+MODULE_DEVICE_TABLE(of, dra7xx_radio_subdev_of_match);
+
+static struct platform_driver dra7xx_radio_subdev_driver = {
+ .driver = {
+ .of_match_table = of_match_ptr(dra7xx_radio_subdev_of_match),
+ .name = "dra7xx_radio_subdev",
+ .owner = THIS_MODULE,
+ },
+ .probe = dra7xx_radio_subdev_probe,
+ .remove = dra7xx_radio_subdev_remove,
+};
+
+module_platform_driver(dra7xx_radio_subdev_driver);
+
+MODULE_DESCRIPTION("DRA7xx Radio Helper Sub-driver");
+MODULE_LICENSE("GPL v2");
+MODULE_ALIAS("platform:dra7xx_radio_helper");
+MODULE_AUTHOR("Texas Instrument Inc.");
diff --git a/drivers/power/Kconfig b/drivers/power/Kconfig
index 5c4fe1670fc..8b07dc1aca5 100644
--- a/drivers/power/Kconfig
+++ b/drivers/power/Kconfig
@@ -395,3 +395,4 @@ endif # POWER_SUPPLY
source "drivers/power/avs/Kconfig"
source "drivers/power/voltdm/Kconfig"
+source "drivers/power/coproc/Kconfig"
diff --git a/drivers/power/Makefile b/drivers/power/Makefile
index 3d47072191d..a76fa2a1eda 100644
--- a/drivers/power/Makefile
+++ b/drivers/power/Makefile
@@ -59,3 +59,4 @@ obj-$(CONFIG_CHARGER_SMB347) += smb347-charger.o
obj-$(CONFIG_CHARGER_TPS65090) += tps65090-charger.o
obj-$(CONFIG_POWER_RESET) += reset/
obj-$(CONFIG_VOLTAGE_DOMAIN) += voltdm/
+obj-$(CONFIG_TI_COPROC) += coproc/
diff --git a/drivers/power/coproc/Kconfig b/drivers/power/coproc/Kconfig
new file mode 100644
index 00000000000..ec0e3076800
--- /dev/null
+++ b/drivers/power/coproc/Kconfig
@@ -0,0 +1,7 @@
+config TI_COPROC
+ tristate "TI Co-processor driversupport"
+ depends on VOLTAGE_DOMAIN_OMAP
+ help
+ TI Coprocessor driver helps initialize a coprocessor to
+ a particular Operating performance point.
+
diff --git a/drivers/power/coproc/Makefile b/drivers/power/coproc/Makefile
new file mode 100644
index 00000000000..5e393a5f403
--- /dev/null
+++ b/drivers/power/coproc/Makefile
@@ -0,0 +1,2 @@
+#Texas Instruments co-processor init driver
+obj-${CONFIG_TI_COPROC} += ti-coproc.o
diff --git a/drivers/power/coproc/ti-coproc.c b/drivers/power/coproc/ti-coproc.c
new file mode 100644
index 00000000000..3795d36e105
--- /dev/null
+++ b/drivers/power/coproc/ti-coproc.c
@@ -0,0 +1,229 @@
+/*
+ * OMAP SoC COPROC driver
+ *
+ * Copyright (C) 2014 Texas Instruments Incorporated - http://www.ti.com/
+ * Carlos Hernandez <ceh@ti.com>
+ * Nishanth Menon <nm@ti.com>
+ * Ravikumar Kattekola <rk@ti.com>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed "as is" WITHOUT ANY WARRANTY of any
+ * kind, whether express or implied; without even the implied warranty
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+#include <linux/io.h>
+#include <linux/slab.h>
+#include <linux/mutex.h>
+#include <linux/suspend.h>
+#include <linux/pm_opp.h>
+#include <linux/of.h>
+#include <linux/platform_device.h>
+#include <linux/regulator/consumer.h>
+#include <linux/module.h>
+#include <linux/clk.h>
+#include <linux/pm_voltage_domain.h>
+
+/**
+ * struct coproc_data - Co processor private data
+ * @profile: profile specific for this device
+ * @dev: device pointer
+ * @: for this device
+ * @stat: my current statistics
+ * @dev_clk: my device clk
+ * @dpll_clk: my dpll clk
+ * @nb: my notifier block
+ */
+struct coproc_data {
+ struct device *dev;
+ struct clk *dev_clk;
+ struct clk *dpll_clk;
+ struct notifier_block *clk_nb;
+};
+
+/**
+ * DOC:
+ * clock-names should be defined in dts file, e.g.
+ * coproc {
+ *
+ * compatible = "ti,coproc";
+ * clocks = <&dpll_iva_m2_ck>, <&dpll_iva_ck>;
+ * clock-names = "fclk", "dpll";
+ * clock-target-frequency = <532000000>;
+ * operating-points = <
+ * 388200 1055000
+ * 500000 1150000
+ * 532000 1250000
+ * >;
+ * coproc-voltdm = <&voltdm_ivahd>;
+ * voltage-tolerance = <1>;
+ *
+ * };
+ */
+#define DEV_CLK_NAME "fclk"
+#define DPLL_CLK_NAME "dpll"
+
+static int coproc_probe(struct platform_device *pdev)
+{
+ struct coproc_data *d;
+ unsigned int voltage_latency;
+ u32 target_freq = 0;
+ int err = 0;
+ struct device *dev = &pdev->dev;
+ struct device_node *np = of_node_get(dev->of_node);
+ bool noset_dpll_as_rate;
+
+ dev_info(dev, "probe\n");
+
+ of_property_read_u32(np, "clock-target-frequency", &target_freq);
+ if (!target_freq) {
+ dev_err(dev, "%s: Invalid/no target frequency found in dt.\n",
+ __func__);
+ return -EINVAL;
+ }
+
+ noset_dpll_as_rate = of_property_read_bool(np, "noset-dpll-rate");
+
+ d = devm_kzalloc(dev, sizeof(*d), GFP_KERNEL);
+ if (d == NULL) {
+ dev_err(dev, "%s: Cannot allocate memory.\n", __func__);
+ err = -ENOMEM;
+ goto out;
+ }
+ platform_set_drvdata(pdev, d);
+
+ d->dpll_clk = devm_clk_get(dev, DPLL_CLK_NAME);
+ if (IS_ERR(d->dpll_clk)) {
+ err = PTR_ERR(d->dpll_clk);
+ dev_err(dev, "%s: Cannot get dpll clk(%d).\n", __func__, err);
+ d->dpll_clk = NULL;
+ }
+
+ d->dev_clk = devm_clk_get(dev, DEV_CLK_NAME);
+ if (IS_ERR(d->dev_clk)) {
+ err = PTR_ERR(d->dpll_clk);
+ dev_err(dev, "%s: Cannot get func clk(%d).\n", __func__, err);
+ goto out;
+ }
+
+ if (noset_dpll_as_rate)
+ d->dpll_clk = NULL;
+
+ err = of_init_opp_table(dev);
+ if (err) {
+ dev_err(dev, "%s: Cannot initialize opp table(%d).\n", __func__,
+ err);
+ goto out;
+ }
+ d->dev = dev;
+
+ /* Register voltage domain notifier */
+ d->clk_nb = of_pm_voltdm_notifier_register(dev, np, d->dev_clk,
+ "coproc",
+ &voltage_latency);
+ if (IS_ERR(d->clk_nb)) {
+ err = PTR_ERR(d->clk_nb);
+ /* defer probe if regulator is not yet registered */
+ if (err == -EPROBE_DEFER) {
+ dev_err(dev,
+ "coproc clock notifier not ready, retry\n");
+ } else {
+ dev_err(dev,
+ "Failed to register coproc clk notifier: %d\n",
+ err);
+ }
+ goto out;
+ }
+
+ if (target_freq) {
+ if (d->dpll_clk) {
+ err = clk_set_rate(d->dpll_clk, target_freq);
+ if (err) {
+ dev_err(dev, "%s: Cannot set dpll clock rate(%d).\n",
+ __func__, err);
+ goto out;
+ }
+ }
+
+ err = clk_set_rate(d->dev_clk, target_freq);
+ if (err) {
+ dev_err(dev, "%s: Cannot set func clock rate(%d).\n",
+ __func__, err);
+ goto out;
+ }
+ }
+
+ /* All good.. */
+ goto out;
+
+out:
+ dev_info(dev, "%s result=%d", __func__, err);
+ return err;
+}
+
+static int coproc_remove(struct platform_device *pdev)
+{
+ struct coproc_data *d = platform_get_drvdata(pdev);
+ struct device *dev = &pdev->dev;
+
+ dev_info(dev, "remove\n");
+
+ of_pm_voltdm_notifier_unregister(d->clk_nb);
+
+ dev_info(dev, "%s Removed\n", __func__);
+ return 0;
+}
+
+/**
+ * coproc_suspend() - dummy hook for suspend
+ * @dev: device pointer
+ *
+ * Return: 0
+ */
+static int coproc_suspend(struct device *dev)
+{
+ dev_info(dev, "suspend\n");
+ return 0;
+}
+
+/**
+ * coproc_resume() - dummy hook for resume
+ * @dev: device pointer
+ *
+ * Return: 0
+ */
+static int coproc_resume(struct device *dev)
+{
+ dev_info(dev, "resume\n");
+ return 0;
+}
+
+/* Device power management hooks */
+static SIMPLE_DEV_PM_OPS(coproc_pm,
+ coproc_suspend,
+ coproc_resume);
+
+static struct of_device_id of_coproc_match[] = {
+ {.compatible = "ti,coproc"},
+ {},
+};
+
+MODULE_DEVICE_TABLE(of, of_coproc_match);
+
+static struct platform_driver coproc_driver = {
+ .probe = coproc_probe,
+ .remove = coproc_remove,
+ .driver = {
+ .name = "coproc",
+ .owner = THIS_MODULE,
+ .of_match_table = of_match_ptr(of_coproc_match),
+ .pm = &coproc_pm,
+ },
+};
+module_platform_driver(coproc_driver);
+
+MODULE_LICENSE("GPL v2");
+MODULE_DESCRIPTION("OMAP Co-processor Driver");
+MODULE_AUTHOR("Texas Instruments Inc.");
diff --git a/drivers/usb/dwc3/debugfs.c b/drivers/usb/dwc3/debugfs.c
index 9ac37fe1b6a..0cc5a015451 100644
--- a/drivers/usb/dwc3/debugfs.c
+++ b/drivers/usb/dwc3/debugfs.c
@@ -27,6 +27,7 @@
#include <linux/uaccess.h>
#include <linux/usb/ch9.h>
+#include <linux/usb/drd.h>
#include "core.h"
#include "gadget.h"
@@ -412,7 +413,15 @@ static ssize_t dwc3_mode_write(struct file *file,
if (mode) {
spin_lock_irqsave(&dwc->lock, flags);
- dwc3_set_mode(dwc, mode);
+ if (mode & DWC3_GCTL_PRTCAP_HOST) {
+ dwc3_omap_usbvbus_id_handler(dwc->dev->parent,
+ OMAP_DWC3_ID_GROUND);
+ mode = 0;
+ } else if (mode & DWC3_GCTL_PRTCAP_DEVICE) {
+ dwc3_omap_usbvbus_id_handler(dwc->dev->parent,
+ OMAP_DWC3_VBUS_VALID);
+ mode = 1;
+ }
spin_unlock_irqrestore(&dwc->lock, flags);
}
return count;
diff --git a/drivers/usb/dwc3/dwc3-omap.c b/drivers/usb/dwc3/dwc3-omap.c
index 4ccdef7333c..96b4c46cbbd 100644
--- a/drivers/usb/dwc3/dwc3-omap.c
+++ b/drivers/usb/dwc3/dwc3-omap.c
@@ -32,6 +32,7 @@
#include <linux/regulator/consumer.h>
#include <linux/usb/otg.h>
+#include <linux/usb/drd.h>
/*
* All these registers belong to OMAP's Wrapper around the
@@ -137,13 +138,6 @@ struct dwc3_omap {
struct regulator *vbus_reg;
};
-enum omap_dwc3_vbus_id_status {
- OMAP_DWC3_ID_FLOAT,
- OMAP_DWC3_ID_GROUND,
- OMAP_DWC3_VBUS_OFF,
- OMAP_DWC3_VBUS_VALID,
-};
-
static inline u32 dwc3_omap_readl(void __iomem *base, u32 offset)
{
return readl(base + offset);
@@ -278,6 +272,28 @@ static void dwc3_omap_set_mailbox(struct dwc3_omap *omap,
}
}
+int dwc3_omap_usbvbus_id_handler(struct device *dev,
+ enum omap_dwc3_vbus_id_status status)
+{
+ struct dwc3_omap *omap;
+ struct platform_device *pdev;
+
+ if (!dev)
+ return -ENODEV;
+
+ dev_dbg(omap->dev, "VBUS Connect\n");
+
+ pdev = to_platform_device(dev);
+ omap = platform_get_drvdata(pdev);
+ if (!omap)
+ return -ENODEV;
+
+ dwc3_omap_set_mailbox(omap, status);
+
+ return 0;
+}
+EXPORT_SYMBOL(dwc3_omap_usbvbus_id_handler);
+
static irqreturn_t dwc3_omap_interrupt(int irq, void *_omap)
{
struct dwc3_omap *omap = _omap;
diff --git a/firmware/Makefile b/firmware/Makefile
index cbb09ce9730..bcee66d9eeb 100644
--- a/firmware/Makefile
+++ b/firmware/Makefile
@@ -96,6 +96,9 @@ fw-shipped-$(CONFIG_SND_WAVEFRONT) += yamaha/yss225_registers.bin
fw-shipped-$(CONFIG_TEHUTI) += tehuti/bdx.bin
fw-shipped-$(CONFIG_TIGON3) += tigon/tg3.bin tigon/tg3_tso.bin \
tigon/tg3_tso5.bin
+
+fw-shipped-$(CONFIG_VIDEO_TI_VPDMA_LOAD_FW) += vpdma-1b8.bin
+
fw-shipped-$(CONFIG_TYPHOON) += 3com/typhoon.bin
fw-shipped-$(CONFIG_USB_EMI26) += emi26/loader.fw emi26/firmware.fw \
emi26/bitstream.fw
diff --git a/firmware/vpdma-1b8.bin.ihex b/firmware/vpdma-1b8.bin.ihex
new file mode 100644
index 00000000000..ddf307dd3e2
--- /dev/null
+++ b/firmware/vpdma-1b8.bin.ihex
@@ -0,0 +1,252 @@
+:10000000064B408007680749064A005102441F0812
+:10001000064A003102441E080449418004484080D9
+:100020000680000C01D002C01681010000441C08AB
+:1000300001441D080649E809064818080185064AD2
+:1000400001002181219400441B080044180806483F
+:10005000010000441A080648001C0044190806491B
+:1000600000000144250801442408064818080144FA
+:100070002108004420080648E809068001000144E0
+:100080002308004422080144260806480080004452
+:100090002708064834000044428006480000004417
+:1000A000F880064801000044F980064B1808864B8A
+:1000B000200807BC0FB80004064801000044FF8078
+:1000C0000648FFFF0044F8800648FFFF0044F9801F
+:1000D000064800000044580800445D0800445E08DB
+:1000E00000445F0800445C08004457090044590973
+:1000F00000445A0900445B0900445C0900445D095E
+:1001000000445E0900445F09004460090044660938
+:10011000004465090648D1000044E18006486A02AF
+:100120000044E2800648F9050044E3800648B8012F
+:100130000044FC800044FE800004064800000044A7
+:10014000540900445509004456090448FE8006AA93
+:1001500008000649010001940044FF80864B5909BC
+:10016000C483FE800F480ECC064B01800648080071
+:1001700004A8FE80308307480689F0011685F00147
+:1001800001C881450649FF010144FD800FB90649B8
+:1001900042802183074A26867F00CCCC0448E08039
+:1001A00000E00648FFFF0044F880064B59093483FD
+:1001B000FE80064A00000245044AFE8002446108AF
+:1001C00026A9050001446808064B32081383074836
+:1001D0000044630826A9080001446708064B4080D4
+:1001E000138307680044650807480044660836839F
+:1001F000030007480680F9FF03CC064AD70502E052
+:100200000648000000446408064B300826A9050093
+:100210001383076800445D0800445C080045064BF2
+:1002200033081383074800445F080648510100E083
+:1002300004486708064B43803083074932CC044AA0
+:10024000FE80064B6709238306481F010045864B45
+:100250004280C48367080F4836830800004506487B
+:100260007F008045064B0180348367080648FFFF06
+:1002700000450448540912C806488001044955093C
+:10028000018C0045068C80000044FC80064B34083D
+:1002900026AA05003283064800000045064897015B
+:1002A00000E0044AFE80064B6709238306481801D4
+:1002B0000045044AFE8006490800064B018012AA48
+:1002C0002383064801010045864B0F080F4A0DD8CD
+:1002D000064800010045864B07080F4A06D8064825
+:1002E000FA0100450044FF8025C00448FE8006A8AE
+:1002F0000500064B34080383044964080145064B96
+:100300003108038304495D08014506480080004424
+:10031000FA80064A000002449108044AFE80064B17
+:100320006709238306481801068C008000450648AB
+:100330009A0000E00649005106480001108C004474
+:100340001F08044A660802441D080244D18004497B
+:10035000650801441C080144D08004486308064B2A
+:100360004380348367080749018603D80244620842
+:1003700006C016800000064A00000244620804829B
+:10038000640802446408044A640806A81000004493
+:100390001B08004418080044D280064801000044AD
+:1003A000D380064A000004495C0802442508014441
+:1003B00024080449910807C806490000014491082F
+:1003C00004495C0805C00449920802CC04495D0850
+:1003D0000244210801442008064900000144920813
+:1003E00004495F0802442308014422080244260805
+:1003F0000649008001442708864B18080FBE0448B0
+:100400006208064B4380348367080045864B20080A
+:100410000448D480004465080448D5800044660838
+:100420000FB806483400064B42800449670813831E
+:100430000045044AFE80064B6709238306491801DC
+:10044000168D0040014536830800004536830800BC
+:1004500004485D080045064B43803483670807491C
+:100460000448FE80064B6709038336831800014564
+:1004700004496708064B40801383044865080065FB
+:100480000448660800450448FE8006A80500064B9F
+:1004900034080383044964080145064B310803838B
+:1004A00004495D0801450648970100E006480080C0
+:1004B0000044FA80044AFE80064B670923830648FD
+:1004C0001801068C00C0004506489A0000E0004470
+:1004D000EE8000E4044AFE80064B018026A9080055
+:1004E00001446708064B4080138307680044650891
+:1004F0000768004466080768076800446208074800
+:10050000004460080244610826AA05000244680805
+:10051000064B30082383076800445C0807680044E2
+:100520005D08076800445E08076800445F080748E4
+:1005300000446408004463080448640807CC044885
+:100540005E08004463080648180100E0044B5D089B
+:100550000649F5FF368307000748109406490A004C
+:1005600010840CC80649010010840BC8108403C80D
+:100570000648C40200E006488E0400E00648DC029B
+:1005800000E00648CC0300E036830800044A5D081A
+:10059000024536830800044A640802450448FE8088
+:1005A00006490800864B018010A888830648FB0195
+:1005B000804506489A0000E0044A640806CC0648D4
+:1005C0008A0300E006487C0300E0044A64082680B1
+:1005D000FFFFF8C8044B5D08B68306000F48068885
+:1005E000004000448F080F480688008000445409EA
+:1005F000B68307000F480688FF01044AFE800649BB
+:100600000800864B018012AAA88380450649030092
+:100610009097C68307000F4A05D8B68306000F4A95
+:1006200004D808C006489B0300E09097C6830200E8
+:100630000F49F8D8044AFE80864B0180064908001D
+:1006400012AAA8830649FE0181450144FF8007BD27
+:10065000064903009097C68302000F49168D00805B
+:10066000814536830800044954090DC80649030032
+:100670009097C68307000F491689008004488F08A9
+:10068000108D01448F0806480100044A5609209441
+:10069000044A5509028E02445509044A5F0823851D
+:1006A00004D8044B5C0803445D0804498F0805C85E
+:1006B00007B81689000001448F0807B83683080080
+:1006C00006480100044A56092681010001445609E2
+:1006D000044964081681FEFF0144640823C8044AE3
+:1006E0005F08328505D803445D080648A60200E08D
+:1006F00004485C0800445D0804485D0804495F083C
+:100700000680080000449208108404D806480100BE
+:100710000044910804485E080649FFFF1094004415
+:10072000630834C004485C0800445D0804485E085F
+:10073000004463082BC0B68306000F4801D810C0E0
+:10074000044AFE80864B01800649080012AAA8834D
+:100750000648FE0180450044FF8036831000B0C08B
+:1007600004486808064B34080383044964080145BB
+:10077000064B3108038304495D0801450AC0064859
+:10078000100000448E080648670200E00648180181
+:1007900000E006489A0000E0044A640803CC0648DA
+:1007A000500400E0044B5D08B68306000F4869C89A
+:1007B000064A000004495C08024425080144240854
+:1007C00004495D08024421080144200804495F08E7
+:1007D00002442308014422080244260806490080F6
+:1007E00001442708044AFE8006490800064B0180A0
+:1007F00012AA238306480101064900800045864B62
+:100800000F080F4A59D80648000106490040004524
+:10081000864B07080F4A50D8064901010144FD8064
+:100820000044FF800648FC010045044B5D0807BCFE
+:10083000B68306000F680F49168AFF011689000467
+:1008400003C80680010002C006480100864B4280B2
+:10085000C483670806493E00218181450449640834
+:1008600001850144640806A80800308202445D083E
+:10087000064B2008864B080807B90F490F490F4956
+:100880000AC004485D08068008000449640816810F
+:10089000FFFF06C834C004495F08218526D814C06C
+:1008A0000144640804495E08064AFFFF2196024499
+:1008B00063080648180100E0064800800044FA80FA
+:1008C0000648FF800044F98004486808064B340855
+:1008D0000383044964080145064B31080383044936
+:1008E0005D08014506489A0000E004485C080044A1
+:1008F0005D08044A5E0804496408D2C8E5C0064B96
+:10090000310834836808004500445D0836830300DD
+:100910000145014464080648A60200E0044AFE803E
+:10092000044B5D0836830600074806880F000BC895
+:1009300006490100108421C810842DC810843BC8CA
+:1009400010843FC87BC036830100044AFE800748FC
+:100950000688FF01864B9308C6830100C0830F49B8
+:10096000068C00800044FD8007B8864B4280064814
+:10097000080002AAA88381456FC0044AFE80064988
+:100980000800864BF080A88336830100074806885C
+:10099000FF01804561C0044AFE8006490800864B7D
+:1009A000428012A9C183138307480688FF0126826B
+:1009B0004700824551C03683FAFF07480044FB8058
+:1009C0004BC0044AFE8006490800864B018012AAEB
+:1009D000A8833683010007480688FF01804506ABDF
+:1009E00008003683070007491689008009CC368342
+:1009F000FCFF0749168A008008C8168A004005CC0B
+:100A000004485D080449640832C00648FE01804578
+:100A10000044FF80044B5D083683080076C03683AF
+:100A2000010007480688FF01068C00803683F9FF25
+:100A30000044FD8007B83683080067C01084EFC803
+:100A4000108418C8108422C810843EC8108453C86B
+:100A50001084064AC90502E004485D0806800800C3
+:100A6000044964081681FFFF04865F0863D8064ABC
+:100A7000BE0502E00649FCFF3683010007680688D0
+:100A8000FF010044EE800648850500E0064A0000AC
+:100A900002449108044AFE8006490800864B4080C3
+:100AA00012AAA883064806000387076880650768BE
+:100AB0008065C683010007488045064A000002445D
+:100AC00064080648DC0000E0076907490648FF01A2
+:100AD000108906480000864B7E0880658165806528
+:100AE00080658065806580658065864B7E080FBC6B
+:100AF000368301000AC03683FEFF07480688FF01DF
+:100B00000044FA803683040000C00448640806806C
+:100B1000FFFF15C80044640804495F0803445D08EA
+:100B2000318403D80648A60200E004485C0800446B
+:100B30005D08F8C004485C0800445D081FC0044814
+:100B40005E080044630804495F0803445D0831847B
+:100B500003D80648180100E004485C0800445D081A
+:100B60000648180100E004485C0800445D08044899
+:100B70005E080044630806489A0000E0064B31080E
+:100B800034836808004536830300014506489A000F
+:100B900000E00448FE8006490800864B018010A84A
+:100BA00088830648FD01804506489A0000E0044A13
+:100BB0006708064B4080328307680649FFFF90971D
+:100BC000074A268A010002C8C68F00800F4A06889D
+:100BD000010003C80649F8FF12960448FE80064942
+:100BE0000800864B018010A888838245064A9A0037
+:100BF00002E006489A0000E000000000000000004B
+:100C00000000001C01001000020000000031005133
+:100C100000000000000000000000000000000000D4
+:100C200000000000000000000000000000000000C4
+:100C3000001000104000FF110000001200124000E0
+:100C4000FF130000001400144000FF150000001600
+:100C500000164000FF170000001800184000FF19A0
+:100C60000000001A001A4000FF1B0000001C001CBE
+:100C70004000FF1D0000001E001E4000FF1F00007E
+:100C80000000000000000000000000000000000064
+:100C90000000000000000000000000000000000054
+:100CA0000000000000000000000000000000000044
+:100CB0000000000000000000000000000000000034
+:100CC0000000000000000000000000000000000420
+:100CD0000000000000000000000000000000000014
+:100CE0000000000000000000000000000000000004
+:100CF000000000000000000D0100000002000300E1
+:100D00000400050006000700080009000A000B00A7
+:100D10000C000D000E000F00100011001400130055
+:100D2000150016001700180019001A001B001C00FF
+:100D30001D001F00200021002A002B002C002A008B
+:100D40002B002C0022002200220022002200220080
+:100D50002200220022002200220022002200220083
+:100D6000220022002300230023002300230023006D
+:100D7000230023002300230023002300230023005B
+:100D8000230023003A003A003A003A003A003A00C1
+:100D90003A003A003A003A003A003A003A003A0083
+:100DA0003A003A003B003B003B003B003B003B006D
+:100DB0003B003B003B003B003B003B003B003B005B
+:100DC0003B003B00240025002200230024002200D9
+:100DD00026002600260026002600260026002600E3
+:100DE00026002600260026002600260026002600D3
+:100DF00027002700270027002700270027002700BB
+:100E000027002700270027002700270027002700AA
+:100E10003C003C003C003C003C003C003C003C00F2
+:100E20003C003C003C003C003C003C003C003C00E2
+:100E30003D003D003D003D003D003D003D003D00CA
+:100E40003D003D003D003D003D003D003D003D00BA
+:100E50002800290026002700280026002D00300049
+:100E600031002E002F0032003300350012001E002A
+:100E70003700360039003800000000000000000094
+:100E80000000000000000000000000000000000062
+:100E90000000000000000000000000000000000052
+:100EA0000000000000000000000000000000000042
+:100EB0000000000000000000000000000000000032
+:100EC0000000000000000000000000000000000022
+:100ED0000000000000000000000000000000000012
+:100EE0000000000000000000000000000000000002
+:100EF00000000000000000000000000000000000F2
+:100F000000000000000000000000000000000000E1
+:100F100000000000000000000000000000000000D1
+:100F200000000000000000000000000000000000C1
+:100F300000000000000000000000000000000000B1
+:100F400000000000000000000000000000000000A1
+:100F50000000000000000000000000000000000091
+:100F60000000000000000000000000000000000081
+:100F70000000000000000000000000000000000071
+:100F80000000000000000000000000000000000061
+:100F90000000000000000000000000000000000051
+:020FA00000004F
+:00000001FF
diff --git a/include/linux/usb/drd.h b/include/linux/usb/drd.h
index 71c64dcd93e..6a9c3ce5635 100644
--- a/include/linux/usb/drd.h
+++ b/include/linux/usb/drd.h
@@ -22,6 +22,13 @@ struct usb_drd_gadget {
struct usb_drd_setup *gadget_setup;
};
+enum omap_dwc3_vbus_id_status {
+ OMAP_DWC3_ID_FLOAT,
+ OMAP_DWC3_ID_GROUND,
+ OMAP_DWC3_VBUS_OFF,
+ OMAP_DWC3_VBUS_VALID,
+};
+
#define DRD_UNREGISTERED 0x0
#define DRD_DEVICE_REGISTERED 0x1
#define DRD_HOST_REGISTERED 0x2
@@ -45,6 +52,8 @@ int usb_drd_stop_hcd(struct device *parent);
int usb_drd_start_udc(struct device *parent);
int usb_drd_stop_udc(struct device *parent);
int usb_drd_get_state(struct device *parent);
+int dwc3_omap_usbvbus_id_handler(struct device *dev,
+ enum omap_dwc3_vbus_id_status status);
#else
static inline int usb_drd_release(struct device *parent)
{ return 0; }
diff --git a/include/uapi/drm/drm.h b/include/uapi/drm/drm.h
index b06c8ed6870..a66f948f6bb 100644
--- a/include/uapi/drm/drm.h
+++ b/include/uapi/drm/drm.h
@@ -644,6 +644,7 @@ struct drm_set_client_cap {
};
#define DRM_CLOEXEC O_CLOEXEC
+#define DRM_RDWR O_RDWR
struct drm_prime_handle {
__u32 handle;
diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h
index d26bcff63cf..57d04c77084 100644
--- a/include/uapi/linux/videodev2.h
+++ b/include/uapi/linux/videodev2.h
@@ -69,7 +69,7 @@
* Common stuff for both V4L1 and V4L2
* Moved from videodev.h
*/
-#define VIDEO_MAX_FRAME 32
+#define VIDEO_MAX_FRAME 128
#define VIDEO_MAX_PLANES 8
/*
diff --git a/sound/soc/davinci/davinci-evm.c b/sound/soc/davinci/davinci-evm.c
index b9010c91b4e..8605d4b0f6e 100644
--- a/sound/soc/davinci/davinci-evm.c
+++ b/sound/soc/davinci/davinci-evm.c
@@ -218,6 +218,12 @@ static int evm_aic3x_init(struct snd_soc_pcm_runtime *rtd)
snd_soc_dapm_nc_pin(&codec->dapm, "HPLCOM");
snd_soc_dapm_nc_pin(&codec->dapm, "HPRCOM");
+ /* Minimize artifacts as much as possible if can be afforded */
+ if (of_find_property(np, "ti,always-on", NULL))
+ rtd->pmdown_time = INT_MAX;
+ else
+ rtd->pmdown_time = 0;
+
return 0;
}
diff --git a/sound/soc/davinci/davinci-mcasp.c b/sound/soc/davinci/davinci-mcasp.c
index eeb51f9d478..0036ef372ef 100644
--- a/sound/soc/davinci/davinci-mcasp.c
+++ b/sound/soc/davinci/davinci-mcasp.c
@@ -1288,6 +1288,24 @@ static struct davinci_mcasp_pdata *davinci_mcasp_set_pdata_from_of(
pdata->serial_dir = of_serial_dir;
}
+ if (pdata->version == MCASP_VERSION_4) {
+ for (i = 0; i < pdata->num_serializer; i++) {
+ if (pdata->serial_dir[i] == TX_MODE) {
+ pdata->tx_dma_offset =
+ DAVINCI_MCASP_TXBUF_REG(i);
+ break;
+ }
+ }
+
+ for (i = 0; i < pdata->num_serializer; i++) {
+ if (pdata->serial_dir[i] == RX_MODE) {
+ pdata->rx_dma_offset =
+ DAVINCI_MCASP_RXBUF_REG(i);
+ break;
+ }
+ }
+ }
+
ret = of_property_match_string(np, "dma-names", "tx");
if (ret < 0)
goto nodata;
diff --git a/sound/soc/davinci/davinci-mcasp.h b/sound/soc/davinci/davinci-mcasp.h
index cbba1daa25e..3d778463968 100644
--- a/sound/soc/davinci/davinci-mcasp.h
+++ b/sound/soc/davinci/davinci-mcasp.h
@@ -85,9 +85,9 @@
(n << 2))
/* Transmit Buffer for Serializer n */
-#define DAVINCI_MCASP_TXBUF_REG 0x200
+#define DAVINCI_MCASP_TXBUF_REG(n) (0x200 + (n << 2))
/* Receive Buffer for Serializer n */
-#define DAVINCI_MCASP_RXBUF_REG 0x280
+#define DAVINCI_MCASP_RXBUF_REG(n) (0x280 + (n << 2))
/* McASP FIFO Registers */
#define DAVINCI_MCASP_V2_AFIFO_BASE (0x1010)
diff --git a/ti_config_fragments/baseport.cfg b/ti_config_fragments/baseport.cfg
index feae1f43edd..fabd82a4f8b 100644
--- a/ti_config_fragments/baseport.cfg
+++ b/ti_config_fragments/baseport.cfg
@@ -15,7 +15,8 @@ CONFIG_CRYPTO_DEV_OMAP_DES=y
CONFIG_CRYPTO_USER_API_HASH=y
CONFIG_CRYPTO_USER_API_SKCIPHER=y
-CONFIG_PREEMPT_VOLUNTARY=y
+# CONFIG_PREEMPT_VOLUNTARY is not set
+CONFIG_PREEMPT=y
CONFIG_JUMP_LABEL=y
diff --git a/ti_config_fragments/connectivity.cfg b/ti_config_fragments/connectivity.cfg
index e0be9666c71..1745a20cd5d 100644
--- a/ti_config_fragments/connectivity.cfg
+++ b/ti_config_fragments/connectivity.cfg
@@ -88,6 +88,7 @@ CONFIG_TOUCHSCREEN_ATMEL_MXT=y
CONFIG_MFD_TI_AM335X_TSCADC=y
CONFIG_TOUCHSCREEN_TI_AM335X_TSC=y
CONFIG_TOUCHSCREEN_PIXCIR=m
+CONFIG_TOUCHSCREEN_LDC3001=y
# Buttons
CONFIG_INPUT_PALMAS_PWRBUTTON=y
diff --git a/ti_config_fragments/linux_config.sh b/ti_config_fragments/linux_config.sh
new file mode 100755
index 00000000000..886c9cd088e
--- /dev/null
+++ b/ti_config_fragments/linux_config.sh
@@ -0,0 +1,12 @@
+export ARCH=arm
+
+./scripts/kconfig/merge_config.sh \
+arch/arm/configs/omap2plus_defconfig \
+ti_config_fragments/dra7_only.cfg \
+ti_config_fragments/baseport.cfg \
+ti_config_fragments/power.cfg \
+ti_config_fragments/connectivity.cfg \
+ti_config_fragments/ipc.cfg \
+ti_config_fragments/audio_display.cfg \
+ti_config_fragments/radio.cfg \
+ti_config_fragments/wlan.cfg \
diff --git a/ti_config_fragments/radio.cfg b/ti_config_fragments/radio.cfg
new file mode 100644
index 00000000000..c87a56bf967
--- /dev/null
+++ b/ti_config_fragments/radio.cfg
@@ -0,0 +1,9 @@
+##################################################
+# TI DSP-based Radio Configs
+##################################################
+
+CONFIG_MEDIA_SUPPORT=y
+CONFIG_VIDEO_V4L2=y
+CONFIG_MEDIA_RADIO_SUPPORT=y
+CONFIG_RADIO_ADAPTERS=y
+CONFIG_DRA7XX_RADIO_HELPER=y