V4L/DVB updates
cover V4L/DVB updates
This patch series is also available under v4l-dvb.git tree at:
kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb.git
Linus, please pull these from master branch.
It contains the following stuff:
- Kconfig: DVB_USB_CXUSB depends on DVB_LGDT330X and DVB_MT352
- Fix NICAM buzz on analog sound
- Added signal detection support to tvp5150
- Fix [Bug 5895] to correct snd_87x autodetect
- Add IR support to KWorld DVB-T (cx22702-based)
- Add standard for South Korean NTSC-M using A2 audio.
- Fixed i2c return value, conversion mdelay to msleep
- Support for Galaxis DVB-S rev1.3
- Use parallel transport for FusionHDTV Dual Digital USB
- Use MT352 parallel transport function for all Bluebird FusionHDTV DVB-T boxes.
- FIX: Multiple usage of VP7045-based devices
- FIX: Check if FW was downloaded or not + new firmware file
- Makes Some symbols static.
- fix saa7146 kobject register failure
- DVB: remove the at76c651/tda80xx frontends
- Disabled debug on by default in tvp5150
The following stuff is also pending to be pulled from v4l-dvb.git:
- Activate remote control on HVR1100
- Add bttv card MagicTV (rebranded MachTV)
- whitespace cleanup: insert missing space before curly brackets
- More whitespace cleanup in bttv-cards.c
- Add support for DViCO FusionHDTV DVB-T USB devices
- Conversions from kmalloc+memset to k(z|c)alloc
- don't ignore return from i2c_add_driver() for tuner-3036
- Pci probing for stradis driver
- Stradis video little cleanup
- Enable microtune for Pinnacle 300i boards
- Stradis Lindent
- Stradis Kconfig url changed
- Fixes some bad global variables
- debug renamed to cx25840_debug
- Add PCI ID for UltraView DVB-T Plus, rebranded DViCO FusionHDTV DVB-T Plus
- Added USB ID for DigitalNow DVB-T Dual USB, DViCO clone
- adding support for knc1 Tv Star dvb-s
- Some fixes to compat_ioctl32
- VIDEO_SAA7134_ALSA shouldn't select SND_PCM_OSS
Cheers,
Mauro
Diffstat from newer stuff follows.
---
drivers/media/dvb/bt8xx/bt878.c | 44 + drivers/media/dvb/bt8xx/bt878.h | 17 drivers/media/dvb/dvb-usb/Kconfig | 12 drivers/media/dvb/dvb-usb/cxusb.c | 4 drivers/media/dvb/dvb-usb/digitv.c | 13 drivers/media/dvb/dvb-usb/vp7045-fe.c | 6 drivers/media/dvb/frontends/Kconfig | 12 drivers/media/dvb/frontends/Makefile | 2 drivers/media/dvb/frontends/at76c651.c | 450 ------------ drivers/media/dvb/frontends/at76c651.h | 47 - drivers/media/dvb/frontends/tda80xx.c | 734 --------------------- drivers/media/dvb/frontends/tda80xx.h | 51 - drivers/media/dvb/ttpci/av7110.c | 14 drivers/media/video/bttv-driver.c | 2 drivers/media/video/cx25840/cx25840-core.c | 50 - drivers/media/video/cx88/cx88-alsa.c | 6 drivers/media/video/cx88/cx88-core.c | 10 drivers/media/video/cx88/cx88-input.c | 1 drivers/media/video/em28xx/em28xx-core.c | 15 drivers/media/video/em28xx/em28xx-i2c.c | 8 drivers/media/video/hexium_orion.c | 2 drivers/media/video/tda9887.c | 7 drivers/media/video/tuner-core.c | 5 drivers/media/video/tvp5150.c | 11 include/linux/videodev2.h | 4 25 files changed, 170 insertions(+), 1357 deletions(-)
PATCH 1/16 Kconfig: DVB_USB_CXUSB depends on DVB_LGDT330X and DVB_MT352
From: Michael Krufky <[email protected]>
- rename DVB_USB_CXUSB one-liner description to:
Conexant USB2.0 hybrid reference design support.
- with the addition of bluebird support to dvb-usb-cxusb, it now depends on lgdt330x and mt352 modules.
---
drivers/media/dvb/dvb-usb/Kconfig | 12 +++++++++--- 1 files changed, 9 insertions(+), 3 deletions(-)
drivers/media/dvb/dvb-usb/Kconfig +9 -3
@@ -83,12 +83,18 @@ config DVB_USB_UMT_010 Say Y here to support the HanfTek UMT-010 USB2.0 stick-sized DVB-T receiver. config DVB_USB_CXUSB - tristate "Medion MD95700 hybrid USB2.0 (Conexant) support" + tristate "Conexant USB2.0 hybrid reference design support" depends on DVB_USB select DVB_CX22702 + select DVB_LGDT330X + select DVB_MT352 help - Say Y here to support the Medion MD95700 hybrid USB2.0 device. Currently - only the DVB-T part is supported. + Say Y here to support the Conexant USB2.0 hybrid reference design. + Currently, only DVB and ATSC modes are supported, analog mode + shall be added in the future. Devices that require this module: + + Medion MD95700 hybrid USB2.0 device. + DViCO FusionHDTV (Bluebird) USB2.0 devices config DVB_USB_DIGITV tristate "Nebula Electronics uDigiTV DVB-T USB2.0 support"
PATCH 2/16 Fix NICAM buzz on analog sound
In reply to [email protected]From: Marcin Rudowski <[email protected]>
Apparently, having the number of lines fixed at 4 reduces (or even kills) the buzz found in NICAM stereo with analog sound.
---
drivers/media/video/cx88/cx88-core.c | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-)
drivers/media/video/cx88/cx88-core.c +6 -4
@@ -787,12 +787,14 @@ static int set_pll(struct cx88_core *corint cx88_start_audio_dma (struct cx88_core *core) { +/* constant 128 made buzz in analog Nicam-stereo for bigger fifo_size */ +int bpl = cx88_sram_channels[SRAM_CH25 ].fifo_size/4 ;/* setup fifo + format */ -cx88_sram_channel_setup (core, &cx88_sram_channels[SRAM_CH25 ],128 ,0 ); -cx88_sram_channel_setup (core, &cx88_sram_channels[SRAM_CH26 ],128 ,0 ); +cx88_sram_channel_setup (core, &cx88_sram_channels[SRAM_CH25 ], bpl,0 ); +cx88_sram_channel_setup (core, &cx88_sram_channels[SRAM_CH26 ], bpl,0 ); -cx_write (MO_AUDD_LNGTH ,128 );/* fifo bpl size */ -cx_write (MO_AUDR_LNGTH ,128 );/* fifo bpl size */ +cx_write (MO_AUDD_LNGTH , bpl);/* fifo bpl size */ +cx_write (MO_AUDR_LNGTH , bpl);/* fifo bpl size */ /* start dma */ cx_write (MO_AUD_DMACNTRL ,0x0003 );/* Up and Down fifo enable */
PATCH 3/16 Added signal detection support to tvp5150
In reply to [email protected]From: Markus Rechberger <[email protected]>
- added signal detection support to tvp5150
---
drivers/media/video/tvp5150.c | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-)
drivers/media/video/tvp5150.c +11 -0
@@ -896,6 +896,17 @@ static int tvp5150_command(struct i2c_cl }case DECODER_GET_STATUS : { +int *iarg = arg; +int status; +int res=0 ; + status =tvp5150_read (c,0x88 ); +if (status&0x08 ){ + res |=DECODER_STATUS_COLOR ; + } +if (status&0x04 && status&0x02 ){ + res |=DECODER_STATUS_GOOD ; + } + *iarg=res;break ; }
PATCH 4/16 Fix [Bug 5895] to correct snd_87x autodetect
In reply to [email protected]From: Manu Abraham <[email protected]>
With DVB drivers enabled snd_87x (ALSA) don't detect.
---
drivers/media/dvb/bt8xx/bt878.c | 44 ++++++++++++++++++++++++++++++++++++++- drivers/media/dvb/bt8xx/bt878.h | 17 +++++++++++++++ 2 files changed, 60 insertions(+), 1 deletions(-)
drivers/media/dvb/bt8xx/bt878.c +43 -1
@@ -381,6 +381,23 @@ bt878_device_control(struct bt878 *bt, uEXPORT_SYMBOL (bt878_device_control); + +struct cards card_list[]__devinitdata = { + + {0x01010071 ,BTTV_BOARD_NEBULA_DIGITV ,"Nebula Electronics DigiTV" }, + {0x07611461 ,BTTV_BOARD_AVDVBT_761 ,"AverMedia AverTV DVB-T 761" }, + {0x001c11bd ,BTTV_BOARD_PINNACLESAT ,"Pinnacle PCTV Sat" }, + {0x002611bd ,BTTV_BOARD_TWINHAN_DST ,"Pinnacle PCTV SAT CI" }, + {0x00011822 ,BTTV_BOARD_TWINHAN_DST ,"Twinhan VisionPlus DVB" }, + {0xfc00270f ,BTTV_BOARD_TWINHAN_DST ,"ChainTech digitop DST-1000 DVB-S" }, + {0x07711461 ,BTTV_BOARD_AVDVBT_771 ,"AVermedia AverTV DVB-T 771" }, + {0xdb1018ac ,BTTV_BOARD_DVICO_DVBT_LITE ,"DViCO FusionHDTV DVB-T Lite" }, + {0xd50018ac ,BTTV_BOARD_DVICO_FUSIONHDTV_5_LITE ,"DViCO FusionHDTV 5 Lite" }, + {0x20007063 ,BTTV_BOARD_PC_HDTV ,"pcHDTV HD-2000 TV" }, + {0 ,-1 ,NULL } +}; + +/***********************/ /* PCI device handling */ /***********************/
@@ -388,18 +405,41 @@ EXPORT_SYMBOL(bt878_device_control);static int __devinit bt878_probe (struct pci_dev *dev,const struct pci_device_id *pci_id) { -int result; +int result =0 , has_dvb =0 , i;unsigned char lat;struct bt878 *bt;#if defined(__powerpc__)unsigned int cmd;#endif +unsigned int cardid; +unsigned short id; +struct cards *dvb_cards;printk (KERN_INFO "bt878: Bt878 AUDIO function found (%d).\n" , bt878_num);if (pci_enable_device (dev))return -EIO ; +pci_read_config_word (dev,PCI_SUBSYSTEM_ID , &id); + cardid = id <<16 ; +pci_read_config_word (dev,PCI_SUBSYSTEM_VENDOR_ID , &id); + cardid |= id; + +for (i =0 , dvb_cards = card_list; i <ARRAY_SIZE (card_list); i++, dvb_cards++) { +if (cardid == dvb_cards->pci_id) { +printk ("%s: card id=[0x%x],[ %s ] has DVB functions.\n" , + __func__, cardid, dvb_cards->name); + has_dvb =1 ; + } + } + +if (!has_dvb) { +printk ("%s: card id=[0x%x], Unknown card.\nExiting..\n" , __func__, cardid); + result = -EINVAL ; + + goto fail0; + } + bt = &bt878[bt878_num]; bt->dev = dev; bt->nr = bt878_num;
@@ -416,6 +456,8 @@ static int __devinit bt878_probe(structpci_read_config_byte (dev,PCI_CLASS_REVISION , &bt->revision);pci_read_config_byte (dev,PCI_LATENCY_TIMER , &lat); + +printk (KERN_INFO "bt878(%d): Bt%x (rev %d) at %02x:%02x.%x, " , bt878_num, bt->id, bt->revision, dev->bus->number,PCI_SLOT (dev->devfn),PCI_FUNC (dev->devfn));
drivers/media/dvb/bt8xx/bt878.h +17 -0
@@ -88,6 +88,23 @@#define BT878_RISC_SYNC_MASK (1 << 15) + +#define BTTV_BOARD_UNKNOWN 0x00 +#define BTTV_BOARD_PINNACLESAT 0x5e +#define BTTV_BOARD_NEBULA_DIGITV 0x68 +#define BTTV_BOARD_PC_HDTV 0x70 +#define BTTV_BOARD_TWINHAN_DST 0x71 +#define BTTV_BOARD_AVDVBT_771 0x7b +#define BTTV_BOARD_AVDVBT_761 0x7c +#define BTTV_BOARD_DVICO_DVBT_LITE 0x80 +#define BTTV_BOARD_DVICO_FUSIONHDTV_5_LITE 0x87 + +struct cards { +__u32 pci_id; +__u16 card_id; +char *name; +}; +extern int bt878_num;struct bt878 {
Re: [PATCH 04/16] Fix [Bug 5895] to correct snd_87x autodetect
drivers/media/dvb/bt8xx/bt878.c bt878_device_control(struct bt878 *bt, u · line 388
Quoted 13 lines · [email protected] wrote:
drivers/media/dvb/bt8xx/bt878.c +5
-0@@ -381,6 +381,23 @@ bt878_device_control(struct bt878 *bt, uEXPORT_SYMBOL (bt878_device_control); + +struct cards card_list[]__devinitdata = { + + {0x01010071 ,BTTV_BOARD_NEBULA_DIGITV ,"Nebula Electronics DigiTV" }, + {0x07611461 ,BTTV_BOARD_AVDVBT_761 ,"AverMedia AverTV DVB-T 761" },
I'm not very familiar with the pci configuration logic but what's the point of this list and the BTTV_BOARD_xxx defines? The defines are never used and the list is only used to let the probe routine fail when the device is not in the list.
Wouldn't it be cleaner to add them to the pci_device_id list further down instead of requesting all subsystem ids?
| static struct pci_device_id bt878_pci_tbl[] __devinitdata = {
| {PCI_VENDOR_ID_BROOKTREE, PCI_DEVICE_ID_BROOKTREE_878,
| PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0},
| {0,}
| };Anyway, the bttv driver already has this information in his card list (field has_dvb). As long as the bt878 isn't stand alone and requires the bttv driver wouldn't it be better to query its table?
Even if this table is kept, it should be static and the variable card_id in the probe routine should be renamed to pci_id as it does not hold the card_id as defined in struct card but the pci_id.
Ciao, ET.
Re: [PATCH 04/16] Fix [Bug 5895] to correct snd_87x autodetect
Quoted 8 lines · Edgar Toernig
Quoted 6 lines · [email protected] wrote:
drivers/media/dvb/bt8xx/bt878.c +0
-0@@ -381,6 +381,23 @@ bt878_device_control(struct bt878 *bt, uEXPORT_SYMBOL (bt878_device_control);
Quoted 13 lines
drivers/media/dvb/bt8xx/bt878.c bt878_device_control(struct bt878 *bt, u · line 388
Quoted 7 lines
drivers/media/dvb/bt8xx/bt878.c +5
-0+ +struct cards card_list[]__devinitdata = { + + {0x01010071 ,BTTV_BOARD_NEBULA_DIGITV ,"Nebula Electronics DigiTV" }, + {0x07611461 ,BTTV_BOARD_AVDVBT_761 ,"AverMedia AverTV DVB-T 761" },I'm not very familiar with the pci configuration logic but what's the point of this list and the
BTTV_BOARD_xxxdefines? The defines are never used and the list is only used to let the probe routine fail when the device is not in the list.
Yes, that's the idea. The naming is for identification in the failed case.
Quoted 6 lines
Anyway, the bttv driver already has this information in his card list (field
has_dvb). As long as the bt878 isn't stand alone and requires the bttv driver wouldn't it be better to query its table?
This is only the interim fix for bug [5895] prior to the merge, as was discussed on the linux-dvb and video4linux mailing lists.
Thread: [linux-dvb] Re: [Fwd: [Bug 5895] With DVB drivers enabled snd_87x (ALSA) don't detect Broooktree audio]
Quoted 2 lines
Even if this table is kept, it should be static
Ack'd.
Thanks,
Manu
PATCH 5/16 Add IR support to KWorld DVB-T (cx22702-based)
In reply to [email protected]From: Marco Manenti <[email protected]>
add IR support to KWorld DVB-T (cx22702-based)
---
drivers/media/video/cx88/cx88-input.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/media/video/cx88/cx88-input.c +1 -0
@@ -482,6 +482,7 @@ int cx88_ir_init(struct cx88_core *core,switch (core->board) {case CX88_BOARD_DNTV_LIVE_DVB_T :case CX88_BOARD_KWORLD_DVB_T : +case CX88_BOARD_KWORLD_DVB_T_CX22702 : ir_codes = ir_codes_dntv_live_dvb_t; ir->gpio_addr =MO_GP1_IO ; ir->mask_keycode =0x1f ;
PATCH 6/16 Add standard for South Korean NTSC-M using A2 audio.
In reply to [email protected]From: Hans Verkuil <[email protected]>
South Korea uses NTSC-M but with A2 audio instead of BTSC. Several audio chips need this information in order to set the correct audio processing registers.
---
drivers/media/video/bttv-driver.c | 2 + drivers/media/video/cx25840/cx25840-core.c | 50 +++++++++++----------------- drivers/media/video/tda9887.c | 7 +++- drivers/media/video/tuner-core.c | 5 +++ include/linux/videodev2.h | 4 ++ 5 files changed, 35 insertions(+), 33 deletions(-)
drivers/media/video/bttv-driver.c +1 -1
@@ -214,7 +214,7 @@ const struct bttv_tvnorm bttv_tvnorms[]we can capture, of the first and second field. */ .vbistart = { 7,320 }, },{ - .v4l2_id =V4L2_STD_NTSC_M , + .v4l2_id =V4L2_STD_NTSC_M |V4L2_STD_NTSC_M_KR , .name = "NTSC", .Fsc = 28636363, .swidth = 768,
drivers/media/video/cx25840/cx25840-core.c +20 -30
77 lines not on this page · raw message
drivers/media/video/tda9887.c +6 -1
@@ -231,7 +231,7 @@ static struct tvnorm tvnorms[] = { cAudioIF_6_5 | cVideoIF_38_90 ), },{ - .std = V4L2_STD_NTSC_M, + .std = V4L2_STD_NTSC_M | V4L2_STD_NTSC_M_KR, .name = "NTSC-M", .b = ( cNegativeFmTV | cQSS ),
@@ -619,6 +619,11 @@ static int tda9887_fixup_std(struct tda9tda9887_dbg ("insmod fixup: NTSC => NTSC_M_JP\n" ); t->std =V4L2_STD_NTSC_M_JP ;break ; +case 'k' : +case 'K' : +tda9887_dbg ("insmod fixup: NTSC => NTSC_M_KR\n" ); + t->std =V4L2_STD_NTSC_M_KR ; +break ;case '-' :/* default parameter, do nothing */ break ;
drivers/media/video/tuner-core.c +5 -0
@@ -366,6 +366,11 @@ static int tuner_fixup_std(struct tunertuner_dbg ("insmod fixup: NTSC => NTSC_M_JP\n" ); t->std =V4L2_STD_NTSC_M_JP ;break ; +case 'k' : +case 'K' : +tuner_dbg ("insmod fixup: NTSC => NTSC_M_KR\n" ); + t->std =V4L2_STD_NTSC_M_KR ; +break ;case '-' :/* default parameter, do nothing */ break ;
include/linux/videodev2.h +3 -1
@@ -628,6 +628,7 @@ typedef __u64 v4l2_std_id;#define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000)#define V4L2_STD_NTSC_M_JP ((v4l2_std_id)0x00002000)#define V4L2_STD_NTSC_443 ((v4l2_std_id)0x00004000) +#define V4L2_STD_NTSC_M_KR ((v4l2_std_id)0x00008000)#define V4L2_STD_SECAM_B ((v4l2_std_id)0x00010000)#define V4L2_STD_SECAM_D ((v4l2_std_id)0x00020000)
@@ -660,7 +661,8 @@ typedef __u64 v4l2_std_id; V4L2_STD_PAL_H |\ V4L2_STD_PAL_I)#define V4L2_STD_NTSC (V4L2_STD_NTSC_M |\ - V4L2_STD_NTSC_M_JP) + V4L2_STD_NTSC_M_JP |\ + V4L2_STD_NTSC_M_KR)#define V4L2_STD_SECAM_DK (V4L2_STD_SECAM_D |\ V4L2_STD_SECAM_K |\ V4L2_STD_SECAM_K1)
PATCH 7/16 Fixed i2c return value, conversion mdelay to msleep
In reply to [email protected]From: Markus Rechberger <[email protected]>
fixed i2c return value, conversion mdelay to msleep
---
drivers/media/video/em28xx/em28xx-core.c | 15 +++++++++++++-- drivers/media/video/em28xx/em28xx-i2c.c | 8 ++++---- 2 files changed, 17 insertions(+), 6 deletions(-)
drivers/media/video/em28xx/em28xx-core.c +13 -2
@@ -139,6 +139,9 @@ int em28xx_read_reg_req_len(struct em28x {int ret, byte; +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV ); +em28xx_regdbg ("req=%02x, reg=%02x " , req, reg); ret = usb_control_msg(dev->udev, usb_rcvctrlpipe(dev->udev, 0), req,
@@ -165,6 +168,9 @@ int em28xx_read_reg_req(struct em28xx *du8 val;int ret; +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV ); +em28xx_regdbg ("req=%02x, reg=%02x:" , req, reg); ret = usb_control_msg(dev->udev, usb_rcvctrlpipe(dev->udev, 0), req,
@@ -195,7 +201,12 @@ int em28xx_write_regs_req(struct em28xxint ret;/*usb_control_msg seems to expect a kmalloced buffer */ -unsigned char *bufs =kmalloc (len,GFP_KERNEL ); +unsigned char *bufs; + +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV ); + + bufs =kmalloc (len,GFP_KERNEL );em28xx_regdbg ("req=%02x reg=%02x:" , req, reg);
@@ -212,7 +223,7 @@ int em28xx_write_regs_req(struct em28xx ret =usb_control_msg (dev->udev,usb_sndctrlpipe (dev->udev,0 ), req,USB_DIR_OUT |USB_TYPE_VENDOR |USB_RECIP_DEVICE ,0x0000 , reg, bufs, len,HZ ); -mdelay (5 );/* FIXME: magic number */ +msleep (5 );/* FIXME: magic number */ kfree (bufs);return ret; }
drivers/media/video/em28xx/em28xx-i2c.c +4 -4
@@ -78,7 +78,7 @@ static int em2800_i2c_send_max4(struct e ret = dev->em28xx_read_reg (dev,0x05 );if (ret ==0x80 + len -1 )return len; -mdelay (5 ); +msleep (5 ); }em28xx_warn ("i2c write timed out\n" );return -EIO ;
@@ -138,7 +138,7 @@ static int em2800_i2c_check_for_device(sreturn -ENODEV ; else if (msg == 0x84) return 0; -mdelay (5 ); +msleep (5 ); }return -ENODEV ; }
@@ -278,9 +278,9 @@ static int em28xx_i2c_xfer(struct i2c_ad msgs[i].buf, msgs[i].len, i == num - 1); -if (rc <0 ) - goto err; } +if (rc <0 ) + goto err;if (i2c_debug>=2 )printk ("\n" ); }
Re: [v4l-dvb-maintainer] [PATCH 07/16] Fixed i2c return value, conversion mdelay to msleep
Hi,
drivers/media/video/em28xx/em28xx-core.c int em28xx_read_reg_req(struct em28xx *d · line 172
Quoted 6 lines · On Tue, 2006-02-07 at 13:33 -0200, [email protected] wrote:
drivers/media/video/em28xx/em28xx-core.c +2
-0@@ -165,6 +168,9 @@ int em28xx_read_reg_req(struct em28xx *du8 val;int ret; +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV );
This looks like return was a function and is very uncommon for kernel coding style.
drivers/media/video/em28xx/em28xx-core.c int em28xx_write_regs_req(struct em28xx · line 207
Quoted 13 lines
drivers/media/video/em28xx/em28xx-core.c +5
-1+em28xx_regdbg ("req=%02x, reg=%02x:" , req, reg); ret = usb_control_msg(dev->udev, usb_rcvctrlpipe(dev->udev, 0), req,@@ -195,7 +201,12 @@ int em28xx_write_regs_req(struct em28xxint ret;/*usb_control_msg seems to expect a kmalloced buffer */ -unsigned char *bufs =kmalloc (len,GFP_KERNEL ); +unsigned char *bufs; + +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV );
Same as obove.
Review int em28xx_write_regs_req(struct em28xx · line 209
Quoted 2 lines
(quoted diff) +2
-0+ + bufs = kmalloc(len, GFP_KERNEL);
I think you should add this:
if (bufs == NULL)
return -ENOMEM;Best regards,
Andreas
Re: [v4l-dvb-maintainer] [PATCH 07/16] Fixed i2c return value, conversion mdelay to msleep
Hi,
this is actually not needed but it saves as introduced by Luca Risolia some CPU cycles. USB Devices might come and go whenever the user feels he has to plug or unplug it.
Quoted 29 lines · Andreas Oberritter
Hi,
drivers/media/video/em28xx/em28xx-core.c int em28xx_read_reg_req(struct em28xx *d · line 172
Quoted 6 lines · On Tue, 2006-02-07 at 13:33 -0200, [email protected] wrote:
drivers/media/video/em28xx/em28xx-core.c +2
-0@@ -165,6 +168,9 @@ int em28xx_read_reg_req(struct em28xx *du8 val;int ret; +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV );This looks like return was a function and is very uncommon for kernel coding style.
drivers/media/video/em28xx/em28xx-core.c int em28xx_write_regs_req(struct em28xx · line 207
Quoted 13 lines
drivers/media/video/em28xx/em28xx-core.c +5
-1+em28xx_regdbg ("req=%02x, reg=%02x:" , req, reg); ret = usb_control_msg(dev->udev, usb_rcvctrlpipe(dev->udev, 0), req,@@ -195,7 +201,12 @@ int em28xx_write_regs_req(struct em28xxint ret;/*usb_control_msg seems to expect a kmalloced buffer */ -unsigned char *bufs =kmalloc (len,GFP_KERNEL ); +unsigned char *bufs; + +if (dev->state &DEV_DISCONNECTED ) +return (-ENODEV );Same as obove.
Quoted 7 lines
Review int em28xx_write_regs_req(struct em28xx · line 209
Quoted 2 lines
(quoted diff) +2
-0+ + bufs = kmalloc(len, GFP_KERNEL);I think you should add this:
if (bufs == NULL) return -ENOMEM;
right, submit a patch? :)
Quoted 5 lines
Best regards,
Andreas
Markus
PATCH 8/16 Support for Galaxis DVB-S rev1.3
In reply to [email protected]From: Oliver Endriss <[email protected]>
support for Galaxis DVB-S rev1.3 (subsystem 13c2:0004)
---
drivers/media/dvb/ttpci/av7110.c | 14 +++++++++++++- 1 files changed, 13 insertions(+), 1 deletions(-)
drivers/media/dvb/ttpci/av7110.c +13 -1
@@ -2329,6 +2329,17 @@ static int frontend_init(struct av7110 * av7110->fe =ves1820_attach (&alps_tdbe2_config, &av7110->i2c_adap,read_pwm (av7110));break ; +case 0x0004 :// Galaxis DVB-S rev1.3 +/* ALPS BSRV2 */ + av7110->fe =ves1x93_attach (&alps_bsrv2_config, &av7110->i2c_adap); +if (av7110->fe) { + av7110->fe->ops->diseqc_send_master_cmd = av7110_diseqc_send_master_cmd; + av7110->fe->ops->diseqc_send_burst = av7110_diseqc_send_burst; + av7110->fe->ops->set_tone = av7110_set_tone; + av7110->recover = dvb_s_recover; + } +break ; +case 0x0006 :/* Fujitsu-Siemens DVB-S rev 1.6 */ /* Grundig 29504-451 */ av7110->fe =tda8083_attach (&grundig_29504_451_config, &av7110->i2c_adap);
@@ -2930,6 +2941,7 @@ MAKE_AV7110_INFO(tts_1_3se, "TechnotrenMAKE_AV7110_INFO (ttt,"Technotrend/Hauppauge DVB-T" );MAKE_AV7110_INFO (fsc,"Fujitsu Siemens DVB-C" );MAKE_AV7110_INFO (fss,"Fujitsu Siemens DVB-S rev1.6" ); +MAKE_AV7110_INFO (gxs_1_3,"Galaxis DVB-S rev1.3" );static struct pci_device_id pci_tbl[] = {MAKE_EXTENSION_PCI (fsc,0x110a ,0x0000 ),
@@ -2937,13 +2949,13 @@ static struct pci_device_id pci_tbl[] =MAKE_EXTENSION_PCI (ttt_1_X,0x13c2 ,0x0001 ),MAKE_EXTENSION_PCI (ttc_2_X,0x13c2 ,0x0002 ),MAKE_EXTENSION_PCI (tts_2_X,0x13c2 ,0x0003 ), +MAKE_EXTENSION_PCI (gxs_1_3,0x13c2 ,0x0004 ),MAKE_EXTENSION_PCI (fss,0x13c2 ,0x0006 ),MAKE_EXTENSION_PCI (ttt,0x13c2 ,0x0008 ),MAKE_EXTENSION_PCI (ttc_1_X,0x13c2 ,0x000a ),MAKE_EXTENSION_PCI (tts_2_3,0x13c2 ,0x000e ),MAKE_EXTENSION_PCI (tts_1_3se,0x13c2 ,0x1002 ), -/* MAKE_EXTENSION_PCI(???, 0x13c2, 0x0004), UNDEFINED CARD */ // Galaxis DVB PC-Sat-Carte /* MAKE_EXTENSION_PCI(???, 0x13c2, 0x0005), UNDEFINED CARD */ // Technisat SkyStar1 /* MAKE_EXTENSION_PCI(???, 0x13c2, 0x0009), UNDEFINED CARD */ // TT/Hauppauge WinTV Nexus-CA v????
PATCH 9/16 Use parallel transport for FusionHDTV Dual Digital USB
In reply to [email protected]From: Chris Pascoe <[email protected]>
Use the parallel transport function of the MT352 in USB demodulator of the Dual Digital board.
---
drivers/media/dvb/dvb-usb/cxusb.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/media/dvb/dvb-usb/cxusb.c +1 -1
@@ -234,7 +234,7 @@ static struct dvb_usb_rc_key dvico_mce_rstatic int cxusb_dee1601_demod_init (struct dvb_frontend * fe) { -static u8 clock_config [] = {CLOCK_CTL ,0x38 ,0x38 }; +static u8 clock_config [] = {CLOCK_CTL ,0x38 ,0x28 };static u8 reset [] = {RESET ,0x80 };static u8 adc_ctl_1_cfg [] = {ADC_CTL_1 ,0x40 };static u8 agc_cfg [] = {AGC_TARGET ,0x28 ,0x20 };
PATCH 10/16 Use MT352 parallel transport function for all Bluebird FusionHDTV DVB-T boxes.
In reply to [email protected]From: Michael Krufky <[email protected]>
Use the parallel transport function of the MT352 demodulator in TH7579 and LGZ201 -based FusionHDTV Bluebird usb boxes.
---
drivers/media/dvb/dvb-usb/cxusb.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/media/dvb/dvb-usb/cxusb.c +1 -1
@@ -255,7 +255,7 @@ static int cxusb_dee1601_demod_init(strustatic int cxusb_mt352_demod_init (struct dvb_frontend * fe) {/* used in both lgz201 and th7579 */ -static u8 clock_config [] = {CLOCK_CTL ,0x38 ,0x39 }; +static u8 clock_config [] = {CLOCK_CTL ,0x38 ,0x29 };static u8 reset [] = {RESET ,0x80 };static u8 adc_ctl_1_cfg [] = {ADC_CTL_1 ,0x40 };static u8 agc_cfg [] = {AGC_TARGET ,0x24 ,0x20 };
PATCH 11/16 FIX: Multiple usage of VP7045-based devices
In reply to [email protected]From: Patrick Boettcher <[email protected]>
Reassigning function pointers in a static led to infinite loops when using multiple VP7045-based device at the same time on one system. Using kmalloc'd copies for reassignments is better.
---
drivers/media/dvb/dvb-usb/vp7045-fe.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-)
drivers/media/dvb/dvb-usb/vp7045-fe.c +4 -2
@@ -23,10 +23,11 @@struct vp7045_fe_state {struct dvb_frontend fe; +struct dvb_frontend_ops ops; +struct dvb_usb_device *d; }; -static int vp7045_fe_read_status (struct dvb_frontend * fe,fe_status_t *status) {struct vp7045_fe_state *state = fe->demodulator_priv;
@@ -150,7 +151,8 @@ struct dvb_frontend * vp7045_fe_attach(s goto error; s->d = d; - s->fe.ops = &vp7045_fe_ops; +memcpy (&s->ops, &vp7045_fe_ops,sizeof (struct dvb_frontend_ops )); + s->fe.ops = &s->ops; s->fe.demodulator_priv = s; goto success;
PATCH 12/16 FIX: Check if FW was downloaded or not + new firmware file
In reply to [email protected]From: Patrick Boettcher <[email protected]>
- When a firmware was downloaded dvb_usb_device_init returns NULL for the dvb_usb_device, then nothing should be done with that pointer and device, because it will re-enumerate.
- A new firmware should be used with digitv devices.
- It should make "slave"-devices work and others, too.
---
drivers/media/dvb/dvb-usb/digitv.c | 13 ++++++++----- 1 files changed, 8 insertions(+), 5 deletions(-)
drivers/media/dvb/dvb-usb/digitv.c +8 -5
@@ -175,11 +175,13 @@ static int digitv_probe(struct usb_interif ((ret =dvb_usb_device_init (intf,&digitv_properties,THIS_MODULE ,&d)) ==0 ) {u8 b[4 ] = {0 }; - b[0 ] =1 ; -digitv_ctrl_msg (d,USB_WRITE_REMOTE_TYPE ,0 ,b,4 ,NULL ,0 ); +if (d !=NULL ) {/* do that only when the firmware is loaded */ + b[0 ] =1 ; +digitv_ctrl_msg (d,USB_WRITE_REMOTE_TYPE ,0 ,b,4 ,NULL ,0 ); - b[0 ] =0 ; -digitv_ctrl_msg (d,USB_WRITE_REMOTE ,0 ,b,4 ,NULL ,0 ); + b[0 ] =0 ; +digitv_ctrl_msg (d,USB_WRITE_REMOTE ,0 ,b,4 ,NULL ,0 ); + } }return ret; }
@@ -194,7 +196,7 @@ static struct dvb_usb_properties digitv_ .caps = DVB_USB_IS_AN_I2C_ADAPTER, .usb_ctrl = CYPRESS_FX2, - .firmware = "dvb-usb-digitv-01.fw", + .firmware = "dvb-usb-digitv-02.fw", .size_of_priv = 0,
@@ -229,6 +231,7 @@ static struct dvb_usb_properties digitv_ { &digitv_table[0], NULL }, { NULL }, }, + { NULL }, } };
PATCH 13/16 Makes Some symbols static.
In reply to [email protected]From: Mauro Carvalho Chehab <[email protected]>
Some symbols at cx88-alsa were global. Making those static.
---
drivers/media/video/cx88/cx88-alsa.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-)
drivers/media/video/cx88/cx88-alsa.c +3 -3
@@ -128,7 +128,7 @@ MODULE_PARM_DESC(debug,"enable debug mes* BOARD Specific: Sets audio DMA */ -int _cx88_start_audio_dma (snd_cx88_card_t *chip) +static int _cx88_start_audio_dma (snd_cx88_card_t *chip) {struct cx88_buffer *buf = chip->buf;struct cx88_core *core=chip->core;
@@ -173,7 +173,7 @@ int _cx88_start_audio_dma(snd_cx88_card_/* * BOARD Specific: Resets audio DMA */ -int _cx88_stop_audio_dma (snd_cx88_card_t *chip) +static int _cx88_stop_audio_dma (snd_cx88_card_t *chip) {struct cx88_core *core=chip->core;dprintk (1 ,"Stopping audio DMA\n" );
@@ -613,7 +613,7 @@ static snd_kcontrol_new_t snd_cx88_captu* Only boards with eeprom and byte 1 at eeprom=1 have it */ -struct pci_device_id cx88_audio_pci_tbl[] = { +static struct pci_device_id cx88_audio_pci_tbl[] = { {0x14f1 ,0x8801 ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, {0x14f1 ,0x8811 ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, {0 , }
PATCH 14/16 fix saa7146 kobject register failure
In reply to [email protected]From: Dave Jones <[email protected]>
Whoops.
kobject_register failed for hexium HV-PCI6/Orion (-13)
[<c01d3eb6>] kobject_register+0x31/0x47 [<c023a996>] bus_add_driver+0x4a/0xfd [<c01de3c1>] __pci_register_driver+0x82/0xa4 [<d083400a>] hexium_init_module+0xa/0x47 [hexium_orion] [<c013bdae>] sys_init_module+0x167b/0x1822 [<c01633f7>] do_sync_read+0xb8/0xf3 [<c0133fa3>] autoremove_wake_function+0x0/0x2d [<c0145390>] audit_syscall_entry+0x118/0x13f [<c0106ae2>] do_syscall_trace+0x104/0x14a [<c0103d21>] syscall_call+0x7/0xb
slashes in kobject names aren't allowed.
---
drivers/media/video/hexium_orion.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/media/video/hexium_orion.c +1 -1
@@ -484,7 +484,7 @@ static struct saa7146_ext_vv vv_data = { };static struct saa7146_extension extension = { - .name ="hexium HV-PCI6/Orion" , + .name ="hexium HV-PCI6 Orion" , .flags =0 ,// SAA7146_USE_I2C_IRQ, .pci_tbl = &pci_tbl[0 ],
PATCH 15/16 DVB: remove the at76c651/tda80xx frontends
In reply to [email protected]From: Adrian Bunk <[email protected]>
The at76c651 and tda80xx frontends are currently completely unused, IOW their only effect is making the kernel larger for people accitentially enabling them.
The current in-kernel drivers differ from the drivers at cvs.tuxbox.org, and re-adding them when parts of the dbox2 project get merged should be trivial.
---
drivers/media/dvb/frontends/Kconfig | 12 - drivers/media/dvb/frontends/Makefile | 2 drivers/media/dvb/frontends/at76c651.c | 450 -------------------- drivers/media/dvb/frontends/at76c651.h | 47 -- drivers/media/dvb/frontends/tda80xx.c | 734 -------------------------------- drivers/media/dvb/frontends/tda80xx.h | 51 -- 6 files changed, 0 insertions(+), 1296 deletions(-)
drivers/media/dvb/frontends/Kconfig +0 -12
@@ -28,12 +28,6 @@ config DVB_TDA8083 help A DVB-S tuner module. Say Y when you want to support this frontend. -config DVB_TDA80XX - tristate "Philips TDA8044 or TDA8083 based" - depends on DVB_CORE - help - A DVB-S tuner module. Say Y when you want to support this frontend. - config DVB_MT312 tristate "Zarlink MT312 based" depends on DVB_CORE
@@ -139,12 +133,6 @@ config DVB_DIB3000MC comment "DVB-C (cable) frontends" depends on DVB_CORE -config DVB_ATMEL_AT76C651 - tristate "Atmel AT76C651 based" - depends on DVB_CORE - help - A DVB-C tuner module. Say Y when you want to support this frontend. - config DVB_VES1820 tristate "VLSI VES1820 based" depends on DVB_CORE
drivers/media/dvb/frontends/Makefile +0 -2
@@ -8,7 +8,6 @@ obj-$(CONFIG_DVB_CORE) += dvb-pll.o obj-$(CONFIG_DVB_STV0299) += stv0299.o obj-$(CONFIG_DVB_SP8870) += sp8870.o obj-$(CONFIG_DVB_CX22700) += cx22700.o -obj-$(CONFIG_DVB_ATMEL_AT76C651) += at76c651.o obj-$(CONFIG_DVB_CX24110) += cx24110.o obj-$(CONFIG_DVB_TDA8083) += tda8083.o obj-$(CONFIG_DVB_L64781) += l64781.o
@@ -22,7 +21,6 @@ obj-$(CONFIG_DVB_SP887X) += sp887x.o obj-$(CONFIG_DVB_NXT6000) += nxt6000.o obj-$(CONFIG_DVB_MT352) += mt352.o obj-$(CONFIG_DVB_CX22702) += cx22702.o -obj-$(CONFIG_DVB_TDA80XX) += tda80xx.o obj-$(CONFIG_DVB_TDA10021) += tda10021.o obj-$(CONFIG_DVB_STV0297) += stv0297.o obj-$(CONFIG_DVB_NXT200X) += nxt200x.o
drivers/media/dvb/frontends/at76c651.c deleted +0 -450
450 lines not on this page · raw message
drivers/media/dvb/frontends/at76c651.h deleted +0 -47
47 lines not on this page · raw message
drivers/media/dvb/frontends/tda80xx.c deleted +0 -734
734 lines not on this page · raw message
drivers/media/dvb/frontends/tda80xx.h deleted +0 -51
51 lines not on this page · raw message
PATCH 16/16 Disabled debug on by default in tvp5150
In reply to [email protected]From: Markus Rechberger <[email protected]>
disabled debug on by default in tvp5150
---
0 files changed, 0 insertions(+), 0 deletions(-)