Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

media: qcom: camss: use a handy v4l2_async_nf_add_fwnode_remote() function

Another code simplification makes parsing of remote endpoints easy.

Tested-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
Signed-off-by: Vladimir Zapolskiy <vladimir.zapolskiy@linaro.org>
Signed-off-by: Bryan O'Donoghue <bod@kernel.org>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>

authored by

Vladimir Zapolskiy and committed by
Hans Verkuil
77a2ff40 eccf5fa8

+2 -11
+2 -11
drivers/media/platform/qcom/camss/camss.c
··· 4271 4271 4272 4272 fwnode_graph_for_each_endpoint(fwnode, ep) { 4273 4273 struct camss_async_subdev *csd; 4274 - struct fwnode_handle *remote; 4275 4274 4276 - remote = fwnode_graph_get_remote_port_parent(ep); 4277 - if (!remote) { 4278 - dev_err(dev, "Cannot get remote parent\n"); 4279 - ret = -EINVAL; 4280 - goto err_cleanup; 4281 - } 4282 - 4283 - csd = v4l2_async_nf_add_fwnode(&camss->notifier, remote, 4284 - struct camss_async_subdev); 4285 - fwnode_handle_put(remote); 4275 + csd = v4l2_async_nf_add_fwnode_remote(&camss->notifier, ep, 4276 + typeof(*csd)); 4286 4277 if (IS_ERR(csd)) { 4287 4278 ret = PTR_ERR(csd); 4288 4279 goto err_cleanup;