diff options
author | Sakari Ailus <sakari.ailus@linux.intel.com> | 2023-10-16 10:27:34 +0300 |
---|---|---|
committer | Hans Verkuil <hverkuil-cisco@xs4all.nl> | 2023-11-22 10:56:34 +0100 |
commit | a6a42fada1e5ee0bcc1ce534ea196625d271dfd8 (patch) | |
tree | 0a2e328ed010e2c50b04241b5ffae9afcc0c047b /drivers/media | |
parent | e34660972b88e8d27f17e220fe13609b5cd52ec2 (diff) | |
download | linux-stable-a6a42fada1e5ee0bcc1ce534ea196625d271dfd8.tar.gz linux-stable-a6a42fada1e5ee0bcc1ce534ea196625d271dfd8.tar.bz2 linux-stable-a6a42fada1e5ee0bcc1ce534ea196625d271dfd8.zip |
media: ivsc: csi: Clean up notifier set-up
Use v4l2_async_nf_add_fwnode_remote() to add an async fwnode remote
sub-device sub-device to the notifier. This avoids dealing with remote
endpoints.
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Tested-by: Wentong Wu <wentong.wu@intel.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/pci/intel/ivsc/mei_csi.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/media/pci/intel/ivsc/mei_csi.c b/drivers/media/pci/intel/ivsc/mei_csi.c index 19f1a47ba52d..f11c7b25491d 100644 --- a/drivers/media/pci/intel/ivsc/mei_csi.c +++ b/drivers/media/pci/intel/ivsc/mei_csi.c @@ -645,7 +645,6 @@ static int mei_csi_parse_firmware(struct mei_csi *csi) }; struct device *dev = &csi->cldev->dev; struct v4l2_async_connection *asd; - struct fwnode_handle *fwnode; struct fwnode_handle *ep; int ret; @@ -664,15 +663,12 @@ static int mei_csi_parse_firmware(struct mei_csi *csi) csi->nr_of_lanes = v4l2_ep.bus.mipi_csi2.num_data_lanes; - fwnode = fwnode_graph_get_remote_endpoint(ep); - fwnode_handle_put(ep); - 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_connection); - fwnode_handle_put(fwnode); + asd = v4l2_async_nf_add_fwnode_remote(&csi->notifier, ep, + struct v4l2_async_connection); + fwnode_handle_put(ep); if (IS_ERR(asd)) { ret = PTR_ERR(asd); goto out_nf_cleanup; |