mirror of
https://github.com/torvalds/linux.git
synced 2026-06-01 11:03:43 +02:00
media: omap3isp: configure entity functions
For the various subdevices, set the function field. This fixes v4l2-compliance errors: $ v4l2-compliance -M0 v4l2-compliance 1.33.0-5410, 32 bits, 64-bit time_t v4l2-compliance SHA: c12c89c5bd70 2025-10-05 09:58:42 Compliance test for omap3isp device /dev/media0: Media Driver Info: Driver name : omap3isp Model : TI OMAP3 ISP Serial : Bus info : platform:480bc000.isp Media version : 6.17.0 Hardware revision: 0x000000f0 (240) Driver version : 6.17.0 Required ioctls: test MEDIA_IOC_DEVICE_INFO: OK test invalid ioctls: OK Allow for multiple opens: test second /dev/media0 open: OK test MEDIA_IOC_DEVICE_INFO: OK test for unlimited opens: OK Media Controller ioctls: fail: v4l2-test-media.cpp(108): function == MEDIA_ENT_F_V4L2_SUBDEV_UNKNOWN fail: v4l2-test-media.cpp(196): checkFunction(ent.function, true) test MEDIA_IOC_G_TOPOLOGY: FAIL fail: v4l2-test-media.cpp(398): num_data_links != num_links test MEDIA_IOC_ENUM_ENTITIES/LINKS: FAIL test MEDIA_IOC_SETUP_LINK: OK Total for omap3isp device /dev/media0: 8, Succeeded: 6, Failed: 2, Warnings: 0 Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
This commit is contained in:
parent
ee5b462b97
commit
e0ac618fff
|
|
@ -2675,6 +2675,7 @@ static int ccdc_init_entities(struct isp_ccdc_device *ccdc)
|
|||
pads[CCDC_PAD_SOURCE_OF].flags = MEDIA_PAD_FL_SOURCE;
|
||||
|
||||
me->ops = &ccdc_media_ops;
|
||||
me->function = MEDIA_ENT_F_PROC_VIDEO_PIXEL_ENC_CONV;
|
||||
ret = media_entity_pads_init(me, CCDC_PADS_NUM, pads);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
|
|
|||
|
|
@ -1086,6 +1086,7 @@ static int ccp2_init_entities(struct isp_ccp2_device *ccp2)
|
|||
pads[CCP2_PAD_SOURCE].flags = MEDIA_PAD_FL_SOURCE;
|
||||
|
||||
me->ops = &ccp2_media_ops;
|
||||
me->function = MEDIA_ENT_F_VID_IF_BRIDGE;
|
||||
ret = media_entity_pads_init(me, CCP2_PADS_NUM, pads);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
|
|
|||
|
|
@ -1251,6 +1251,7 @@ static int csi2_init_entities(struct isp_csi2_device *csi2)
|
|||
| MEDIA_PAD_FL_MUST_CONNECT;
|
||||
|
||||
me->ops = &csi2_media_ops;
|
||||
me->function = MEDIA_ENT_F_VID_IF_BRIDGE;
|
||||
ret = media_entity_pads_init(me, CSI2_PADS_NUM, pads);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
|
|
|||
|
|
@ -2294,6 +2294,7 @@ static int preview_init_entities(struct isp_prev_device *prev)
|
|||
pads[PREV_PAD_SOURCE].flags = MEDIA_PAD_FL_SOURCE;
|
||||
|
||||
me->ops = &preview_media_ops;
|
||||
me->function = MEDIA_ENT_F_PROC_VIDEO_PIXEL_FORMATTER;
|
||||
ret = media_entity_pads_init(me, PREV_PADS_NUM, pads);
|
||||
if (ret < 0)
|
||||
goto error_handler_free;
|
||||
|
|
|
|||
|
|
@ -1738,6 +1738,7 @@ static int resizer_init_entities(struct isp_res_device *res)
|
|||
pads[RESZ_PAD_SOURCE].flags = MEDIA_PAD_FL_SOURCE;
|
||||
|
||||
me->ops = &resizer_media_ops;
|
||||
me->function = MEDIA_ENT_F_PROC_VIDEO_SCALER;
|
||||
ret = media_entity_pads_init(me, RESZ_PADS_NUM, pads);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
|
|
|||
|
|
@ -1037,6 +1037,7 @@ static int isp_stat_init_entities(struct ispstat *stat, const char *name,
|
|||
|
||||
stat->pad.flags = MEDIA_PAD_FL_SINK | MEDIA_PAD_FL_MUST_CONNECT;
|
||||
me->ops = NULL;
|
||||
me->function = MEDIA_ENT_F_PROC_VIDEO_STATISTICS;
|
||||
|
||||
return media_entity_pads_init(me, 1, &stat->pad);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user