H A D | vpbe_display.c | 50 static int vpbe_set_osd_display_params(struct vpbe_display *disp_dev, 53 static int venc_is_second_field(struct vpbe_display *disp_dev) venc_is_second_field() argument 55 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; venc_is_second_field() 123 struct vpbe_display *disp_dev = (struct vpbe_display *)arg; venc_isr() local 130 if ((NULL == arg) || (NULL == disp_dev->dev[0])) venc_isr() 133 if (venc_is_second_field(disp_dev)) venc_isr() 154 layer = disp_dev->dev[i]; venc_isr() 168 vpbe_isr_even_field(disp_dev, layer); venc_isr() 169 vpbe_isr_odd_field(disp_dev, layer); venc_isr() 193 vpbe_isr_even_field(disp_dev, layer); venc_isr() 195 vpbe_isr_odd_field(disp_dev, layer); venc_isr() 212 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_buffer_prepare() 243 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_buffer_queue_setup() 271 struct vpbe_display *disp = layer->disp_dev; vpbe_buffer_queue() 272 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_buffer_queue() 287 struct osd_state *osd_device = layer->disp_dev->osd_device; vpbe_start_streaming() 303 ret = vpbe_set_osd_display_params(layer->disp_dev, layer); vpbe_start_streaming() 328 struct osd_state *osd_device = layer->disp_dev->osd_device; vpbe_stop_streaming() 329 struct vpbe_display *disp = layer->disp_dev; vpbe_stop_streaming() 371 _vpbe_display_get_other_win_layer(struct vpbe_display *disp_dev, _vpbe_display_get_other_win_layer() argument 379 return disp_dev->dev[otherwin]; _vpbe_display_get_other_win_layer() 382 static int vpbe_set_osd_display_params(struct vpbe_display *disp_dev, vpbe_set_osd_display_params() argument 386 struct osd_state *osd_device = disp_dev->osd_device; vpbe_set_osd_display_params() 387 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_set_osd_display_params() 396 disp_dev->cbcr_ofst); vpbe_set_osd_display_params() 410 _vpbe_display_get_other_win_layer(disp_dev, layer); vpbe_set_osd_display_params() 425 vpbe_disp_calculate_scale_factor(struct vpbe_display *disp_dev, vpbe_disp_calculate_scale_factor() argument 432 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_disp_calculate_scale_factor() 532 static void vpbe_disp_adj_position(struct vpbe_display *disp_dev, vpbe_disp_adj_position() argument 537 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_disp_adj_position() 549 static void vpbe_disp_check_window_params(struct vpbe_display *disp_dev, vpbe_disp_check_window_params() argument 552 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_disp_check_window_params() 574 static int vpbe_try_format(struct vpbe_display *disp_dev, vpbe_try_format() argument 577 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_try_format() 640 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_querycap() 657 struct vpbe_display *disp_dev = layer->disp_dev; vpbe_display_s_crop() local 658 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_display_s_crop() 660 struct osd_state *osd_device = disp_dev->osd_device; vpbe_display_s_crop() 677 vpbe_disp_check_window_params(disp_dev, &rect); vpbe_display_s_crop() 682 vpbe_disp_calculate_scale_factor(disp_dev, layer, vpbe_display_s_crop() 685 vpbe_disp_adj_position(disp_dev, layer, rect.top, vpbe_display_s_crop() 726 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_g_crop() 727 struct osd_state *osd_device = layer->disp_dev->osd_device; vpbe_display_g_crop() 752 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_cropcap() 770 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_g_fmt() 791 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_enum_fmt() 822 struct vpbe_display *disp_dev = layer->disp_dev; vpbe_display_s_fmt() local 823 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_display_s_fmt() 826 struct osd_state *osd_device = disp_dev->osd_device; vpbe_display_s_fmt() 841 ret = vpbe_try_format(disp_dev, pixfmt, 1); vpbe_display_s_fmt() 852 otherlayer = _vpbe_display_get_other_win_layer(disp_dev, layer); vpbe_display_s_fmt() 883 otherlayer = _vpbe_display_get_other_win_layer(disp_dev, vpbe_display_s_fmt() 908 struct vpbe_display *disp_dev = layer->disp_dev; vpbe_display_try_fmt() local 909 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_try_fmt() 920 return vpbe_try_format(disp_dev, pixfmt, 0); vpbe_display_try_fmt() 934 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_s_std() 966 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_g_std() 989 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_enum_output() 1017 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_s_output() 1046 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_g_output() 1066 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_enum_dv_timings() 1096 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_s_dv_timings() 1129 struct vpbe_device *vpbe_dev = layer->disp_dev->vpbe_dev; vpbe_display_g_dv_timings() 1153 struct vpbe_display *disp_dev = layer->disp_dev; vpbe_display_open() local 1154 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_display_open() 1155 struct osd_state *osd_device = disp_dev->osd_device; vpbe_display_open() 1200 struct vpbe_display *disp_dev = layer->disp_dev; vpbe_display_release() local 1201 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_display_release() 1202 struct osd_state *osd_device = disp_dev->osd_device; vpbe_display_release() 1217 _vpbe_display_get_other_win_layer(disp_dev, layer); vpbe_display_release() 1232 disp_dev->cbcr_ofst = 0; vpbe_display_release() 1293 static int init_vpbe_layer(int i, struct vpbe_display *disp_dev, init_vpbe_layer() argument 1301 disp_dev->dev[i] = init_vpbe_layer() 1305 if (!disp_dev->dev[i]) { init_vpbe_layer() 1309 spin_lock_init(&disp_dev->dev[i]->irqlock); init_vpbe_layer() 1310 mutex_init(&disp_dev->dev[i]->opslock); init_vpbe_layer() 1313 vpbe_display_layer = disp_dev->dev[i]; init_vpbe_layer() 1320 vbd->v4l2_dev = &disp_dev->vpbe_dev->v4l2_dev; init_vpbe_layer() 1324 if (disp_dev->vpbe_dev->current_timings.timings_type & init_vpbe_layer() 1344 struct vpbe_display *disp_dev, register_device() 1349 v4l2_info(&disp_dev->vpbe_dev->v4l2_dev, register_device() 1351 v4l2_info(&disp_dev->vpbe_dev->v4l2_dev, register_device() 1363 vpbe_display_layer->disp_dev = disp_dev; register_device() 1365 platform_set_drvdata(pdev, disp_dev); register_device() 1381 struct vpbe_display *disp_dev; vpbe_display_probe() local 1392 disp_dev = devm_kzalloc(&pdev->dev, sizeof(struct vpbe_display), vpbe_display_probe() 1394 if (!disp_dev) vpbe_display_probe() 1397 spin_lock_init(&disp_dev->dma_queue_lock); vpbe_display_probe() 1402 err = bus_for_each_dev(&platform_bus_type, NULL, disp_dev, vpbe_display_probe() 1407 v4l2_dev = &disp_dev->vpbe_dev->v4l2_dev; vpbe_display_probe() 1409 if (NULL != disp_dev->vpbe_dev->ops.initialize) { vpbe_display_probe() 1410 err = disp_dev->vpbe_dev->ops.initialize(&pdev->dev, vpbe_display_probe() 1411 disp_dev->vpbe_dev); vpbe_display_probe() 1420 if (init_vpbe_layer(i, disp_dev, pdev)) { vpbe_display_probe() 1435 VPBE_DISPLAY_DRIVER, disp_dev); vpbe_display_probe() 1443 q = &disp_dev->dev[i]->buffer_queue; vpbe_display_probe() 1447 q->drv_priv = disp_dev->dev[i]; vpbe_display_probe() 1453 q->lock = &disp_dev->dev[i]->opslock; vpbe_display_probe() 1460 disp_dev->dev[i]->alloc_ctx = vpbe_display_probe() 1461 vb2_dma_contig_init_ctx(disp_dev->vpbe_dev->pdev); vpbe_display_probe() 1462 if (IS_ERR(disp_dev->dev[i]->alloc_ctx)) { vpbe_display_probe() 1464 err = PTR_ERR(disp_dev->dev[i]->alloc_ctx); vpbe_display_probe() 1468 INIT_LIST_HEAD(&disp_dev->dev[i]->dma_queue); vpbe_display_probe() 1470 if (register_device(disp_dev->dev[i], disp_dev, pdev)) { vpbe_display_probe() 1484 if (disp_dev->dev[k] != NULL) { vpbe_display_probe() 1485 vb2_dma_contig_cleanup_ctx(disp_dev->dev[k]->alloc_ctx); vpbe_display_probe() 1486 video_unregister_device(&disp_dev->dev[k]->video_dev); vpbe_display_probe() 1487 kfree(disp_dev->dev[k]); vpbe_display_probe() 1500 struct vpbe_display *disp_dev = platform_get_drvdata(pdev); vpbe_display_remove() local 1501 struct vpbe_device *vpbe_dev = disp_dev->vpbe_dev; vpbe_display_remove() 1512 vpbe_display_layer = disp_dev->dev[i]; vpbe_display_remove() 1519 kfree(disp_dev->dev[i]); vpbe_display_remove() 1520 disp_dev->dev[i] = NULL; vpbe_display_remove() 1343 register_device(struct vpbe_layer *vpbe_display_layer, struct vpbe_display *disp_dev, struct platform_device *pdev) register_device() argument
|