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

Commit 08be64be authored by Dmitri Belimov's avatar Dmitri Belimov Committed by Mauro Carvalho Chehab
Browse files

V4L/DVB (13966): DVB-T regression fix for saa7134 cards

Some customers has problem with quality of DVB-T
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/446575

After this patch http://patchwork.kernel.org/patch/23345/



This is patch for fix regression with DVB-T. Tested with many people.

Signed-off-by: default avatarAlexey Osipov <lion-simba@pridelands.ru>
Signed-off-by: default avatarBeholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 423f5c0d
Loading
Loading
Loading
Loading
+0 −13
Original line number Original line Diff line number Diff line
@@ -420,19 +420,6 @@ int saa7134_set_dmabits(struct saa7134_dev *dev)
		ctrl |= SAA7134_MAIN_CTRL_TE5;
		ctrl |= SAA7134_MAIN_CTRL_TE5;
		irq  |= SAA7134_IRQ1_INTE_RA2_1 |
		irq  |= SAA7134_IRQ1_INTE_RA2_1 |
			SAA7134_IRQ1_INTE_RA2_0;
			SAA7134_IRQ1_INTE_RA2_0;

		/* dma: setup channel 5 (= TS) */

		saa_writeb(SAA7134_TS_DMA0, (dev->ts.nr_packets - 1) & 0xff);
		saa_writeb(SAA7134_TS_DMA1,
			((dev->ts.nr_packets - 1) >> 8) & 0xff);
		/* TSNOPIT=0, TSCOLAP=0 */
		saa_writeb(SAA7134_TS_DMA2,
			(((dev->ts.nr_packets - 1) >> 16) & 0x3f) | 0x00);
		saa_writel(SAA7134_RS_PITCH(5), TS_PACKET_SIZE);
		saa_writel(SAA7134_RS_CONTROL(5), SAA7134_RS_CONTROL_BURST_16 |
						  SAA7134_RS_CONTROL_ME |
						  (dev->ts.pt_ts.dma >> 12));
	}
	}


	/* set task conditions + field handling */
	/* set task conditions + field handling */
+13 −0
Original line number Original line Diff line number Diff line
@@ -250,6 +250,19 @@ int saa7134_ts_start(struct saa7134_dev *dev)


	BUG_ON(dev->ts_started);
	BUG_ON(dev->ts_started);


	/* dma: setup channel 5 (= TS) */
	saa_writeb(SAA7134_TS_DMA0, (dev->ts.nr_packets - 1) & 0xff);
	saa_writeb(SAA7134_TS_DMA1,
		((dev->ts.nr_packets - 1) >> 8) & 0xff);
	/* TSNOPIT=0, TSCOLAP=0 */
	saa_writeb(SAA7134_TS_DMA2,
		(((dev->ts.nr_packets - 1) >> 16) & 0x3f) | 0x00);
	saa_writel(SAA7134_RS_PITCH(5), TS_PACKET_SIZE);
	saa_writel(SAA7134_RS_CONTROL(5), SAA7134_RS_CONTROL_BURST_16 |
					  SAA7134_RS_CONTROL_ME |
					  (dev->ts.pt_ts.dma >> 12));

	/* reset hardware TS buffers */
	saa_writeb(SAA7134_TS_SERIAL1, 0x00);
	saa_writeb(SAA7134_TS_SERIAL1, 0x00);
	saa_writeb(SAA7134_TS_SERIAL1, 0x03);
	saa_writeb(SAA7134_TS_SERIAL1, 0x03);
	saa_writeb(SAA7134_TS_SERIAL1, 0x00);
	saa_writeb(SAA7134_TS_SERIAL1, 0x00);