V4L/DVB(7879): Adding cx18 Support for mxl5005s

Adding cx18 Support

Signed-off-by: Steven Toth <stoth@hauppauge.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
This commit is contained in:
Steven Toth 2008-05-01 07:23:23 -03:00 committed by Mauro Carvalho Chehab
parent 9426954277
commit 6712947196
3 changed files with 22 additions and 22 deletions

View File

@ -11,6 +11,7 @@ config VIDEO_CX18
select VIDEO_CX2341X
select VIDEO_CS5345
select DVB_S5H1409
select MEDIA_TUNER_MXL5005S
---help---
This is a video4linux driver for Conexant cx23418 based
PCI combo video recorder devices.

View File

@ -51,7 +51,8 @@ static const struct cx18_card cx18_card_hvr1600_esmt = {
.v4l2_capabilities = CX18_CAP_ENCODER,
.hw_audio_ctrl = CX18_HW_CX23418,
.hw_muxer = CX18_HW_CS5345,
.hw_all = CX18_HW_TVEEPROM | CX18_HW_TUNER | CX18_HW_CS5345,
.hw_all = CX18_HW_TVEEPROM | CX18_HW_TUNER | CX18_HW_CS5345
| CX18_HW_DVB,
.video_inputs = {
{ CX18_CARD_INPUT_VID_TUNER, 0, CX23418_COMPOSITE7 },
{ CX18_CARD_INPUT_SVIDEO1, 1, CX23418_SVIDEO1 },

View File

@ -24,25 +24,27 @@
#include "cx18-streams.h"
#include "cx18-cards.h"
#include "s5h1409.h"
/* Wait until the MXL500X driver is merged */
#ifdef HAVE_MXL500X
#include "mxl500x.h"
#endif
#include "mxl5005s.h"
DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr);
#define CX18_REG_DMUX_NUM_PORT_0_CONTROL 0xd5a000
#ifdef HAVE_MXL500X
static struct mxl500x_config hauppauge_hvr1600_tuner = {
.delsys = MXL500x_MODE_ATSC,
.octf = MXL500x_OCTF_CH,
.xtal_freq = 16000000,
.iflo_freq = 5380000,
.ref_freq = 322800000,
.rssi_ena = MXL_RSSI_ENABLE,
.addr = 0xC6 >> 1,
static struct mxl5005s_config hauppauge_hvr1600_tuner = {
.i2c_address = 0xC6 >> 1,
.if_freq = IF_FREQ_5380000HZ,
.xtal_freq = CRYSTAL_FREQ_16000000HZ,
.agc_mode = MXL_SINGLE_AGC,
.tracking_filter = MXL_TF_C_H,
.rssi_enable = MXL_RSSI_ENABLE,
.cap_select = MXL_CAP_SEL_ENABLE,
.div_out = MXL_DIV_OUT_4,
.clock_out = MXL_CLOCK_OUT_DISABLE,
.output_load = MXL5005S_IF_OUTPUT_LOAD_200_OHM,
.top = MXL5005S_TOP_25P2,
.mod_mode = MXL_DIGITAL_MODE,
.if_mode = MXL_ZERO_IF,
.AgcMasterByte = 0x00,
};
static struct s5h1409_config hauppauge_hvr1600_config = {
@ -55,7 +57,6 @@ static struct s5h1409_config hauppauge_hvr1600_config = {
.mpeg_timing = S5H1409_MPEGTIMING_CONTINOUS_NONINVERTING_CLOCK
};
#endif
static int dvb_register(struct cx18_stream *stream);
@ -252,21 +253,18 @@ static int dvb_register(struct cx18_stream *stream)
int ret = 0;
switch (cx->card->type) {
/* Wait until the MXL500X driver is merged */
#ifdef HAVE_MXL500X
case CX18_CARD_HVR_1600_ESMT:
case CX18_CARD_HVR_1600_SAMSUNG:
dvb->fe = dvb_attach(s5h1409_attach,
&hauppauge_hvr1600_config,
&cx->i2c_adap[0]);
if (dvb->fe != NULL) {
dvb_attach(mxl500x_attach, dvb->fe,
&hauppauge_hvr1600_tuner,
&cx->i2c_adap[0]);
dvb_attach(mxl5005s_attach, dvb->fe,
&cx->i2c_adap[0],
&hauppauge_hvr1600_tuner);
ret = 0;
}
break;
#endif
default:
/* No Digital Tv Support */
break;