Skip to content

Commit

Permalink
StarBlzer SB340,540 support.
Browse files Browse the repository at this point in the history
  • Loading branch information
crazycat69 committed Jun 15, 2013
1 parent 5e119be commit 3fe75c5
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 7 deletions.
28 changes: 27 additions & 1 deletion linux/drivers/media/dvb/dvb-usb/dw2102.c
@@ -1,6 +1,7 @@
/* DVB USB framework compliant Linux driver for the
* DVBWorld DVB-S 2101, 2102, DVB-S2 2104, DVB-C 3101,
* TeVii S600, S630, S650, S660, S480, S421, S632
* TeVii S600, S630, S650, S660, S480, S421, S632,
* StarBlazer SB340,
* Prof 1100, 7500,
* Geniatech SU3000, T220 Cards
* Copyright (C) 2008-2011 Igor M. Liplianin (liplianin@me.by)
Expand Down Expand Up @@ -1796,6 +1797,7 @@ enum dw2102_table_entry {
TEVII_S630,
PROF_1100,
TEVII_S660,
STARBLAZER_SB340,
PROF_7500,
GENIATECH_SU3000,
TERRATEC_CINERGY_S2,
Expand All @@ -1820,6 +1822,7 @@ static struct usb_device_id dw2102_table[] = {
[TEVII_S630] = {USB_DEVICE(0x9022, USB_PID_TEVII_S630)},
[PROF_1100] = {USB_DEVICE(0x3011, USB_PID_PROF_1100)},
[TEVII_S660] = {USB_DEVICE(0x9022, USB_PID_TEVII_S660)},
[STARBLAZER_SB340] = {USB_DEVICE(0x9022, 0xd662)},
[PROF_7500] = {USB_DEVICE(0x3034, 0x7500)},
[GENIATECH_SU3000] = {USB_DEVICE(0x1f4d, 0x3000)},
[TERRATEC_CINERGY_S2] = {USB_DEVICE(USB_VID_TERRATEC, 0x00a8)},
Expand Down Expand Up @@ -2150,6 +2153,7 @@ static struct dvb_usb_device_description d660 = {
{NULL},
};


static struct dvb_usb_device_description d480_1 = {
"TeVii S480.1 USB",
{&dw2102_table[TEVII_S480_1], NULL},
Expand All @@ -2162,6 +2166,13 @@ static struct dvb_usb_device_description d480_2 = {
{NULL},
};

struct dvb_usb_device_properties *sb340;
static struct dvb_usb_device_description d662 = {
"StarBlazer SB340 USB",
{&dw2102_table[STARBLAZER_SB340], NULL},
{NULL},
};

struct dvb_usb_device_properties *p7500;
static struct dvb_usb_device_description d7500 = {
"Prof 7500 USB DVB-S2",
Expand Down Expand Up @@ -2404,6 +2415,18 @@ static int dw2102_probe(struct usb_interface *intf,
s660->devices[2] = d480_2;
s660->adapter->frontend_attach = ds3000_frontend_attach;

sb340 = kzalloc(sizeof(struct dvb_usb_device_properties), GFP_KERNEL);
if (!sb340) {
kfree(p1100);
return -ENOMEM;
}
memcpy(sb340, &s6x0_properties,
sizeof(struct dvb_usb_device_properties));
sb340->firmware = "dvb-usb-sb340.fw";
sb340->num_device_descs = 1;
sb340->devices[0] = d662;
sb340->adapter->frontend_attach = ds3000_frontend_attach;

p7500 = kzalloc(sizeof(struct dvb_usb_device_properties), GFP_KERNEL);
if (!p7500) {
kfree(p1100);
Expand Down Expand Up @@ -2444,6 +2467,8 @@ static int dw2102_probe(struct usb_interface *intf,
THIS_MODULE, NULL, adapter_nr) ||
0 == dvb_usb_device_init(intf, s660,
THIS_MODULE, NULL, adapter_nr) ||
0 == dvb_usb_device_init(intf, sb340,
THIS_MODULE, NULL, adapter_nr) ||
0 == dvb_usb_device_init(intf, p7500,
THIS_MODULE, NULL, adapter_nr) ||
0 == dvb_usb_device_init(intf, s421,
Expand Down Expand Up @@ -2489,6 +2514,7 @@ MODULE_AUTHOR("Igor M. Liplianin (c) liplianin@me.by");
MODULE_DESCRIPTION("Driver for DVBWorld DVB-S 2101, 2102, DVB-S2 2104,"
" DVB-C 3101 USB2.0,"
" TeVii S600, S630, S650, S660, S480, S421, S632"
" StarBlazer SB340 USB2.0,"
" Prof 1100, 7500 USB2.0,"
" Geniatech SU3000, T220 devices");
MODULE_VERSION("0.1");
Expand Down
17 changes: 17 additions & 0 deletions linux/drivers/media/video/cx88/cx88-cards.c
Expand Up @@ -1966,6 +1966,18 @@ static const struct cx88_board cx88_boards[] = {
} },
.mpeg = CX88_MPEG_DVB,
},
[CX88_BOARD_SB_540] = {
.name = "StarBlazer SB540 DVB-S/S2",
.tuner_type = UNSET,
.radio_type = UNSET,
.tuner_addr = ADDR_UNSET,
.radio_addr = ADDR_UNSET,
.input = {{
.type = CX88_VMUX_DVB,
.vmux = 0,
} },
.mpeg = CX88_MPEG_DVB,
},
[CX88_BOARD_OMICOM_SS4_PCI] = {
.name = "Omicom SS4 DVB-S/S2 PCI",
.tuner_type = UNSET,
Expand Down Expand Up @@ -2676,6 +2688,10 @@ static const struct cx88_subid cx88_subids[] = {
.subvendor = 0xd464,
.subdevice = 0x9022,
.card = CX88_BOARD_TEVII_S464,
}, {
.subvendor = 0x0540,
.subdevice = 0x9022,
.card = CX88_BOARD_SB_540,
}, {
.subvendor = 0xA044,
.subdevice = 0x2011,
Expand Down Expand Up @@ -3489,6 +3505,7 @@ static void cx88_card_setup(struct cx88_core *core)
case CX88_BOARD_TEVII_S420:
case CX88_BOARD_TEVII_S460:
case CX88_BOARD_TEVII_S464:
case CX88_BOARD_SB_540:
case CX88_BOARD_OMICOM_SS4_PCI:
case CX88_BOARD_TBS_8910:
case CX88_BOARD_TBS_8920:
Expand Down
1 change: 1 addition & 0 deletions linux/drivers/media/video/cx88/cx88-dvb.c
Expand Up @@ -1526,6 +1526,7 @@ static int dvb_register(struct cx8802_dev *dev)
fe0->dvb.frontend->ops.set_voltage = tbs_dvbs_set_voltage;
break;
case CX88_BOARD_TEVII_S464:
case CX88_BOARD_SB_540:
fe0->dvb.frontend = dvb_attach(ds3000_attach,
&tevii_ds3000_config,
&core->i2c_adap);
Expand Down
1 change: 1 addition & 0 deletions linux/drivers/media/video/cx88/cx88-input.c
Expand Up @@ -382,6 +382,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_TEVII_S464:
case CX88_BOARD_TEVII_S460:
case CX88_BOARD_TEVII_S420:
case CX88_BOARD_SB_540:
ir_codes = RC_MAP_TEVII_NEC;
ir->sampling = 0xff00; /* address */
break;
Expand Down
12 changes: 7 additions & 5 deletions linux/drivers/media/video/cx88/cx88.h
Expand Up @@ -245,11 +245,13 @@ extern const struct sram_channel const cx88_sram_channels[];
#define CX88_BOARD_SAMSUNG_SMT_7020 84
#define CX88_BOARD_TWINHAN_VP1027_DVBS 85
#define CX88_BOARD_TEVII_S464 86
#define CX88_BOARD_WINFAST_DTV2000H_PLUS 87
#define CX88_BOARD_WINFAST_DTV1800H_XC4000 88
#define CX88_BOARD_TBS_8921 89
#define CX88_BOARD_TBS_8922 90
#define CX88_BOARD_BST_PS8312 91
#define CX88_BOARD_SB_540 87
#define CX88_BOARD_WINFAST_DTV2000H_PLUS 88
#define CX88_BOARD_WINFAST_DTV1800H_XC4000 89
#define CX88_BOARD_TBS_8921 90
#define CX88_BOARD_TBS_8922 91
#define CX88_BOARD_BST_PS8312 92


enum cx88_itype {
CX88_VMUX_COMPOSITE1 = 1,
Expand Down
2 changes: 1 addition & 1 deletion v4l/firmware/Makefile
Expand Up @@ -4,7 +4,7 @@ TARGETS = vicam/firmware.fw dabusb/firmware.fw dabusb/bitstream.bin ttusb-budget
dvb-usb-tbsqbox-id2601.fw dvb-usb-tbsqbox-id5910.fw dvb-usb-tbsqbox-id5920.fw dvb-usb-tbsqbox-id5925.fw dvb-usb-tbsqbox-id5980.fw \
dvb-usb-tbsqbox-id5921.fw dvb-usb-tbsqbox-id5922.fw dvb-usb-tbsqbox-id5928.fw \
dvb-usb-tbsqbox-dvbc.fw dvb-usb-tbsqbox-id5680.fw dvb-usb-tbsqbox-id5880.fw \
dvb-usb-p1100.fw dvb-usb-p1100-old.fw dvb-usb-p7500.fw dvb-usb-s620.fw dvb-usb-s630.fw dvb-usb-s660.fw \
dvb-usb-p1100.fw dvb-usb-p1100-old.fw dvb-usb-p7500.fw dvb-usb-s620.fw dvb-usb-s630.fw dvb-usb-s660.fw dvb-usb-sb340.fw \
dvb-demod-drxk-pctv.fw dvb-fe-tda10045.fw dvb-fe-tda10046.fw dvb-fe-tda10048-1.0.fw dvb-fe-tda10071.fw \
dvb-usb-tt-s2400-01.fw dvb-usb-pctv-400e-01.fw dvb-usb-pctv-450e-01.fw dvb-usb-pctv-452e-01.fw \
dvb-usb-SkyStar_USB_HD_FW_v17_63.HEX.fw
Expand Down

0 comments on commit 3fe75c5

Please sign in to comment.