All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/5] saa7164: add support for i2c read
@ 2015-03-27 11:57 Olli Salonen
  2015-03-27 11:57 ` [PATCH 2/5] si2168: add support for gapped clock Olli Salonen
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Olli Salonen @ 2015-03-27 11:57 UTC (permalink / raw)
  To: linux-media; +Cc: Olli Salonen

Add support for pure I2C reads. Needed by si2157 tuner driver.

Signed-off-by: Olli Salonen <olli.salonen@iki.fi>
---
 drivers/media/pci/saa7164/saa7164-i2c.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/media/pci/saa7164/saa7164-i2c.c b/drivers/media/pci/saa7164/saa7164-i2c.c
index 4f7e3b4..e30e206 100644
--- a/drivers/media/pci/saa7164/saa7164-i2c.c
+++ b/drivers/media/pci/saa7164/saa7164-i2c.c
@@ -39,9 +39,12 @@ static int i2c_xfer(struct i2c_adapter *i2c_adap, struct i2c_msg *msgs, int num)
 		dprintk(DBGLVL_I2C, "%s(num = %d) addr = 0x%02x  len = 0x%x\n",
 			__func__, num, msgs[i].addr, msgs[i].len);
 		if (msgs[i].flags & I2C_M_RD) {
-			/* Unsupported - Yet*/
-			printk(KERN_ERR "%s() Unsupported - Yet\n", __func__);
-			continue;
+			/* dummy write before read */
+			retval = saa7164_api_i2c_read(bus, msgs[i].addr,
+				0, NULL, msgs[i].len, msgs[i].buf);
+
+			if (retval < 0)
+				goto err;
 		} else if (i + 1 < num && (msgs[i + 1].flags & I2C_M_RD) &&
 			   msgs[i].addr == msgs[i + 1].addr) {
 			/* write then read from same address */
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 2/5] si2168: add support for gapped clock
  2015-03-27 11:57 [PATCH 1/5] saa7164: add support for i2c read Olli Salonen
@ 2015-03-27 11:57 ` Olli Salonen
  2015-03-27 11:57 ` [PATCH 3/5] saa7164: store i2c_client for demod and tuner in state Olli Salonen
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 10+ messages in thread
From: Olli Salonen @ 2015-03-27 11:57 UTC (permalink / raw)
  To: linux-media; +Cc: Olli Salonen

Add a parameter in si2168_config to support gapped clock.

Signed-off-by: Olli Salonen <olli.salonen@iki.fi>
---
 drivers/media/dvb-frontends/si2168.c      | 3 +++
 drivers/media/dvb-frontends/si2168.h      | 3 +++
 drivers/media/dvb-frontends/si2168_priv.h | 1 +
 3 files changed, 7 insertions(+)

diff --git a/drivers/media/dvb-frontends/si2168.c b/drivers/media/dvb-frontends/si2168.c
index 5db588e..29a5936 100644
--- a/drivers/media/dvb-frontends/si2168.c
+++ b/drivers/media/dvb-frontends/si2168.c
@@ -508,6 +508,8 @@ static int si2168_init(struct dvb_frontend *fe)
 	/* set ts mode */
 	memcpy(cmd.args, "\x14\x00\x01\x10\x10\x00", 6);
 	cmd.args[4] |= dev->ts_mode;
+	if (dev->ts_clock_gapped)
+		cmd.args[4] |= 0x40;
 	cmd.wlen = 6;
 	cmd.rlen = 4;
 	ret = si2168_cmd_execute(client, &cmd);
@@ -688,6 +690,7 @@ static int si2168_probe(struct i2c_client *client,
 	*config->fe = &dev->fe;
 	dev->ts_mode = config->ts_mode;
 	dev->ts_clock_inv = config->ts_clock_inv;
+	dev->ts_clock_gapped = config->ts_clock_gapped;
 	dev->fw_loaded = false;
 
 	i2c_set_clientdata(client, dev);
diff --git a/drivers/media/dvb-frontends/si2168.h b/drivers/media/dvb-frontends/si2168.h
index 70d702a..3225d0c 100644
--- a/drivers/media/dvb-frontends/si2168.h
+++ b/drivers/media/dvb-frontends/si2168.h
@@ -42,6 +42,9 @@ struct si2168_config {
 
 	/* TS clock inverted */
 	bool ts_clock_inv;
+
+	/* TS clock gapped */
+	bool ts_clock_gapped;
 };
 
 #endif
diff --git a/drivers/media/dvb-frontends/si2168_priv.h b/drivers/media/dvb-frontends/si2168_priv.h
index aadd136..953af7b 100644
--- a/drivers/media/dvb-frontends/si2168_priv.h
+++ b/drivers/media/dvb-frontends/si2168_priv.h
@@ -38,6 +38,7 @@ struct si2168_dev {
 	bool fw_loaded;
 	u8 ts_mode;
 	bool ts_clock_inv;
+	bool ts_clock_gapped;
 };
 
 /* firmare command struct */
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 3/5] saa7164: store i2c_client for demod and tuner in state
  2015-03-27 11:57 [PATCH 1/5] saa7164: add support for i2c read Olli Salonen
  2015-03-27 11:57 ` [PATCH 2/5] si2168: add support for gapped clock Olli Salonen
@ 2015-03-27 11:57 ` Olli Salonen
  2015-03-27 11:57 ` [PATCH 4/5] dvbsky: use si2168 config option ts_clock_gapped Olli Salonen
  2015-03-27 11:57 ` [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners Olli Salonen
  3 siblings, 0 replies; 10+ messages in thread
From: Olli Salonen @ 2015-03-27 11:57 UTC (permalink / raw)
  To: linux-media; +Cc: Olli Salonen

In order to support demodulators and tuners that have their drivers
implemented as I2C drivers, the i2c_client should be stored in state for
both.

Signed-off-by: Olli Salonen <olli.salonen@iki.fi>
---
 drivers/media/pci/saa7164/saa7164-dvb.c | 16 ++++++++++++++++
 drivers/media/pci/saa7164/saa7164.h     |  3 +++
 2 files changed, 19 insertions(+)

diff --git a/drivers/media/pci/saa7164/saa7164-dvb.c b/drivers/media/pci/saa7164/saa7164-dvb.c
index 16ae715..6b9e8f6 100644
--- a/drivers/media/pci/saa7164/saa7164-dvb.c
+++ b/drivers/media/pci/saa7164/saa7164-dvb.c
@@ -425,6 +425,7 @@ int saa7164_dvb_unregister(struct saa7164_port *port)
 	struct saa7164_dev *dev = port->dev;
 	struct saa7164_buffer *b;
 	struct list_head *c, *n;
+	struct i2c_client *client;
 
 	dprintk(DBGLVL_DVB, "%s()\n", __func__);
 
@@ -451,6 +452,21 @@ int saa7164_dvb_unregister(struct saa7164_port *port)
 	dvb_unregister_frontend(dvb->frontend);
 	dvb_frontend_detach(dvb->frontend);
 	dvb_unregister_adapter(&dvb->adapter);
+
+	/* remove I2C client for tuner */
+	client = port->i2c_client_tuner;
+	if (client) {
+		module_put(client->dev.driver->owner);
+		i2c_unregister_device(client);
+	}
+
+	/* remove I2C client for demodulator */
+	client = port->i2c_client_demod;
+	if (client) {
+		module_put(client->dev.driver->owner);
+		i2c_unregister_device(client);
+	}
+
 	return 0;
 }
 
diff --git a/drivers/media/pci/saa7164/saa7164.h b/drivers/media/pci/saa7164/saa7164.h
index cd1a07c..37e450a 100644
--- a/drivers/media/pci/saa7164/saa7164.h
+++ b/drivers/media/pci/saa7164/saa7164.h
@@ -422,6 +422,9 @@ struct saa7164_port {
 	u8 last_v_cc;
 	u8 last_a_cc;
 	u32 done_first_interrupt;
+
+	struct i2c_client *i2c_client_demod;
+	struct i2c_client *i2c_client_tuner;
 };
 
 struct saa7164_dev {
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 4/5] dvbsky: use si2168 config option ts_clock_gapped
  2015-03-27 11:57 [PATCH 1/5] saa7164: add support for i2c read Olli Salonen
  2015-03-27 11:57 ` [PATCH 2/5] si2168: add support for gapped clock Olli Salonen
  2015-03-27 11:57 ` [PATCH 3/5] saa7164: store i2c_client for demod and tuner in state Olli Salonen
@ 2015-03-27 11:57 ` Olli Salonen
  2015-03-27 11:57 ` [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners Olli Salonen
  3 siblings, 0 replies; 10+ messages in thread
From: Olli Salonen @ 2015-03-27 11:57 UTC (permalink / raw)
  To: linux-media; +Cc: Olli Salonen

Change the dvbsky driver to support gapped clock instead of the current
hack.

Signed-off-by: Olli Salonen <olli.salonen@iki.fi>
---
 drivers/media/usb/dvb-usb-v2/dvbsky.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/media/usb/dvb-usb-v2/dvbsky.c b/drivers/media/usb/dvb-usb-v2/dvbsky.c
index 9b5add4..a8495cd 100644
--- a/drivers/media/usb/dvb-usb-v2/dvbsky.c
+++ b/drivers/media/usb/dvb-usb-v2/dvbsky.c
@@ -619,7 +619,8 @@ static int dvbsky_t330_attach(struct dvb_usb_adapter *adap)
 	memset(&si2168_config, 0, sizeof(si2168_config));
 	si2168_config.i2c_adapter = &i2c_adapter;
 	si2168_config.fe = &adap->fe[0];
-	si2168_config.ts_mode = SI2168_TS_PARALLEL | 0x40;
+	si2168_config.ts_mode = SI2168_TS_PARALLEL;
+	si2168_config.ts_clock_gapped = true;
 	memset(&info, 0, sizeof(struct i2c_board_info));
 	strlcpy(info.type, "si2168", I2C_NAME_SIZE);
 	info.addr = 0x64;
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners
  2015-03-27 11:57 [PATCH 1/5] saa7164: add support for i2c read Olli Salonen
                   ` (2 preceding siblings ...)
  2015-03-27 11:57 ` [PATCH 4/5] dvbsky: use si2168 config option ts_clock_gapped Olli Salonen
@ 2015-03-27 11:57 ` Olli Salonen
  2015-03-27 12:08   ` Steven Toth
  3 siblings, 1 reply; 10+ messages in thread
From: Olli Salonen @ 2015-03-27 11:57 UTC (permalink / raw)
  To: linux-media; +Cc: Olli Salonen

Hauppauge HVR-2205 and HVR-2215 are PCIe dual tuner cards that support
DVB-C, DVB-T and DVB-T2.

PCIe bridge: SAA7164
Demodulator: Si2168-B40
Tuner: SI2157-A20

I know there's parallel activity ongoing regarding these devices, but I 
thought I'll submit my own version here as well. The maintainers of each 
module can then make the call what to merge.

Signed-off-by: Olli Salonen <olli.salonen@iki.fi>
---
 drivers/media/pci/saa7164/Kconfig         |   2 +
 drivers/media/pci/saa7164/saa7164-cards.c | 101 ++++++++++++++++++++++++++++++
 drivers/media/pci/saa7164/saa7164-dvb.c   |  67 ++++++++++++++++++++
 drivers/media/pci/saa7164/saa7164.h       |   2 +
 4 files changed, 172 insertions(+)

diff --git a/drivers/media/pci/saa7164/Kconfig b/drivers/media/pci/saa7164/Kconfig
index a53db7d..5ebe930 100644
--- a/drivers/media/pci/saa7164/Kconfig
+++ b/drivers/media/pci/saa7164/Kconfig
@@ -8,7 +8,9 @@ config VIDEO_SAA7164
 	select VIDEOBUF_DVB
 	select DVB_TDA10048 if MEDIA_SUBDRV_AUTOSELECT
 	select DVB_S5H1411 if MEDIA_SUBDRV_AUTOSELECT
+	select DVB_SI2168 if MEDIA_SUBDRV_AUTOSELECT
 	select MEDIA_TUNER_TDA18271 if MEDIA_SUBDRV_AUTOSELECT
+	select MEDIA_TUNER_SI2157 if MEDIA_SUBDRV_AUTOSELECT
 	---help---
 	  This is a video4linux driver for NXP SAA7164 based
 	  TV cards.
diff --git a/drivers/media/pci/saa7164/saa7164-cards.c b/drivers/media/pci/saa7164/saa7164-cards.c
index 5b72da5..5ebd312 100644
--- a/drivers/media/pci/saa7164/saa7164-cards.c
+++ b/drivers/media/pci/saa7164/saa7164-cards.c
@@ -499,6 +499,90 @@ struct saa7164_board saa7164_boards[] = {
 			.i2c_reg_len	= REGLEN_8bit,
 		} },
 	},
+	[SAA7164_BOARD_HAUPPAUGE_HVR2205] = {
+		.name		= "Hauppauge WinTV-HVR2205",
+		.porta		= SAA7164_MPEG_DVB,
+		.portb		= SAA7164_MPEG_DVB,
+		.chiprev	= SAA7164_CHIP_REV3,
+		.unit = {{
+			.id = 0x28,
+			.type = SAA7164_UNIT_EEPROM,
+			.name = "4K EEPROM",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_0,
+			.i2c_bus_addr	= 0xa0 >> 1,
+			.i2c_reg_len	= REGLEN_8bit,
+		}, {
+			.id		= 0x04,
+			.type		= SAA7164_UNIT_TUNER,
+			.name		= "SI2157-1",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_1,
+			.i2c_bus_addr	= 0xc0 >> 1,
+			.i2c_reg_len	= 0,
+		}, {
+			.id		= 0x05,
+			.type		= SAA7164_UNIT_DIGITAL_DEMODULATOR,
+			.name		= "SI2168-1",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_1,
+			.i2c_bus_addr	= 0xc8 >> 1,
+			.i2c_reg_len	= 0,
+		}, {
+			.id		= 0x25,
+			.type		= SAA7164_UNIT_TUNER,
+			.name		= "SI2157-2",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_2,
+			.i2c_bus_addr	= 0xc0 >> 1,
+			.i2c_reg_len	= 0,
+		}, {
+			.id		= 0x26,
+			.type		= SAA7164_UNIT_DIGITAL_DEMODULATOR,
+			.name		= "SI2168-2",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_2,
+			.i2c_bus_addr	= 0xcc >> 1,
+			.i2c_reg_len	= 0,
+		} },
+	},
+	[SAA7164_BOARD_HAUPPAUGE_HVR2215] = {
+		.name		= "Hauppauge WinTV-HVR2215",
+		.porta		= SAA7164_MPEG_DVB,
+		.portb		= SAA7164_MPEG_DVB,
+		.chiprev	= SAA7164_CHIP_REV3,
+		.unit = {{
+			.id = 0x28,
+			.type = SAA7164_UNIT_EEPROM,
+			.name = "4K EEPROM",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_0,
+			.i2c_bus_addr	= 0xa0 >> 1,
+			.i2c_reg_len	= REGLEN_8bit,
+		}, {
+			.id		= 0x04,
+			.type		= SAA7164_UNIT_TUNER,
+			.name		= "SI2157-1",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_1,
+			.i2c_bus_addr	= 0xc0 >> 1,
+			.i2c_reg_len	= 0,
+		}, {
+			.id		= 0x05,
+			.type		= SAA7164_UNIT_DIGITAL_DEMODULATOR,
+			.name		= "SI2168-1",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_1,
+			.i2c_bus_addr	= 0xc8 >> 1,
+			.i2c_reg_len	= 0,
+		}, {
+			.id		= 0x25,
+			.type		= SAA7164_UNIT_TUNER,
+			.name		= "SI2157-2",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_2,
+			.i2c_bus_addr	= 0xc0 >> 1,
+			.i2c_reg_len	= 0,
+		}, {
+			.id		= 0x26,
+			.type		= SAA7164_UNIT_DIGITAL_DEMODULATOR,
+			.name		= "SI2168-2",
+			.i2c_bus_nr	= SAA7164_I2C_BUS_2,
+			.i2c_bus_addr	= 0xcc >> 1,
+			.i2c_reg_len	= 0,
+		} },
+	},
 };
 const unsigned int saa7164_bcount = ARRAY_SIZE(saa7164_boards);
 
@@ -546,6 +630,14 @@ struct saa7164_subid saa7164_subids[] = {
 		.subvendor = 0x0070,
 		.subdevice = 0x8953,
 		.card      = SAA7164_BOARD_HAUPPAUGE_HVR2200_5,
+	}, {
+		.subvendor = 0x0070,
+		.subdevice = 0xf120,
+		.card      = SAA7164_BOARD_HAUPPAUGE_HVR2205,
+	}, {
+		.subvendor = 0x0070,
+		.subdevice = 0xf123,
+		.card      = SAA7164_BOARD_HAUPPAUGE_HVR2215,
 	},
 };
 const unsigned int saa7164_idcount = ARRAY_SIZE(saa7164_subids);
@@ -591,6 +683,8 @@ void saa7164_gpio_setup(struct saa7164_dev *dev)
 	case SAA7164_BOARD_HAUPPAUGE_HVR2200_3:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2200_4:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2200_5:
+	case SAA7164_BOARD_HAUPPAUGE_HVR2205:
+	case SAA7164_BOARD_HAUPPAUGE_HVR2215:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250_2:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250_3:
@@ -647,6 +741,11 @@ static void hauppauge_eeprom(struct saa7164_dev *dev, u8 *eeprom_data)
 		/* WinTV-HVR2200 (PCIe, Retail, half-height)
 		 * DVB-T (TDA18271/TDA10048) and basic analog, no IR */
 		break;
+	case 151009:
+	case 151609:
+		/* WinTV-HVR2205/HVR2215 (PCIe, Retail, full-height bracket)
+		 * DVB-T2/C (Si2157/Si2168) and basic analog, FM */
+		break;
 	default:
 		printk(KERN_ERR "%s: Warning: Unknown Hauppauge model #%d\n",
 			dev->name, tv.model);
@@ -673,6 +772,8 @@ void saa7164_card_setup(struct saa7164_dev *dev)
 	case SAA7164_BOARD_HAUPPAUGE_HVR2200_3:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2200_4:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2200_5:
+	case SAA7164_BOARD_HAUPPAUGE_HVR2205:
+	case SAA7164_BOARD_HAUPPAUGE_HVR2215:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250_2:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250_3:
diff --git a/drivers/media/pci/saa7164/saa7164-dvb.c b/drivers/media/pci/saa7164/saa7164-dvb.c
index 6b9e8f6..2242ef5 100644
--- a/drivers/media/pci/saa7164/saa7164-dvb.c
+++ b/drivers/media/pci/saa7164/saa7164-dvb.c
@@ -24,6 +24,8 @@
 #include "tda10048.h"
 #include "tda18271.h"
 #include "s5h1411.h"
+#include "si2168.h"
+#include "si2157.h"
 
 #define DRIVER_NAME "saa7164"
 
@@ -519,6 +521,71 @@ int saa7164_dvb_register(struct saa7164_port *port)
 			break;
 		}
 		break;
+	case SAA7164_BOARD_HAUPPAUGE_HVR2205:
+	case SAA7164_BOARD_HAUPPAUGE_HVR2215:
+		{
+			struct si2168_config si2168_config;
+			struct si2157_config si2157_config;
+			struct i2c_board_info info;
+			struct i2c_adapter *adapter;
+			struct i2c_client *client_demod = NULL;
+			struct i2c_client *client_tuner = NULL;
+
+			i2c_bus = &dev->i2c_bus[port->nr + 1];
+
+			/* attach frontend */
+			memset(&si2168_config, 0, sizeof(si2168_config));
+			si2168_config.i2c_adapter = &adapter;
+			si2168_config.fe = &port->dvb.frontend;
+			si2168_config.ts_mode = SI2168_TS_SERIAL;
+			si2168_config.ts_clock_gapped = true;
+			memset(&info, 0, sizeof(struct i2c_board_info));
+			switch (port->nr) {
+			case 0:
+				info.addr = 0xc8 >> 1;
+				break;
+			case 1:
+				info.addr = 0xcc >> 1;
+				break;
+			}
+			strlcpy(info.type, "si2168", I2C_NAME_SIZE);
+			info.platform_data = &si2168_config;
+			request_module(info.type);
+			client_demod = i2c_new_device(&i2c_bus->i2c_adap,
+						      &info);
+			if (client_demod == NULL ||
+					client_demod->dev.driver == NULL)
+				break;
+			if (!try_module_get(client_demod->dev.driver->owner)) {
+				i2c_unregister_device(client_demod);
+				break;
+			}
+			port->i2c_client_demod = client_demod;
+
+			/* attach tuner */
+			memset(&si2157_config, 0, sizeof(si2157_config));
+			si2157_config.fe = port->dvb.frontend;
+			memset(&info, 0, sizeof(struct i2c_board_info));
+			strlcpy(info.type, "si2157", I2C_NAME_SIZE);
+			info.addr = 0xc0 >> 1;
+			info.platform_data = &si2157_config;
+			request_module(info.type);
+			client_tuner = i2c_new_device(adapter, &info);
+			if (client_tuner == NULL ||
+					client_tuner->dev.driver == NULL) {
+				module_put(client_demod->dev.driver->owner);
+				i2c_unregister_device(client_demod);
+				break;
+			}
+			if (!try_module_get(client_tuner->dev.driver->owner)) {
+				i2c_unregister_device(client_tuner);
+				module_put(client_demod->dev.driver->owner);
+				i2c_unregister_device(client_demod);
+				break;
+			}
+			port->i2c_client_tuner = client_tuner;
+			break;
+		}
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250_2:
 	case SAA7164_BOARD_HAUPPAUGE_HVR2250_3:
diff --git a/drivers/media/pci/saa7164/saa7164.h b/drivers/media/pci/saa7164/saa7164.h
index 37e450a..1b41849 100644
--- a/drivers/media/pci/saa7164/saa7164.h
+++ b/drivers/media/pci/saa7164/saa7164.h
@@ -83,6 +83,8 @@
 #define SAA7164_BOARD_HAUPPAUGE_HVR2250_3	8
 #define SAA7164_BOARD_HAUPPAUGE_HVR2200_4	9
 #define SAA7164_BOARD_HAUPPAUGE_HVR2200_5	10
+#define SAA7164_BOARD_HAUPPAUGE_HVR2205		11
+#define SAA7164_BOARD_HAUPPAUGE_HVR2215		12
 
 #define SAA7164_MAX_UNITS		8
 #define SAA7164_TS_NUMBER_OF_LINES	312
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners
  2015-03-27 11:57 ` [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners Olli Salonen
@ 2015-03-27 12:08   ` Steven Toth
  2015-03-27 12:13     ` Antti Palosaari
  2015-03-27 12:31     ` Olli Salonen
  0 siblings, 2 replies; 10+ messages in thread
From: Steven Toth @ 2015-03-27 12:08 UTC (permalink / raw)
  To: Olli Salonen; +Cc: Linux-Media, Antti Palosaari

> I know there's parallel activity ongoing regarding these devices, but I
> thought I'll submit my own version here as well. The maintainers of each
> module can then make the call what to merge.

http://git.linuxtv.org/cgit.cgi/stoth/media_tree.git/log/?h=saa7164-dev

As mentioned previously, I've added support for the HVR2205 and
HVR2255. I moved those patches from bitbucket.org into linuxtv.org a
couple of days ago pending a pull request. It took a couple of days to
get my git.linuxtv.org account back up and running.

You've seen and commented on the patches when they were in bitbucket
earlier this week, so your need to push our your own patches only
confuses and concerns me.

I did not require any 2168/2157 driver changes to make these devices
work. (Antti please note).

I plan to issue a pull request for my tree shortly.

- Steve

-- 
Steven Toth - Kernel Labs
http://www.kernellabs.com

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners
  2015-03-27 12:08   ` Steven Toth
@ 2015-03-27 12:13     ` Antti Palosaari
  2015-03-27 12:16       ` Steven Toth
  2015-03-27 12:31     ` Olli Salonen
  1 sibling, 1 reply; 10+ messages in thread
From: Antti Palosaari @ 2015-03-27 12:13 UTC (permalink / raw)
  To: Steven Toth, Olli Salonen; +Cc: Linux-Media

On 03/27/2015 02:08 PM, Steven Toth wrote:
>> I know there's parallel activity ongoing regarding these devices, but I
>> thought I'll submit my own version here as well. The maintainers of each
>> module can then make the call what to merge.
>
> http://git.linuxtv.org/cgit.cgi/stoth/media_tree.git/log/?h=saa7164-dev
>
> As mentioned previously, I've added support for the HVR2205 and
> HVR2255. I moved those patches from bitbucket.org into linuxtv.org a
> couple of days ago pending a pull request. It took a couple of days to
> get my git.linuxtv.org account back up and running.
>
> You've seen and commented on the patches when they were in bitbucket
> earlier this week, so your need to push our your own patches only
> confuses and concerns me.
>
> I did not require any 2168/2157 driver changes to make these devices
> work. (Antti please note).

There seems to be only minor TS config change (which is not even needed 
if you set that bit to existing TS mode config value) for 
gapped/variable length TS clock (which is in my understanding to leave 
TS valid line unconnected).

> I plan to issue a pull request for my tree shortly.
>
> - Steve
>

Antti
-- 
http://palosaari.fi/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners
  2015-03-27 12:13     ` Antti Palosaari
@ 2015-03-27 12:16       ` Steven Toth
  0 siblings, 0 replies; 10+ messages in thread
From: Steven Toth @ 2015-03-27 12:16 UTC (permalink / raw)
  To: Antti Palosaari; +Cc: Olli Salonen, Linux-Media

>> I did not require any 2168/2157 driver changes to make these devices
>> work. (Antti please note).
>
>
> There seems to be only minor TS config change (which is not even needed if
> you set that bit to existing TS mode config value) for gapped/variable
> length TS clock (which is in my understanding to leave TS valid line
> unconnected).

Its not required for the HVR2205 or the HVR2255, these are the only
two models of the hardware shipping in production volumes to
customers. Any other cards were advanced prototypes, that's my
understanding.

I'm not suggesting the gapped clock 2168 patch isn't useful for other
bridges, you might want to pull Olli's patch for that, but its not
required for the HVR2205/2255 support.

-- 
Steven Toth - Kernel Labs
http://www.kernellabs.com

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners
  2015-03-27 12:08   ` Steven Toth
  2015-03-27 12:13     ` Antti Palosaari
@ 2015-03-27 12:31     ` Olli Salonen
  2015-03-27 12:39       ` Steven Toth
  1 sibling, 1 reply; 10+ messages in thread
From: Olli Salonen @ 2015-03-27 12:31 UTC (permalink / raw)
  To: Steven Toth; +Cc: Linux-Media, Antti Palosaari

Hi,

Feel free to ignore the patches I sent. Just thought that since I made
the work to get the devices working anyway I'll post my code in case
someone can benefit from that somehow.

The HVR-2215 is sold in Australia, it's not a prototype card:
http://www.pccasegear.com/index.php?main_page=product_info&products_id=28385&cPath=172

I also know a user in AU who has tested my code with HVR-2215 and it works ok.

My understanding is that the Windows driver does set the gapped clock,
the below is from Hauppauge's own Windows driver INF files for
HVR-2205 (I assume the parameters pointing to Si2164 apply also to
Si2168):

;gapped clock
HKR,"Parameters","Si2164_ts_clk_gapped_en",0x00010001, 1

However, it is true that the device seems to work with or without this
setting. That was the case with TechnoTrend CT2-4400 earlier as well.
Only when TT made another version of the same device (with the same
USB IDs etc.) it stopped working and the change was necessary.

Cheers,
-olli


On 27 March 2015 at 14:08, Steven Toth <stoth@kernellabs.com> wrote:
>> I know there's parallel activity ongoing regarding these devices, but I
>> thought I'll submit my own version here as well. The maintainers of each
>> module can then make the call what to merge.
>
> http://git.linuxtv.org/cgit.cgi/stoth/media_tree.git/log/?h=saa7164-dev
>
> As mentioned previously, I've added support for the HVR2205 and
> HVR2255. I moved those patches from bitbucket.org into linuxtv.org a
> couple of days ago pending a pull request. It took a couple of days to
> get my git.linuxtv.org account back up and running.
>
> You've seen and commented on the patches when they were in bitbucket
> earlier this week, so your need to push our your own patches only
> confuses and concerns me.
>
> I did not require any 2168/2157 driver changes to make these devices
> work. (Antti please note).
>
> I plan to issue a pull request for my tree shortly.
>
> - Steve
>
> --
> Steven Toth - Kernel Labs
> http://www.kernellabs.com

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners
  2015-03-27 12:31     ` Olli Salonen
@ 2015-03-27 12:39       ` Steven Toth
  0 siblings, 0 replies; 10+ messages in thread
From: Steven Toth @ 2015-03-27 12:39 UTC (permalink / raw)
  To: Olli Salonen; +Cc: Linux-Media, Antti Palosaari

> The HVR-2215 is sold in Australia, it's not a prototype card:
> http://www.pccasegear.com/index.php?main_page=product_info&products_id=28385&cPath=172

Thanks for the URL. I've ordered a card. I'll look into the gapped
clock. If it's not required on the HVR2205 (using 2168) then it
shouldn't be required for the HVR2215 (using 2168), but that's
speculation at this point.

I also have the hardware schematics so I'll check those when the board
arrives also.

Thanks for the heads up.

-- 
Steven Toth - Kernel Labs
http://www.kernellabs.com

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2015-03-27 12:39 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-27 11:57 [PATCH 1/5] saa7164: add support for i2c read Olli Salonen
2015-03-27 11:57 ` [PATCH 2/5] si2168: add support for gapped clock Olli Salonen
2015-03-27 11:57 ` [PATCH 3/5] saa7164: store i2c_client for demod and tuner in state Olli Salonen
2015-03-27 11:57 ` [PATCH 4/5] dvbsky: use si2168 config option ts_clock_gapped Olli Salonen
2015-03-27 11:57 ` [PATCH 5/5] saa7164: Hauppauge HVR-2205 and HVR-2215 DVB-C/T/T2 tuners Olli Salonen
2015-03-27 12:08   ` Steven Toth
2015-03-27 12:13     ` Antti Palosaari
2015-03-27 12:16       ` Steven Toth
2015-03-27 12:31     ` Olli Salonen
2015-03-27 12:39       ` Steven Toth

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.