@@ -571,12 +571,13 @@ static const struct media_entity_operations mei_csi_entity_ops = {
static int mei_csi_notify_bound(struct v4l2_async_notifier *notifier,
struct v4l2_subdev *subdev,
- struct v4l2_async_subdev *asd)
+ struct v4l2_async_connection *asd)
{
struct mei_csi *csi = notifier_to_csi(notifier);
int pad;
- pad = media_entity_get_fwnode_pad(&subdev->entity, asd->match.fwnode,
+ pad = media_entity_get_fwnode_pad(&subdev->entity,
+ subdev->fwnode,
MEDIA_PAD_FL_SOURCE);
if (pad < 0)
return pad;
@@ -592,7 +593,7 @@ static int mei_csi_notify_bound(struct v4l2_async_notifier *notifier,
static void mei_csi_notify_unbind(struct v4l2_async_notifier *notifier,
struct v4l2_subdev *subdev,
- struct v4l2_async_subdev *asd)
+ struct v4l2_async_connection *asd)
{
struct mei_csi *csi = notifier_to_csi(notifier);
@@ -645,7 +646,7 @@ static int mei_csi_parse_firmware(struct mei_csi *csi)
.bus_type = V4L2_MBUS_CSI2_DPHY,
};
struct device *dev = &csi->cldev->dev;
- struct v4l2_async_subdev *asd;
+ struct v4l2_async_connection *asd;
struct fwnode_handle *fwnode;
struct fwnode_handle *ep;
int ret;
@@ -666,11 +667,11 @@ static int mei_csi_parse_firmware(struct mei_csi *csi)
fwnode = fwnode_graph_get_remote_endpoint(ep);
fwnode_handle_put(ep);
- v4l2_async_nf_init(&csi->notifier);
+ v4l2_async_subdev_nf_init(&csi->notifier, &csi->subdev);
csi->notifier.ops = &mei_csi_notify_ops;
asd = v4l2_async_nf_add_fwnode(&csi->notifier, fwnode,
- struct v4l2_async_subdev);
+ struct v4l2_async_connection);
if (IS_ERR(asd)) {
fwnode_handle_put(fwnode);
return PTR_ERR(asd);
@@ -682,7 +683,7 @@ static int mei_csi_parse_firmware(struct mei_csi *csi)
return ret;
csi->nr_of_lanes = v4l2_ep.bus.mipi_csi2.num_data_lanes;
- ret = v4l2_async_subdev_nf_register(&csi->subdev, &csi->notifier);
+ ret = v4l2_async_nf_register(&csi->notifier);
if (ret)
v4l2_async_nf_cleanup(&csi->notifier);
Follow new v4l2-async API for mei_csi subdev. Signed-off-by: Wentong Wu <wentong.wu@intel.com> --- v1: - based on https://git.linuxtv.org/sailus/media_tree.git tree --- drivers/media/pci/intel/ivsc/mei_csi.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)