MSM TSC - Transport Stream Controller

TSC is a HW unit for routing MPEG-2 Transport Stream packets and communicating
with the CAM over Common Interface.
For information on the TSC driver, please refer to the TSC driver
documentation: Documentation/arm/msm/tsc.txt.

The device tree representation of the TSPP2 block should be:

Required properties:

- compatible: "qcom,msm-tsc"
- reg: physical memory base addresses and sizes for the TSC.
- reg-names: name of the memory region: "tsc-base".
- interrupts: represents IRQ numbers for the TSC.
- interrupt-names: TSC interrupt names: "cam-cmd" and "card-detect".
- qcom,iommu-group: phandle for the Broadcast HLOS IOMMU domain.
	The Broadcast HLOS IOMMU domain includes a context bank and virtual address
	pools definitions, used for mapping non-secured pipe memory buffers.
- qcom,iommu-partition: partition number in the HLOS IOMMU domain.
- vdd-supply: phandle of the Broadcast GDSC as defined in msm-gdsc.dtsi.
- 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
- qcom,tsc-reset-cam-gpio: gpio for HW reset to the CAM.

Optional properties:

- pinctrl-states: the names of the pinctrl states that used by the driver to
	configure the TLMM pins. The allowed states are subset of the following
	list: disable, ts-in-0, ts-in-1, dual-ts, pc-card, ci-card, ci-plus,
	ts-in-0-pc-card, ts-in-0-ci-card, ts-in-0-ci-plus, ts-in-1-pc-card,
	ts-in-1-ci-card, ts-in-1-ci-plus, dual-ts-pc-card, dual-ts-ci-card,
	dual-ts-ci-plus.
- 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.

Example for a device without PCMCIA, with TS0-in-b serial and TS1-in-a parallel,
both TSIFs with valid and start:

	tsc: msm_tsc@fc74a000 {
		compatible = "qcom,msm-tsc";
		reg = <0xfc74a000 0x1110>;
		reg-names = "tsc-base";
		interrupts = <0 267 0>, /* cam-cmd */
			<0 268 0>; /* card-detect */
		interrupt-names = "cam-cmd",
				"card-detect";
		qcom,iommu-group = <&bcast_domain_hlos>;
		qcom,iommu-partition = <1>;
		vdd-supply = <&gdsc_bcss>;
		qcom,msm-bus,name = "tsc-bus";
		qcom,msm-bus,num-cases = <2>;
		qcom,msm-bus,num-paths = <1>;
		qcom,msm-bus,vectors-KBps = <96 512 0 0>, /* No vote */
					<96 512 448 896>; /* Max. 7Mbps */
		qcom,tsc-reset-cam-gpio = <&msm_gpio 138 0>;	/* reset-pin controller */
		pinctrl-states = "disable", "ts-in-0", "ts-in-1", "dual-ts";
		pinctrl-0 = <&ts_in_0_b_start_sleep
					&ts_in_0_b_valid_sleep
					&ts_in_0_b_ser_sleep
					&ts_in_1_a_start_sleep
					&ts_in_1_a_valid_sleep
					&ts_in_1_a_ser_sleep
					&ts_in_1_a_par_sleep>;	/* disable */
		pinctrl-1 = <&ts_in_0_b_start_active
					&ts_in_0_b_valid_active
					&ts_in_0_b_ser_active
					&ts_in_1_a_start_sleep
					&ts_in_1_a_valid_sleep
					&ts_in_1_a_ser_sleep
					&ts_in_1_a_par_sleep>; /* ts-in-0 */
		pinctrl-2 = <&ts_in_0_b_start_sleep
					&ts_in_0_b_valid_sleep
					&ts_in_0_b_ser_sleep
					&ts_in_1_a_start_active
					&ts_in_1_a_valid_active
					&ts_in_1_a_ser_active
					&ts_in_1_a_par_active>;	/* ts-in-1 */
		pinctrl-3 = <&ts_in_0_b_start_active
					&ts_in_0_b_valid_active
					&ts_in_0_b_ser_active
					&ts_in_1_a_start_active
					&ts_in_1_a_valid_active
					&ts_in_1_a_ser_active
					&ts_in_1_a_par_active>;	/* dual-ts */
	};

Example for a device with pcmcia, TS0-in-a serial with start and error, and
without TS1-in:

		tsc: msm_tsc@fc74a000 {
		compatible = "qcom,msm-tsc";
		reg = <0xfc74a000 0x1110>;
		reg-names = "tsc-base";
		interrupts = <0 267 0>, /* cam-cmd */
			<0 268 0>; /* card-detect */
		interrupt-names = "cam-cmd",
				"card-detect";
		qcom,iommu-group = <&bcast_domain_hlos>;
		qcom,iommu-partition = <1>;
		vdd-supply = <&gdsc_bcss>;
		qcom,msm-bus,name = "tsc-bus";
		qcom,msm-bus,num-cases = <2>;
		qcom,msm-bus,num-paths = <1>;
		qcom,msm-bus,vectors-KBps = <96 512 0 0>, /* No vote */
					<96 512 448 896>; /* Max. 7Mbps */
		qcom,tsc-reset-cam-gpio = <&msm_gpio 138 0>;	/* reset-pin controller */
		pinctrl-states = "disable", "ts-in-0", "pc-card", "ci-card", "ci-plus",
					"ts-in-0-pc-card", "ts-in-0-ci-card", "ts-in-0-ci-plus";
		pinctrl-0 = <&ts_in_0_a_start_sleep
					&ts_in_0_a_err_sleep
					&ts_in_0_a_ser_sleep
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_sleep
					&tsc_pcmcia_8ma_up_pc_card_sleep
					&tsc_cam_reset_pc_card_sleep
					&tsc_pcmcia_8ma_none_pc_card_sleep
					&tsc_pcmcia_ireq_pc_card_sleep
					&tsc_pcmcia_2_pc_card_sleep
					&tsc_pcmcia_1_down_ci_sleep
					&tsc_pcmcia_1_up_ci_sleep
					&tsc_pcmcia_1_none_ci_sleep
					&tsc_pcmcia_4_ci_sleep>;		/* disable */
		pinctrl-1 = <&ts_in_0_a_start_active
					&ts_in_0_a_err_active
					&ts_in_0_a_ser_active
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_sleep
					&tsc_pcmcia_8ma_up_pc_card_sleep
					&tsc_cam_reset_pc_card_sleep
					&tsc_pcmcia_8ma_none_pc_card_sleep
					&tsc_pcmcia_ireq_pc_card_sleep
					&tsc_pcmcia_2_pc_card_sleep
					&tsc_pcmcia_1_down_ci_sleep
					&tsc_pcmcia_1_up_ci_sleep
					&tsc_pcmcia_1_none_ci_sleep
					&tsc_pcmcia_4_ci_sleep>; 		/* ts-in-0 */
		pinctrl-2 = <&ts_in_0_a_start_sleep
					&ts_in_0_a_err_sleep
					&ts_in_0_a_ser_sleep
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_active
					&tsc_pcmcia_8ma_up_pc_card_active
					&tsc_cam_reset_pc_card_active
					&tsc_pcmcia_8ma_none_pc_card_active
					&tsc_pcmcia_ireq_pc_card_active
					&tsc_pcmcia_2_pc_card_active
					&tsc_pcmcia_1_down_ci_sleep
					&tsc_pcmcia_1_up_ci_sleep
					&tsc_pcmcia_1_none_ci_sleep
					&tsc_pcmcia_4_ci_sleep>;		/* pc-card */
		pinctrl-3 = <&ts_in_0_a_start_sleep
					&ts_in_0_a_err_sleep
					&ts_in_0_a_ser_sleep
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_active
					&tsc_pcmcia_8ma_up_pc_card_active
					&tsc_cam_reset_pc_card_active
					&tsc_pcmcia_8ma_none_pc_card_active
					&tsc_pcmcia_ireq_pc_card_sleep
					&tsc_pcmcia_2_pc_card_active
					&tsc_pcmcia_1_down_ci_active
					&tsc_pcmcia_1_up_ci_active
					&tsc_pcmcia_1_none_ci_active
					&tsc_pcmcia_4_ci_active?;		/* ci-card */
		pinctrl-4 = <&ts_in_0_a_start_sleep
					&ts_in_0_a_err_sleep
					&ts_in_0_a_ser_sleep
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_active
					&tsc_pcmcia_8ma_up_pc_card_active
					&tsc_cam_reset_pc_card_active
					&tsc_pcmcia_8ma_none_pc_card_active
					&tsc_pcmcia_ireq_pc_card_active
					&tsc_pcmcia_2_pc_card_active
					&tsc_pcmcia_1_down_ci_active
					&tsc_pcmcia_1_up_ci_active
					&tsc_pcmcia_1_none_ci_active
					&tsc_pcmcia_4_ci_active?;		/* ci-plus */
		pinctrl-5 = <&ts_in_0_a_start_active
					&ts_in_0_a_err_active
					&ts_in_0_a_ser_active
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_active
					&tsc_pcmcia_8ma_up_pc_card_active
					&tsc_cam_reset_pc_card_active
					&tsc_pcmcia_8ma_none_pc_card_active
					&tsc_pcmcia_ireq_pc_card_active
					&tsc_pcmcia_2_pc_card_active
					&tsc_pcmcia_1_down_ci_sleep
					&tsc_pcmcia_1_up_ci_sleep
					&tsc_pcmcia_1_none_ci_sleep
					&tsc_pcmcia_4_ci_sleep>;		/* ts-in-0-pc-card */
		pinctrl-6 = <&ts_in_0_a_start_active
					&ts_in_0_a_err_active
					&ts_in_0_a_ser_active
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_active
					&tsc_pcmcia_8ma_up_pc_card_active
					&tsc_cam_reset_pc_card_active
					&tsc_pcmcia_8ma_none_pc_card_active
					&tsc_pcmcia_ireq_pc_card_sleep
					&tsc_pcmcia_2_pc_card_active
					&tsc_pcmcia_1_down_ci_active
					&tsc_pcmcia_1_up_ci_active
					&tsc_pcmcia_1_none_ci_active
					&tsc_pcmcia_4_ci_active?;		/* ts-in-0-ci-card */
		pinctrl-7 = <&ts_in_0_a_start_active
					&ts_in_0_a_err_active
					&ts_in_0_a_ser_active
					&tsc_cd_pins_active
					&tsc_pcmcia_8ma_down_pc_card_active
					&tsc_pcmcia_8ma_up_pc_card_active
					&tsc_cam_reset_pc_card_active
					&tsc_pcmcia_8ma_none_pc_card_active
					&tsc_pcmcia_ireq_pc_card_active
					&tsc_pcmcia_2_pc_card_active
					&tsc_pcmcia_1_down_ci_active
					&tsc_pcmcia_1_up_ci_active
					&tsc_pcmcia_1_none_ci_active
					&tsc_pcmcia_4_ci_active?;		/* ts-in-0-ci-plus */
	};
