Fix radio issues and few minor bugs.
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi, i have few extra patches against current git, kernel 3.2.0rc-1, primary they should fix radio issues with some XC4000 and XC2028 tuners, but there are also some minor bug fixes. Number 7 is not my work, it is Istvan Varga patch.
M. Slugeň
Quoted 1 line
From
6192e1b178814c7a42f9a1bc8b438024513f220fMon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Sun, 11 Dec 2011 22:47:32 +0100
Subject: [PATCH 1/7] Update xc4000 tuner definition, number 81 is already in use by TUNER_PARTSNIC_PTI_5NF05
--- include/media/tuner.h | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
include/media/tuner.h +2 -1
@@ -127,7 +127,6 @@#define TUNER_PHILIPS_FMD1216MEX_MK3 78#define TUNER_PHILIPS_FM1216MK5 79#define TUNER_PHILIPS_FQ1216LME_MK3 80/* Active loopthrough, no FM */ -#define TUNER_XC4000 81/* Xceive Silicon Tuner */ #define TUNER_PARTSNIC_PTI_5NF05 81#define TUNER_PHILIPS_CU1216L 82
@@ -136,6 +135,8 @@#define TUNER_PHILIPS_FQ1236_MK5 85/* NTSC, TDA9885, no FM radio */ #define TUNER_TENA_TNF_5337 86 +#define TUNER_XC4000 87/* Xceive Silicon Tuner */ +/* tv card specific */ #define TDA9887_PRESENT (1<<0)#define TDA9887_PORT1_INACTIVE (1<<1)
Signature · 1 line
1.7.2.3
Quoted 1 line
From
b7b8a326eaf65e404f9483e3d918d3af3a8d9531Mon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Sun, 11 Dec 2011 22:56:15 +0100
Subject: [PATCH 2/7] Put analog radio and analog TV together both required same offset.
--- drivers/media/common/tuners/tuner-xc2028.c | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-)
drivers/media/common/tuners/tuner-xc2028.c +2 -4
@@ -942,12 +942,10 @@ static int generic_set_freq(struct dvb_frontend *fe, u32 freq /* in HZ */,*/ switch (new_type) {case V4L2_TUNER_ANALOG_TV : +case V4L2_TUNER_RADIO : rc = send_seq(priv, {0x00, 0x00}); -/* Analog mode requires offset = 0 */ -break ; -case V4L2_TUNER_RADIO : -/* Radio mode requires offset = 0 */ +/* Analog modes requires offset = 0 */ break ;case V4L2_TUNER_DIGITAL_TV :/*
Signature · 1 line
1.7.2.3
Quoted 1 line
From
173991a979f5f75dbbaf38f1b053d50043a40729Mon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Sun, 11 Dec 2011 22:57:58 +0100
Subject: [PATCH 3/7] Fix possible null dereference for Leadtek DTV 3200H XC4000 tuner when no firmware file available.
--- drivers/media/video/cx23885/cx23885-dvb.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-)
drivers/media/video/cx23885/cx23885-dvb.c +5 -0
@@ -940,6 +940,11 @@ static int dvb_register(struct cx23885_tsport *port) fe =dvb_attach (xc4000_attach, fe0->dvb.frontend, &dev->i2c_bus[1 ].i2c_adap, &cfg); +if (!fe) { +printk (KERN_ERR "%s/2: xc4000 attach failed\n" , + dev->name); + goto frontend_detach; + } }break ;case CX23885_BOARD_TBS_6920 :
Signature · 1 line
1.7.2.3
Quoted 1 line
From
bfd6d08e3756fb0d4ea917cb8f9379b2ba9c5087Mon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Sun, 11 Dec 2011 23:00:06 +0100
Subject: [PATCH 4/7] All radio tuners in cx88 driver using same address for radio and tuner, so there is no need to probe
it twice for same tuner and we can use radio_type UNSET, this also fix broken radio since kernel 2.6.39-rc1 for those tuners.
--- drivers/media/video/cx88/cx88-cards.c | 24 ++++++++++++------------ 1 files changed, 12 insertions(+), 12 deletions(-)
drivers/media/video/cx88/cx88-cards.c +12 -12
@@ -1573,8 +1573,8 @@ static const struct cx88_board cx88_boards[] = { .name = "Pinnacle Hybrid PCTV", .tuner_type = TUNER_XC2028, .tuner_addr = 0x61, - .radio_type = TUNER_XC2028, - .radio_addr = 0x61, + .radio_type = UNSET, + .radio_addr = ADDR_UNSET, .input = { { .type = CX88_VMUX_TELEVISION, .vmux = 0,
@@ -1611,8 +1611,8 @@ static const struct cx88_board cx88_boards[] = { .name = "Leadtek TV2000 XP Global", .tuner_type = TUNER_XC2028, .tuner_addr = 0x61, - .radio_type = TUNER_XC2028, - .radio_addr = 0x61, + .radio_type = UNSET, + .radio_addr = ADDR_UNSET, .input = { { .type = CX88_VMUX_TELEVISION, .vmux = 0,
@@ -2043,8 +2043,8 @@ static const struct cx88_board cx88_boards[] = { .name = "Terratec Cinergy HT PCI MKII", .tuner_type = TUNER_XC2028, .tuner_addr = 0x61, - .radio_type = TUNER_XC2028, - .radio_addr = 0x61, + .radio_type = UNSET, + .radio_addr = ADDR_UNSET, .input = { { .type = CX88_VMUX_TELEVISION, .vmux = 0,
@@ -2082,9 +2082,9 @@ static const struct cx88_board cx88_boards[] = { [CX88_BOARD_WINFAST_DTV1800H] = { .name = "Leadtek WinFast DTV1800 Hybrid", .tuner_type = TUNER_XC2028, - .radio_type = TUNER_XC2028, + .radio_type = UNSET, .tuner_addr = 0x61, - .radio_addr = 0x61, + .radio_addr = ADDR_UNSET,/* * GPIO setting *
@@ -2123,9 +2123,9 @@ static const struct cx88_board cx88_boards[] = { [CX88_BOARD_WINFAST_DTV1800H_XC4000] = { .name = "Leadtek WinFast DTV1800 H (XC4000)", .tuner_type = TUNER_XC4000, - .radio_type = TUNER_XC4000, + .radio_type = UNSET, .tuner_addr = 0x61, - .radio_addr = 0x61, + .radio_addr = ADDR_UNSET,/* * GPIO setting *
@@ -2164,9 +2164,9 @@ static const struct cx88_board cx88_boards[] = { [CX88_BOARD_WINFAST_DTV2000H_PLUS] = { .name = "Leadtek WinFast DTV2000 H PLUS", .tuner_type = TUNER_XC4000, - .radio_type = TUNER_XC4000, + .radio_type = UNSET, .tuner_addr = 0x61, - .radio_addr = 0x61, + .radio_addr = ADDR_UNSET,/* * GPIO * 2: 1: mute audio
Signature · 1 line
1.7.2.3
Quoted 1 line
From
e8f226b66dc58399a8daf808ba204ec9562abd85Mon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Mon, 12 Dec 2011 00:16:22 +0100
Subject: [PATCH 5/7] Fix mode mask setting in tuner_core for radio only tuners.
--- drivers/media/video/tuner-core.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/media/video/tuner-core.c +2 -2
@@ -317,13 +317,13 @@ static void set_type(struct i2c_client *c, unsigned int type,if (!dvb_attach (tea5767_attach, &t->fe, t->i2c->adapter, t->i2c->addr)) goto attach_failed; - t->mode_mask =T_RADIO ; + new_mode_mask =T_RADIO ;break ;case TUNER_TEA5761 :if (!dvb_attach (tea5761_attach, &t->fe, t->i2c->adapter, t->i2c->addr)) goto attach_failed; - t->mode_mask =T_RADIO ; + new_mode_mask =T_RADIO ;break ;case TUNER_PHILIPS_FMD1216ME_MK3 : buffer[0 ] =0x0b ;
Signature · 1 line
1.7.2.3
Quoted 1 line
From
57d785e912c369f2ace56bd5000f99f968d87a9eMon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Mon, 12 Dec 2011 00:19:34 +0100
Subject: [PATCH 6/7] All radio tuners in cx83885 driver using same address for radio and tuner, so there is no need to probe
it twice for same tuner and we can use radio_type UNSET. Be aware radio support in cx23885 is not yet completed, so this is only minor fix for future support.
--- drivers/media/video/cx23885/cx23885-cards.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/media/video/cx23885/cx23885-cards.c +2 -2
@@ -213,8 +213,8 @@ struct cx23885_board cx23885_boards[] = { .portc = CX23885_MPEG_DVB, .tuner_type = TUNER_XC4000, .tuner_addr = 0x61, - .radio_type = TUNER_XC4000, - .radio_addr = 0x61, + .radio_type = UNSET, + .radio_addr = ADDR_UNSET, .input = {{ .type = CX23885_VMUX_TELEVISION, .vmux = CX25840_VIN2_CH1 |
Signature · 1 line
1.7.2.3
Quoted 1 line
From
f21b0f83b9b51da1664ae0efd4f0d412d681e6faMon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Mon, 12 Dec 2011 00:20:24 +0100
Subject: [PATCH 7/7] Add support for two new types of Leadtek Winfast TV 2000XP tuner, author of
this patch is Istvan Varga. Only resending current reformated version against actual git.
--- drivers/media/video/cx88/cx88-cards.c | 91 +++++++++++++++++++++++++++++++++ drivers/media/video/cx88/cx88-input.c | 4 ++ drivers/media/video/cx88/cx88.h | 2 + 3 files changed, 97 insertions(+), 0 deletions(-)
drivers/media/video/cx88/cx88-cards.c +91 -0
115 lines not on this page · raw message
drivers/media/video/cx88/cx88-input.c +4 -0
@@ -103,6 +103,8 @@ static void cx88_ir_handle_key(struct cx88_IR *ir)case CX88_BOARD_WINFAST_DTV1800H_XC4000 :case CX88_BOARD_WINFAST_DTV2000H_PLUS :case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL : +case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F36 : +case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F43 : gpio = (gpio &0x6ff ) | ((cx_read (MO_GP1_IO ) <<8 ) &0x900 ); auxgpio = gpio;break ;
@@ -302,6 +304,8 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)case CX88_BOARD_WINFAST2000XP_EXPERT :case CX88_BOARD_WINFAST_DTV1000 :case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL : +case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F36 : +case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F43 : ir_codes =RC_MAP_WINFAST ; ir->gpio_addr =MO_GP0_IO ; ir->mask_keycode =0x8f8 ;
drivers/media/video/cx88/cx88.h +2 -0
@@ -244,6 +244,8 @@ extern const struct sram_channel const cx88_sram_channels[];#define CX88_BOARD_TEVII_S464 86#define CX88_BOARD_WINFAST_DTV2000H_PLUS 87#define CX88_BOARD_WINFAST_DTV1800H_XC4000 88 +#define CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F36 89 +#define CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F43 90enum cx88_itype {CX88_VMUX_COMPOSITE1 =1 ,
Signature · 1 line
1.7.2.3
Quoted 1 line
From
f21b0f83b9b51da1664ae0efd4f0d412d681e6faMon Sep 17 00:00:00 2001
From: Miroslav Slugeň <[email protected]>
Date: Mon, 12 Dec 2011 00:20:45 +0100
Subject: [PATCH 0/7] *** SUBJECT HERE ***
*** BLURB HERE ***
Miroslav Slugeň (7):
Update xc4000 tuner definition, number 81 is already in use by
TUNER_PARTSNIC_PTI_5NF05
Put analog radio and analog TV together both required same offset. Fix possible null dereference for Leadtek DTV 3200H XC4000 tuner when
no firmware file available.
All radio tuners in cx88 driver using same address for radio and
tuner, so there is no need to probe it twice for same tuner and
we can use radio_type UNSET, this also fix broken radio since
kernel 2.6.39-rc1 for those tuners.
Fix mode mask setting in tuner_core for radio only tuners. All radio tuners in cx83885 driver using same address for radio and
tuner, so there is no need to probe it twice for same tuner and
we can use radio_type UNSET. Be aware radio support in cx23885 is
not yet completed, so this is only minor fix for future
support.
Add support for two new types of Leadtek Winfast TV 2000XP tuner,
author of this patch is Istvan Varga. Only resending current
reformated version against actual git.
drivers/media/common/tuners/tuner-xc2028.c | 6 +- drivers/media/video/cx23885/cx23885-cards.c | 4 +- drivers/media/video/cx23885/cx23885-dvb.c | 5 + drivers/media/video/cx88/cx88-cards.c | 115 ++++++++++++++++++++++++--- drivers/media/video/cx88/cx88-input.c | 4 + drivers/media/video/cx88/cx88.h | 2 + drivers/media/video/tuner-core.c | 4 +- include/media/tuner.h | 3 +- 8 files changed, 122 insertions(+), 21 deletions(-)
Signature · 1 line
1.7.2.3