Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e2fe825f authored by Gilad Broner's avatar Gilad Broner Committed by Gerrit - the friendly Code Review server
Browse files

Migrate mpq demux driver from kernel 3.10 to 3.18



This change migrates all the relevant files consisting of the mpq
demux driver and its plugins, including the addition of TSPPv1 HW driver.
The snapshot is taken as of msm-3.10, commit 1d1c751febc370 ("Merge "msm:
kgsl: Set IOMMU context and AHB offsets for A5xx"")
In addition, a few minor code changes are introduced to resolve some
checkpatch warnings, typos and other style issues.
TSPPv2 driver and its mpq demux plugins which were only relevant for
8092 and are now obsolete, were dropped.

Change-Id: I074d199939c686597b83cd5a60a7e87d029d3fc5
Signed-off-by: default avatarGilad Broner <gbroner@codeaurora.org>
parent cd35eb97
Loading
Loading
Loading
Loading
+93 −0
Original line number Diff line number Diff line
TSPP Driver

For information on the TSPP driver, please refer to the TSPP driver
documentation: Documentation/arm/msm/tspp.txt.

The devicetree representation of the TSPP block should be:

Required properties:

- compatible: "qcom,msm_tspp"
- reg: physical memory base addresses and sizes for the following:
	TSIF0, TSIF1, TSPP and TSPP_BAM.
- reg-names: names of the memory regions.
- interrupts: represents IRQ numbers for the following:
	TSIF_TSPP_IRQ, TSIF0_IRQ, TSIF1_IRQ, TSIF_BAM_IRQ.
- interrupt-names: TSPP, TSIF and BAM interrupt names.
- pinctrl-names: the names of the pinctrl states that are used by the driver to
	configure the TLMM pins. The allowed states are:
	disabled - both tsif inputs are not used
	tsif0-mode1 - only tsif0 is active in mode 1 (no sync signal)
	tsif0-mode2 - only tsif0 is used in mode 2 (with sync signal)
	tsif1-mode1 - only tsif1 is active in mode 1 (no sync signal)
	tsif1-mode2 - only tsif1 is used in mode 2 (with sync signal)
	dual-tsif-mode1 - both tsif0 and tsif1 are active, in mode 1
	dual-tsif-mode1 - both tsif0 and tsif1 are active, in mode 2
- pinctrl-#: a list of pinctrl phandles for the different pinctrl states. Refer
	to "Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt" for
	the pinctrl handles definitions. Each pinctrl-# corresponds to the
	respective state name that appears under pinctrl-state list.
	Note that when switching from one state to another, any pins in
	the old state which do not appear in the new state are automatically
	disabled by the pinctrl framework.

Optional properties:

- vdd_cx-supply: Reference to the regulator that supplies the CX rail.
	Some hardware platforms (e.g. 8974-v2) require the voltage of the rail
	supplying power to the TSIF hardware block to be elevated before
	enabling the TSIF clocks.
- Refer to "Documentation/devicetree/bindings/arm/msm/msm_bus.txt" for
	the below optional properties:
	- qcom,msm-bus,name
	- qcom,msm-bus,num-cases
	- qcom,msm-bus,num-paths
	- qcom,msm-bus,vectors-KBps

Example (for 8974 platform, avaialble at msm8974.dtsi):

	tspp: msm_tspp@f99d8000 {
		compatible = "qcom,msm_tspp";
		reg = <0xf99d8000 0x1000>, /* MSM_TSIF0_PHYS */
		      <0xf99d9000 0x1000>, /* MSM_TSIF1_PHYS */
		      <0xf99da000 0x1000>, /* MSM_TSPP_PHYS  */
		      <0xf99c4000 0x14000>; /* MSM_TSPP_BAM_PHYS */
		reg-names = "MSM_TSIF0_PHYS",
			"MSM_TSIF1_PHYS",
			"MSM_TSPP_PHYS",
			"MSM_TSPP_BAM_PHYS";
		interrupts = <0 153 0>, /* TSIF_TSPP_IRQ */
			<0 151 0>, /* TSIF0_IRQ */
			<0 152 0>, /* TSIF1_IRQ */
			<0 154 0>; /* TSIF_BAM_IRQ */
		interrupt-names = "TSIF_TSPP_IRQ",
			"TSIF0_IRQ",
			"TSIF1_IRQ",
			"TSIF_BAM_IRQ";

		pinctrl-names = "disabled",
			"tsif0-mode1", "tsif0-mode2",
			"tsif1-mode1", "tsif1-mode2",
			"dual-tsif-mode1", "dual-tsif-mode2";

		pinctrl-0 = <>;				/* disabled */
		pinctrl-1 = <&tsif0_signals_active>;	/* tsif0-mode1 */
		pinctrl-2 = <&tsif0_signals_active
			&tsif0_sync_active>;		/* tsif0-mode2 */
		pinctrl-3 = <&tsif1_signals_active>;	/* tsif1-mode1 */
		pinctrl-4 = <&tsif1_signals_active
			&tsif1_sync_active>;		/* tsif1-mode2 */
		pinctrl-5 = <&tsif0_signals_active
			&tsif1_signals_active>;		/* dual-tsif-mode1 */
		pinctrl-6 = <&tsif0_signals_active
			&tsif0_sync_active
			&tsif1_signals_active
			&tsif1_sync_active>;		/* dual-tsif-mode2 */

		qcom,msm-bus,name = "tsif";
		qcom,msm-bus,num-cases = <2>;
		qcom,msm-bus,num-paths = <1>;
		qcom,msm-bus,vectors-KBps =
				<82 512 0 0>, /* No vote */
				<82 512 12288 24576>; /* Max. bandwidth, 2xTSIF, each max of 96Mbps */
	};
+2 −0
Original line number Diff line number Diff line
@@ -40,3 +40,5 @@ config MSMB_CAMERA_DEBUG
if MSMB_CAMERA
source "drivers/media/platform/msm/camera_v2/Kconfig"
endif # MSMB_CAMERA
source "drivers/media/platform/msm/dvb/Kconfig"
source "drivers/media/platform/msm/broadcast/Kconfig"
+2 −0
Original line number Diff line number Diff line
@@ -3,4 +3,6 @@
# based on V4L2.
#
obj-$(CONFIG_MSM_VIDC_V4L2) += vidc/
obj-y += broadcast/
obj-$(CONFIG_DVB_MPQ) += dvb/
obj-$(CONFIG_MSMB_CAMERA) += camera_v2/
+14 −0
Original line number Diff line number Diff line
#
# MSM Broadcast subsystem drivers
#

config TSPP
	depends on ARCH_MSM
	tristate "TSPP (Transport Stream Packet Processor) Support"
	---help---
	Transport Stream Packet Processor v1 is used to offload the
	processing of MPEG transport streams from the main processor.
	It is used to process incoming transport streams from TSIF
	to supports use-cases such as transport stream live play
	and recording.
	This can also be compiled as a loadable module.
+4 −0
Original line number Diff line number Diff line
#
# Makefile for MSM Broadcast subsystem drivers.
#
obj-$(CONFIG_TSPP) += tspp.o
Loading