diff options
author | Andy Walls <awalls@radix.net> | 2009-02-16 00:23:25 -0500 |
---|---|---|
committer | Andy Walls <awalls@radix.net> | 2009-02-16 00:23:25 -0500 |
commit | 2fc2bbdf325e45fee8f2e62a8594fc62f18b5f3e (patch) | |
tree | 476b889e240097b8296c9a1ab0523cead2b40468 /linux/drivers/media/video/cx18/cx18-driver.c | |
parent | 2aa8e5c7af6768440a674eceede51b867f915445 (diff) | |
download | mediapointer-dvb-s2-2fc2bbdf325e45fee8f2e62a8594fc62f18b5f3e.tar.gz mediapointer-dvb-s2-2fc2bbdf325e45fee8f2e62a8594fc62f18b5f3e.tar.bz2 |
cx18, v4l2-chip-ident: Finish conversion of AV decoder core to v4l2_subdev
From: Andy Walls <awalls@radix.net>
Added a new chip identifer to v4l2-chip-ident for the integrated A/V broadcast
decoder core internal to the CX23418. Completed separation and encapsulation
of the A/V decoder core interface as a v4l2_subdevice. The cx18 driver now
compiles and links again.
Priority: normal
Signed-off-by: Andy Walls <awalls@radix.net>
Diffstat (limited to 'linux/drivers/media/video/cx18/cx18-driver.c')
-rw-r--r-- | linux/drivers/media/video/cx18/cx18-driver.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/linux/drivers/media/video/cx18/cx18-driver.c b/linux/drivers/media/video/cx18/cx18-driver.c index 9daf3c90a..eca2901c9 100644 --- a/linux/drivers/media/video/cx18/cx18-driver.c +++ b/linux/drivers/media/video/cx18/cx18-driver.c @@ -626,13 +626,6 @@ static void __devinit cx18_init_struct2(struct cx18 *cx) i = 0; cx->active_input = i; cx->audio_input = cx->card->video_inputs[i].audio_index; - cx->av_state.vid_input = CX18_AV_COMPOSITE7; - cx->av_state.aud_input = CX18_AV_AUDIO8; - cx->av_state.audclk_freq = 48000; - cx->av_state.audmode = V4L2_TUNER_MODE_LANG1; - cx->av_state.slicer_line_delay = 0; - cx->av_state.slicer_line_offset = - (10 + cx->av_state.slicer_line_delay - 2); } static int cx18_setup_pci(struct cx18 *cx, struct pci_dev *pci_dev, @@ -817,6 +810,14 @@ static int __devinit cx18_probe(struct pci_dev *pci_dev, cx18_gpio_init(cx); + retval = cx18_av_probe(cx, &cx->sd_av); + if (retval) { + CX18_ERR("Could not register A/V decoder subdevice\n"); + goto free_map; + } + /* Initialize the A/V decoder PLLs to sane defaults */ + v4l2_subdev_call(cx->sd_av, core, init, (u32) CX18_AV_INIT_PLLS); + /* active i2c */ CX18_DEBUG_INFO("activating i2c...\n"); retval = init_cx18_i2c(cx); @@ -1025,6 +1026,9 @@ int cx18_init_on_first_open(struct cx18 *cx) cx18_vapi(cx, CX18_APU_RESETAI, 0); cx18_vapi(cx, CX18_APU_STOP, 1, CX18_APU_ENCODING_METHOD_MPEG); + /* Init the A/V decoder, if it hasn't been already */ + v4l2_subdev_call(cx->sd_av, core, init, (u32) CX18_AV_INIT_NORMAL); + vf.tuner = 0; vf.type = V4L2_TUNER_ANALOG_TV; vf.frequency = 6400; /* the tuner 'baseline' frequency */ |