]> git.baikalelectronics.ru Git - kernel.git/commit
media: v4l2-subdev: add v4l2_subdev_get_fwnode_pad_1_to_1
authorSteve Longerbeam <slongerbeam@gmail.com>
Fri, 1 May 2020 17:15:36 +0000 (19:15 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Mon, 18 May 2020 09:12:52 +0000 (11:12 +0200)
commit5737c86ad421a57109d788225e7496a3819ae38b
treeedfe3e69454373d9a5c021108f4e73630acc04e8
parent9be000cfe112216d0824e4236f54beb06986e307
media: v4l2-subdev: add v4l2_subdev_get_fwnode_pad_1_to_1

Add a convenience function that can be used as the .get_fwnode_pad
operation for subdevices that map port numbers and pad indexes 1:1.
The function verifies the endpoint is owned by the subdevice, and if
so returns the endpoint port number.

Signed-off-by: Steve Longerbeam <slongerbeam@gmail.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/v4l2-core/v4l2-subdev.c
include/media/v4l2-subdev.h