diff options
Diffstat (limited to 'drivers/media/video/cx18/cx18-firmware.c')
-rw-r--r-- | drivers/media/video/cx18/cx18-firmware.c | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/drivers/media/video/cx18/cx18-firmware.c b/drivers/media/video/cx18/cx18-firmware.c index 1fa95da1575e..83cd559cc609 100644 --- a/drivers/media/video/cx18/cx18-firmware.c +++ b/drivers/media/video/cx18/cx18-firmware.c | |||
@@ -26,7 +26,6 @@ | |||
26 | #include "cx18-irq.h" | 26 | #include "cx18-irq.h" |
27 | #include "cx18-firmware.h" | 27 | #include "cx18-firmware.h" |
28 | #include "cx18-cards.h" | 28 | #include "cx18-cards.h" |
29 | #include "cx18-av-core.h" | ||
30 | #include <linux/firmware.h> | 29 | #include <linux/firmware.h> |
31 | 30 | ||
32 | #define CX18_PROC_SOFT_RESET 0xc70010 | 31 | #define CX18_PROC_SOFT_RESET 0xc70010 |
@@ -107,7 +106,7 @@ static int load_cpu_fw_direct(const char *fn, u8 __iomem *mem, struct cx18 *cx) | |||
107 | u32 __iomem *dst = (u32 __iomem *)mem; | 106 | u32 __iomem *dst = (u32 __iomem *)mem; |
108 | const u32 *src; | 107 | const u32 *src; |
109 | 108 | ||
110 | if (request_firmware(&fw, fn, &cx->dev->dev)) { | 109 | if (request_firmware(&fw, fn, &cx->pci_dev->dev)) { |
111 | CX18_ERR("Unable to open firmware %s\n", fn); | 110 | CX18_ERR("Unable to open firmware %s\n", fn); |
112 | CX18_ERR("Did you put the firmware in the hotplug firmware directory?\n"); | 111 | CX18_ERR("Did you put the firmware in the hotplug firmware directory?\n"); |
113 | return -ENOMEM; | 112 | return -ENOMEM; |
@@ -151,7 +150,7 @@ static int load_apu_fw_direct(const char *fn, u8 __iomem *dst, struct cx18 *cx, | |||
151 | u32 apu_version = 0; | 150 | u32 apu_version = 0; |
152 | int sz; | 151 | int sz; |
153 | 152 | ||
154 | if (request_firmware(&fw, fn, &cx->dev->dev)) { | 153 | if (request_firmware(&fw, fn, &cx->pci_dev->dev)) { |
155 | CX18_ERR("unable to open firmware %s\n", fn); | 154 | CX18_ERR("unable to open firmware %s\n", fn); |
156 | CX18_ERR("did you put the firmware in the hotplug firmware directory?\n"); | 155 | CX18_ERR("did you put the firmware in the hotplug firmware directory?\n"); |
157 | cx18_setup_page(cx, 0); | 156 | cx18_setup_page(cx, 0); |
@@ -286,23 +285,6 @@ void cx18_init_power(struct cx18 *cx, int lowpwr) | |||
286 | cx18_write_reg(cx, 0x2BE2FE, CX18_MPEG_CLOCK_PLL_FRAC); | 285 | cx18_write_reg(cx, 0x2BE2FE, CX18_MPEG_CLOCK_PLL_FRAC); |
287 | cx18_write_reg(cx, 8, CX18_MPEG_CLOCK_PLL_POST); | 286 | cx18_write_reg(cx, 8, CX18_MPEG_CLOCK_PLL_POST); |
288 | 287 | ||
289 | /* | ||
290 | * VDCLK Integer = 0x0f, Post Divider = 0x04 | ||
291 | * AIMCLK Integer = 0x0e, Post Divider = 0x16 | ||
292 | */ | ||
293 | cx18_av_write4(cx, CXADEC_PLL_CTRL1, 0x160e040f); | ||
294 | |||
295 | /* VDCLK Fraction = 0x2be2fe */ | ||
296 | /* xtal * 0xf.15f17f0/4 = 108 MHz: 432 MHz before post divide */ | ||
297 | cx18_av_write4(cx, CXADEC_VID_PLL_FRAC, 0x002be2fe); | ||
298 | |||
299 | /* AIMCLK Fraction = 0x05227ad */ | ||
300 | /* xtal * 0xe.2913d68/0x16 = 48000 * 384: 406 MHz before post-divide */ | ||
301 | cx18_av_write4(cx, CXADEC_AUX_PLL_FRAC, 0x005227ad); | ||
302 | |||
303 | /* SA_MCLK_SEL=1, SA_MCLK_DIV=0x16 */ | ||
304 | cx18_av_write(cx, CXADEC_I2S_MCLK, 0x56); | ||
305 | |||
306 | /* Defaults */ | 288 | /* Defaults */ |
307 | /* APU = SC or SC/2 = 125/62.5 */ | 289 | /* APU = SC or SC/2 = 125/62.5 */ |
308 | /* EPU = SC = 125 */ | 290 | /* EPU = SC = 125 */ |