diff options
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-davinci/board-dm355-evm.c | 69 |
1 files changed, 68 insertions, 1 deletions
diff --git a/arch/arm/mach-davinci/board-dm355-evm.c b/arch/arm/mach-davinci/board-dm355-evm.c index 37d12cc202af..104350600b20 100644 --- a/arch/arm/mach-davinci/board-dm355-evm.c +++ b/arch/arm/mach-davinci/board-dm355-evm.c | |||
@@ -242,6 +242,73 @@ static struct vpfe_config vpfe_cfg = { | |||
242 | .ccdc = "DM355 CCDC", | 242 | .ccdc = "DM355 CCDC", |
243 | }; | 243 | }; |
244 | 244 | ||
245 | /* venc standards timings */ | ||
246 | static struct vpbe_enc_mode_info dm355evm_enc_preset_timing[] = { | ||
247 | { | ||
248 | .name = "ntsc", | ||
249 | .timings_type = VPBE_ENC_STD, | ||
250 | .std_id = V4L2_STD_525_60, | ||
251 | .interlaced = 1, | ||
252 | .xres = 720, | ||
253 | .yres = 480, | ||
254 | .aspect = {11, 10}, | ||
255 | .fps = {30000, 1001}, | ||
256 | .left_margin = 0x79, | ||
257 | .upper_margin = 0x10, | ||
258 | }, | ||
259 | { | ||
260 | .name = "pal", | ||
261 | .timings_type = VPBE_ENC_STD, | ||
262 | .std_id = V4L2_STD_625_50, | ||
263 | .interlaced = 1, | ||
264 | .xres = 720, | ||
265 | .yres = 576, | ||
266 | .aspect = {54, 59}, | ||
267 | .fps = {25, 1}, | ||
268 | .left_margin = 0x7E, | ||
269 | .upper_margin = 0x16 | ||
270 | }, | ||
271 | }; | ||
272 | |||
273 | #define VENC_STD_ALL (V4L2_STD_NTSC | V4L2_STD_PAL) | ||
274 | |||
275 | /* | ||
276 | * The outputs available from VPBE + ecnoders. Keep the | ||
277 | * the order same as that of encoders. First those from venc followed by that | ||
278 | * from encoders. Index in the output refers to index on a particular encoder. | ||
279 | * Driver uses this index to pass it to encoder when it supports more than | ||
280 | * one output. Application uses index of the array to set an output. | ||
281 | */ | ||
282 | static struct vpbe_output dm355evm_vpbe_outputs[] = { | ||
283 | { | ||
284 | .output = { | ||
285 | .index = 0, | ||
286 | .name = "Composite", | ||
287 | .type = V4L2_OUTPUT_TYPE_ANALOG, | ||
288 | .std = VENC_STD_ALL, | ||
289 | .capabilities = V4L2_OUT_CAP_STD, | ||
290 | }, | ||
291 | .subdev_name = DM355_VPBE_VENC_SUBDEV_NAME, | ||
292 | .default_mode = "ntsc", | ||
293 | .num_modes = ARRAY_SIZE(dm355evm_enc_preset_timing), | ||
294 | .modes = dm355evm_enc_preset_timing, | ||
295 | .if_params = V4L2_MBUS_FMT_FIXED, | ||
296 | }, | ||
297 | }; | ||
298 | |||
299 | static struct vpbe_config dm355evm_display_cfg = { | ||
300 | .module_name = "dm355-vpbe-display", | ||
301 | .i2c_adapter_id = 1, | ||
302 | .osd = { | ||
303 | .module_name = DM355_VPBE_OSD_SUBDEV_NAME, | ||
304 | }, | ||
305 | .venc = { | ||
306 | .module_name = DM355_VPBE_VENC_SUBDEV_NAME, | ||
307 | }, | ||
308 | .num_outputs = ARRAY_SIZE(dm355evm_vpbe_outputs), | ||
309 | .outputs = dm355evm_vpbe_outputs, | ||
310 | }; | ||
311 | |||
245 | static struct platform_device *davinci_evm_devices[] __initdata = { | 312 | static struct platform_device *davinci_evm_devices[] __initdata = { |
246 | &dm355evm_dm9000, | 313 | &dm355evm_dm9000, |
247 | &davinci_nand_device, | 314 | &davinci_nand_device, |
@@ -342,7 +409,7 @@ static __init void dm355_evm_init(void) | |||
342 | davinci_setup_mmc(0, &dm355evm_mmc_config); | 409 | davinci_setup_mmc(0, &dm355evm_mmc_config); |
343 | davinci_setup_mmc(1, &dm355evm_mmc_config); | 410 | davinci_setup_mmc(1, &dm355evm_mmc_config); |
344 | 411 | ||
345 | dm355_init_video(&vpfe_cfg, NULL); | 412 | dm355_init_video(&vpfe_cfg, &dm355evm_display_cfg); |
346 | 413 | ||
347 | dm355_init_spi0(BIT(0), dm355_evm_spi_info, | 414 | dm355_init_spi0(BIT(0), dm355_evm_spi_info, |
348 | ARRAY_SIZE(dm355_evm_spi_info)); | 415 | ARRAY_SIZE(dm355_evm_spi_info)); |