Skip to content

Commit 5564da7

Browse files
committed
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (95 commits) V4L/DVB (9296): Patch to remove warning message during cx88-dvb compilation V4L/DVB (9294): gspca: Add a stop sequence in t613. V4L/DVB (9293): gspca: Separate and fix the sensor dependant sequences in t613. V4L/DVB (9292): gspca: Call the control setting functions at init time in t613. V4L/DVB (9291): gspca: Do not set the white balance temperature by default in t613. V4L/DVB (9290): gspca: Adjust the sensor init sequences in t613. V4L/DVB (9289): gspca: Other sensor identified as om6802 in t613. V4L/DVB (9288): gspca: Write to the USB device and not USB interface in t613. V4L/DVB (9287): gspca: Change the name of the multi bytes write function in t613. V4L/DVB (9286): gspca: Compilation problem of gspca.c and the kernel version. V4L/DVB (9283): Correct typo and enable setting the gain on the mt9m111 sensor V4L/DVB (9282): Properly iterate the urbs when destroying them. V4L/DVB (9281): gspca: Add hflip and vflip to the po1030 sensor V4L/DVB (9280): gspca: Use the gspca debug macros V4L/DVB (9279): gspca: Correct some copyright headers V4L/DVB (9278): gspca: Remove the m5602_debug variable V4L/DVB (9277): gspca: propagate an error in m5602_start_transfer() V4L/DVB (9276): videobuf-dvb: two functions are now static V4L/DVB (9275): dvb: input data pointer of cx24116_writeregN() should be const V4L/DVB (9274): Remove spurious messages and turn into debug. ...
2 parents 58617d5 + d4305c6 commit 5564da7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+4080
-4182
lines changed

Documentation/video4linux/CARDLIST.au0828

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
0 -> Unknown board (au0828)
2-
1 -> Hauppauge HVR950Q (au0828) [2040:7200,2040:7210,2040:7217,2040:721b,2040:721f,2040:7280,0fd9:0008]
2+
1 -> Hauppauge HVR950Q (au0828) [2040:7200,2040:7210,2040:7217,2040:721b,2040:721e,2040:721f,2040:7280,0fd9:0008]
33
2 -> Hauppauge HVR850 (au0828) [2040:7240]
44
3 -> DViCO FusionHDTV USB (au0828) [0fe9:d620]
55
4 -> Hauppauge HVR950Q rev xxF8 (au0828) [2040:7201,2040:7211,2040:7281]

Documentation/video4linux/CARDLIST.tuner

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,3 +75,4 @@ tuner=73 - Samsung TCPG 6121P30A
7575
tuner=75 - Philips TEA5761 FM Radio
7676
tuner=76 - Xceive 5000 tuner
7777
tuner=77 - TCL tuner MF02GIP-5N-E
78+
tuner=78 - Philips FMD1216MEX MK3 Hybrid Tuner

drivers/media/common/tuners/mxl5005s.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3481,7 +3481,9 @@ static u16 MXL_ControlWrite_Group(struct dvb_frontend *fe, u16 controlNum,
34813481
}
34823482
ctrlVal = 0;
34833483
for (k = 0; k < state->MXL_Ctrl[i].size; k++)
3484-
ctrlVal += state->MXL_Ctrl[i].val[k] * (1 << k);
3484+
ctrlVal += state->
3485+
MXL_Ctrl[i].val[k] *
3486+
(1 << k);
34853487
} else
34863488
return -1;
34873489
}
@@ -3581,7 +3583,7 @@ static void MXL_RegWriteBit(struct dvb_frontend *fe, u8 address, u8 bit,
35813583

35823584
static u32 MXL_Ceiling(u32 value, u32 resolution)
35833585
{
3584-
return (value/resolution + (value % resolution > 0 ? 1 : 0));
3586+
return value / resolution + (value % resolution > 0 ? 1 : 0);
35853587
}
35863588

35873589
/* Retrieve the Initialzation Registers */
@@ -3910,7 +3912,10 @@ static int mxl5005s_writeregs(struct dvb_frontend *fe, u8 *addrtable,
39103912

39113913
static int mxl5005s_init(struct dvb_frontend *fe)
39123914
{
3915+
struct mxl5005s_state *state = fe->tuner_priv;
3916+
39133917
dprintk(1, "%s()\n", __func__);
3918+
state->current_mode = MXL_QAM;
39143919
return mxl5005s_reconfigure(fe, MXL_QAM, MXL5005S_BANDWIDTH_6MHZ);
39153920
}
39163921

@@ -4092,7 +4097,6 @@ struct dvb_frontend *mxl5005s_attach(struct dvb_frontend *fe,
40924097
state->frontend = fe;
40934098
state->config = config;
40944099
state->i2c = i2c;
4095-
state->current_mode = MXL_QAM;
40964100

40974101
printk(KERN_INFO "MXL5005S: Attached at address 0x%02x\n",
40984102
config->i2c_address);

drivers/media/common/tuners/tuner-simple.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -493,6 +493,7 @@ static int simple_radio_bandswitch(struct dvb_frontend *fe, u8 *buffer)
493493
case TUNER_PHILIPS_FM1216ME_MK3:
494494
case TUNER_PHILIPS_FM1236_MK3:
495495
case TUNER_PHILIPS_FMD1216ME_MK3:
496+
case TUNER_PHILIPS_FMD1216MEX_MK3:
496497
case TUNER_LG_NTSC_TAPE:
497498
case TUNER_PHILIPS_FM1256_IH3:
498499
case TUNER_TCL_MF02GIP_5N:
@@ -767,6 +768,7 @@ static void simple_set_dvb(struct dvb_frontend *fe, u8 *buf,
767768

768769
switch (priv->type) {
769770
case TUNER_PHILIPS_FMD1216ME_MK3:
771+
case TUNER_PHILIPS_FMD1216MEX_MK3:
770772
if (params->u.ofdm.bandwidth == BANDWIDTH_8_MHZ &&
771773
params->frequency >= 158870000)
772774
buf[3] |= 0x08;

drivers/media/common/tuners/tuner-types.c

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -946,7 +946,7 @@ static struct tuner_params tuner_tena_9533_di_params[] = {
946946
},
947947
};
948948

949-
/* ------------ TUNER_PHILIPS_FMD1216ME_MK3 - Philips PAL ------------ */
949+
/* ------------ TUNER_PHILIPS_FMD1216ME(X)_MK3 - Philips PAL ------------ */
950950

951951
static struct tuner_range tuner_philips_fmd1216me_mk3_pal_ranges[] = {
952952
{ 16 * 160.00 /*MHz*/, 0x86, 0x51, },
@@ -984,6 +984,27 @@ static struct tuner_params tuner_philips_fmd1216me_mk3_params[] = {
984984
},
985985
};
986986

987+
static struct tuner_params tuner_philips_fmd1216mex_mk3_params[] = {
988+
{
989+
.type = TUNER_PARAM_TYPE_PAL,
990+
.ranges = tuner_philips_fmd1216me_mk3_pal_ranges,
991+
.count = ARRAY_SIZE(tuner_philips_fmd1216me_mk3_pal_ranges),
992+
.has_tda9887 = 1,
993+
.port1_active = 1,
994+
.port2_active = 1,
995+
.port2_fm_high_sensitivity = 1,
996+
.port2_invert_for_secam_lc = 1,
997+
.port1_set_for_fm_mono = 1,
998+
.radio_if = 1,
999+
.fm_gain_normal = 1,
1000+
},
1001+
{
1002+
.type = TUNER_PARAM_TYPE_DIGITAL,
1003+
.ranges = tuner_philips_fmd1216me_mk3_dvb_ranges,
1004+
.count = ARRAY_SIZE(tuner_philips_fmd1216me_mk3_dvb_ranges),
1005+
.iffreq = 16 * 36.125, /*MHz*/
1006+
},
1007+
};
9871008

9881009
/* ------ TUNER_LG_TDVS_H06XF - LG INNOTEK / INFINEON ATSC ----- */
9891010

@@ -1663,6 +1684,16 @@ struct tunertype tuners[] = {
16631684
.params = tuner_tcl_mf02gip_5n_params,
16641685
.count = ARRAY_SIZE(tuner_tcl_mf02gip_5n_params),
16651686
},
1687+
[TUNER_PHILIPS_FMD1216MEX_MK3] = { /* Philips PAL */
1688+
.name = "Philips FMD1216MEX MK3 Hybrid Tuner",
1689+
.params = tuner_philips_fmd1216mex_mk3_params,
1690+
.count = ARRAY_SIZE(tuner_philips_fmd1216mex_mk3_params),
1691+
.min = 16 * 50.87,
1692+
.max = 16 * 858.00,
1693+
.stepsize = 166667,
1694+
.initdata = tua603x_agc112,
1695+
.sleepdata = (u8[]){ 4, 0x9c, 0x60, 0x85, 0x54 },
1696+
},
16661697
};
16671698
EXPORT_SYMBOL(tuners);
16681699

drivers/media/common/tuners/xc5000.c

Lines changed: 37 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ MODULE_PARM_DESC(init_fw, "Load firmware during driver initialization.");
4343
static DEFINE_MUTEX(xc5000_list_mutex);
4444
static LIST_HEAD(hybrid_tuner_instance_list);
4545

46-
#define dprintk(level,fmt, arg...) if (debug >= level) \
46+
#define dprintk(level, fmt, arg...) if (debug >= level) \
4747
printk(KERN_INFO "%s: " fmt, "xc5000", ## arg)
4848

4949
#define XC5000_DEFAULT_FIRMWARE "dvb-fe-xc5000-1.1.fw"
@@ -138,11 +138,11 @@ struct xc5000_priv {
138138
immediately the length of the following transaction.
139139
140140
*/
141-
typedef struct {
141+
struct XC_TV_STANDARD {
142142
char *Name;
143143
u16 AudioMode;
144144
u16 VideoMode;
145-
} XC_TV_STANDARD;
145+
};
146146

147147
/* Tuner standards */
148148
#define MN_NTSC_PAL_BTSC 0
@@ -169,7 +169,7 @@ typedef struct {
169169
#define FM_Radio_INPUT2 21
170170
#define FM_Radio_INPUT1 22
171171

172-
static XC_TV_STANDARD XC5000_Standard[MAX_TV_STANDARD] = {
172+
static struct XC_TV_STANDARD XC5000_Standard[MAX_TV_STANDARD] = {
173173
{"M/N-NTSC/PAL-BTSC", 0x0400, 0x8020},
174174
{"M/N-NTSC/PAL-A2", 0x0600, 0x8020},
175175
{"M/N-NTSC/PAL-EIAJ", 0x0440, 0x8020},
@@ -183,7 +183,7 @@ static XC_TV_STANDARD XC5000_Standard[MAX_TV_STANDARD] = {
183183
{"D/K-PAL-NICAM", 0x0E80, 0x8009},
184184
{"D/K-PAL-MONO", 0x1478, 0x8009},
185185
{"D/K-SECAM-A2 DK1", 0x1200, 0x8009},
186-
{"D/K-SECAM-A2 L/DK3",0x0E00, 0x8009},
186+
{"D/K-SECAM-A2 L/DK3", 0x0E00, 0x8009},
187187
{"D/K-SECAM-A2 MONO", 0x1478, 0x8009},
188188
{"L-SECAM-NICAM", 0x8E82, 0x0009},
189189
{"L'-SECAM-NICAM", 0x8E82, 0x4009},
@@ -307,9 +307,10 @@ static int xc_load_i2c_sequence(struct dvb_frontend *fe, const u8 *i2c_sequence)
307307
unsigned int len, pos, index;
308308
u8 buf[XC_MAX_I2C_WRITE_LENGTH];
309309

310-
index=0;
311-
while ((i2c_sequence[index]!=0xFF) || (i2c_sequence[index+1]!=0xFF)) {
312-
len = i2c_sequence[index]* 256 + i2c_sequence[index+1];
310+
index = 0;
311+
while ((i2c_sequence[index] != 0xFF) ||
312+
(i2c_sequence[index + 1] != 0xFF)) {
313+
len = i2c_sequence[index] * 256 + i2c_sequence[index+1];
313314
if (len == 0x0000) {
314315
/* RESET command */
315316
result = xc_reset(fe);
@@ -329,15 +330,17 @@ static int xc_load_i2c_sequence(struct dvb_frontend *fe, const u8 *i2c_sequence)
329330
buf[1] = i2c_sequence[index + 1];
330331
pos = 2;
331332
while (pos < len) {
332-
if ((len - pos) > XC_MAX_I2C_WRITE_LENGTH - 2) {
333-
nbytes_to_send = XC_MAX_I2C_WRITE_LENGTH;
334-
} else {
333+
if ((len - pos) > XC_MAX_I2C_WRITE_LENGTH - 2)
334+
nbytes_to_send =
335+
XC_MAX_I2C_WRITE_LENGTH;
336+
else
335337
nbytes_to_send = (len - pos + 2);
338+
for (i = 2; i < nbytes_to_send; i++) {
339+
buf[i] = i2c_sequence[index + pos +
340+
i - 2];
336341
}
337-
for (i=2; i<nbytes_to_send; i++) {
338-
buf[i] = i2c_sequence[index + pos + i - 2];
339-
}
340-
result = xc_send_i2c_data(priv, buf, nbytes_to_send);
342+
result = xc_send_i2c_data(priv, buf,
343+
nbytes_to_send);
341344

342345
if (result != XC_RESULT_SUCCESS)
343346
return result;
@@ -386,8 +389,7 @@ static int xc_SetSignalSource(struct xc5000_priv *priv, u16 rf_mode)
386389
dprintk(1, "%s(%d) Source = %s\n", __func__, rf_mode,
387390
rf_mode == XC_RF_MODE_AIR ? "ANTENNA" : "CABLE");
388391

389-
if ((rf_mode != XC_RF_MODE_AIR) && (rf_mode != XC_RF_MODE_CABLE))
390-
{
392+
if ((rf_mode != XC_RF_MODE_AIR) && (rf_mode != XC_RF_MODE_CABLE)) {
391393
rf_mode = XC_RF_MODE_CABLE;
392394
printk(KERN_ERR
393395
"%s(), Invalid mode, defaulting to CABLE",
@@ -560,13 +562,13 @@ static int xc5000_readregs(struct xc5000_priv *priv, u8 *buf, u8 len)
560562
.flags = I2C_M_RD, .buf = buf, .len = len };
561563

562564
if (i2c_transfer(priv->i2c_props.adap, &msg, 1) != 1) {
563-
printk(KERN_ERR "xc5000 I2C read failed (len=%i)\n",(int)len);
565+
printk(KERN_ERR "xc5000 I2C read failed (len=%i)\n", (int)len);
564566
return -EREMOTEIO;
565567
}
566568
return 0;
567569
}
568570

569-
static int xc5000_fwupload(struct dvb_frontend* fe)
571+
static int xc5000_fwupload(struct dvb_frontend *fe)
570572
{
571573
struct xc5000_priv *priv = fe->tuner_priv;
572574
const struct firmware *fw;
@@ -576,7 +578,8 @@ static int xc5000_fwupload(struct dvb_frontend* fe)
576578
printk(KERN_INFO "xc5000: waiting for firmware upload (%s)...\n",
577579
XC5000_DEFAULT_FIRMWARE);
578580

579-
ret = request_firmware(&fw, XC5000_DEFAULT_FIRMWARE, &priv->i2c_props.adap->dev);
581+
ret = request_firmware(&fw, XC5000_DEFAULT_FIRMWARE,
582+
&priv->i2c_props.adap->dev);
580583
if (ret) {
581584
printk(KERN_ERR "xc5000: Upload failed. (file not found?)\n");
582585
ret = XC_RESULT_RESET_FAILURE;
@@ -592,7 +595,7 @@ static int xc5000_fwupload(struct dvb_frontend* fe)
592595
ret = XC_RESULT_RESET_FAILURE;
593596
} else {
594597
printk(KERN_INFO "xc5000: firmware upload\n");
595-
ret = xc_load_i2c_sequence(fe, fw->data );
598+
ret = xc_load_i2c_sequence(fe, fw->data);
596599
}
597600

598601
out:
@@ -651,7 +654,7 @@ static int xc5000_set_params(struct dvb_frontend *fe,
651654

652655
dprintk(1, "%s() frequency=%d (Hz)\n", __func__, params->frequency);
653656

654-
switch(params->u.vsb.modulation) {
657+
switch (params->u.vsb.modulation) {
655658
case VSB_8:
656659
case VSB_16:
657660
dprintk(1, "%s() VSB modulation\n", __func__);
@@ -748,50 +751,50 @@ static int xc5000_set_analog_params(struct dvb_frontend *fe,
748751
/* FIX ME: Some video standards may have several possible audio
749752
standards. We simply default to one of them here.
750753
*/
751-
if(params->std & V4L2_STD_MN) {
754+
if (params->std & V4L2_STD_MN) {
752755
/* default to BTSC audio standard */
753756
priv->video_standard = MN_NTSC_PAL_BTSC;
754757
goto tune_channel;
755758
}
756759

757-
if(params->std & V4L2_STD_PAL_BG) {
760+
if (params->std & V4L2_STD_PAL_BG) {
758761
/* default to NICAM audio standard */
759762
priv->video_standard = BG_PAL_NICAM;
760763
goto tune_channel;
761764
}
762765

763-
if(params->std & V4L2_STD_PAL_I) {
766+
if (params->std & V4L2_STD_PAL_I) {
764767
/* default to NICAM audio standard */
765768
priv->video_standard = I_PAL_NICAM;
766769
goto tune_channel;
767770
}
768771

769-
if(params->std & V4L2_STD_PAL_DK) {
772+
if (params->std & V4L2_STD_PAL_DK) {
770773
/* default to NICAM audio standard */
771774
priv->video_standard = DK_PAL_NICAM;
772775
goto tune_channel;
773776
}
774777

775-
if(params->std & V4L2_STD_SECAM_DK) {
778+
if (params->std & V4L2_STD_SECAM_DK) {
776779
/* default to A2 DK1 audio standard */
777780
priv->video_standard = DK_SECAM_A2DK1;
778781
goto tune_channel;
779782
}
780783

781-
if(params->std & V4L2_STD_SECAM_L) {
784+
if (params->std & V4L2_STD_SECAM_L) {
782785
priv->video_standard = L_SECAM_NICAM;
783786
goto tune_channel;
784787
}
785788

786-
if(params->std & V4L2_STD_SECAM_LC) {
789+
if (params->std & V4L2_STD_SECAM_LC) {
787790
priv->video_standard = LC_SECAM_NICAM;
788791
goto tune_channel;
789792
}
790793

791794
tune_channel:
792795
ret = xc_SetSignalSource(priv, priv->rf_mode);
793796
if (ret != XC_RESULT_SUCCESS) {
794-
printk(KERN_ERR
797+
printk(KERN_ERR
795798
"xc5000: xc_SetSignalSource(%d) failed\n",
796799
priv->rf_mode);
797800
return -EREMOTEIO;
@@ -863,7 +866,7 @@ static int xc_load_fw_and_init_tuner(struct dvb_frontend *fe)
863866
* I2C transactions until calibration is complete. This way we
864867
* don't have to rely on clock stretching working.
865868
*/
866-
xc_wait( 100 );
869+
xc_wait(100);
867870

868871
/* Default to "CABLE" mode */
869872
ret |= xc_write_reg(priv, XREG_SIGNALSOURCE, XC_RF_MODE_CABLE);
@@ -885,15 +888,13 @@ static int xc5000_sleep(struct dvb_frontend *fe)
885888
*/
886889

887890
ret = xc_shutdown(priv);
888-
if(ret != XC_RESULT_SUCCESS) {
891+
if (ret != XC_RESULT_SUCCESS) {
889892
printk(KERN_ERR
890893
"xc5000: %s() unable to shutdown tuner\n",
891894
__func__);
892895
return -EREMOTEIO;
893-
}
894-
else {
896+
} else
895897
return XC_RESULT_SUCCESS;
896-
}
897898
}
898899

899900
static int xc5000_init(struct dvb_frontend *fe)
@@ -989,7 +990,7 @@ struct dvb_frontend *xc5000_attach(struct dvb_frontend *fe,
989990
if (xc5000_readreg(priv, XREG_PRODUCT_ID, &id) != 0)
990991
goto fail;
991992

992-
switch(id) {
993+
switch (id) {
993994
case XC_PRODUCT_ID_FW_LOADED:
994995
printk(KERN_INFO
995996
"xc5000: Successfully identified at address 0x%02x\n",

drivers/media/common/tuners/xc5000.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,17 +45,17 @@ struct xc5000_config {
4545

4646
#if defined(CONFIG_MEDIA_TUNER_XC5000) || \
4747
(defined(CONFIG_MEDIA_TUNER_XC5000_MODULE) && defined(MODULE))
48-
extern struct dvb_frontend* xc5000_attach(struct dvb_frontend *fe,
48+
extern struct dvb_frontend *xc5000_attach(struct dvb_frontend *fe,
4949
struct i2c_adapter *i2c,
5050
struct xc5000_config *cfg);
5151
#else
52-
static inline struct dvb_frontend* xc5000_attach(struct dvb_frontend *fe,
52+
static inline struct dvb_frontend *xc5000_attach(struct dvb_frontend *fe,
5353
struct i2c_adapter *i2c,
5454
struct xc5000_config *cfg)
5555
{
5656
printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
5757
return NULL;
5858
}
59-
#endif // CONFIG_MEDIA_TUNER_XC5000
59+
#endif
6060

61-
#endif // __XC5000_H__
61+
#endif

drivers/media/dvb/dm1105/dm1105.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -595,6 +595,18 @@ static void dm1105dvb_hw_exit(struct dm1105dvb *dm1105dvb)
595595
dm1105dvb_dma_unmap(dm1105dvb);
596596
}
597597

598+
static struct stv0299_config sharp_z0194a_config = {
599+
.demod_address = 0x68,
600+
.inittab = sharp_z0194a_inittab,
601+
.mclk = 88000000UL,
602+
.invert = 1,
603+
.skip_reinit = 0,
604+
.lock_output = STV0299_LOCKOUTPUT_1,
605+
.volt13_op0_op1 = STV0299_VOLT13_OP1,
606+
.min_delay_ms = 100,
607+
.set_symbol_rate = sharp_z0194a_set_symbol_rate,
608+
};
609+
598610
static struct stv0288_config earda_config = {
599611
.demod_address = 0x68,
600612
.min_delay_ms = 100,

0 commit comments

Comments
 (0)