diff options
Diffstat (limited to 'include/media/v4l2-async.h')
-rw-r--r-- | include/media/v4l2-async.h | 39 |
1 files changed, 30 insertions, 9 deletions
diff --git a/include/media/v4l2-async.h b/include/media/v4l2-async.h index 6152434cbe82..1592d323c577 100644 --- a/include/media/v4l2-async.h +++ b/include/media/v4l2-async.h | |||
@@ -28,7 +28,7 @@ struct v4l2_async_notifier; | |||
28 | * in order to identify a match | 28 | * in order to identify a match |
29 | * | 29 | * |
30 | * @V4L2_ASYNC_MATCH_CUSTOM: Match will use the logic provided by &struct | 30 | * @V4L2_ASYNC_MATCH_CUSTOM: Match will use the logic provided by &struct |
31 | * v4l2_async_subdev.match ops | 31 | * v4l2_async_subdev.match ops |
32 | * @V4L2_ASYNC_MATCH_DEVNAME: Match will use the device name | 32 | * @V4L2_ASYNC_MATCH_DEVNAME: Match will use the device name |
33 | * @V4L2_ASYNC_MATCH_I2C: Match will check for I2C adapter ID and address | 33 | * @V4L2_ASYNC_MATCH_I2C: Match will check for I2C adapter ID and address |
34 | * @V4L2_ASYNC_MATCH_FWNODE: Match will use firmware node | 34 | * @V4L2_ASYNC_MATCH_FWNODE: Match will use firmware node |
@@ -48,6 +48,31 @@ enum v4l2_async_match_type { | |||
48 | * | 48 | * |
49 | * @match_type: type of match that will be used | 49 | * @match_type: type of match that will be used |
50 | * @match: union of per-bus type matching data sets | 50 | * @match: union of per-bus type matching data sets |
51 | * @match.fwnode: | ||
52 | * pointer to &struct fwnode_handle to be matched. | ||
53 | * Used if @match_type is %V4L2_ASYNC_MATCH_FWNODE. | ||
54 | * @match.device_name: | ||
55 | * string containing the device name to be matched. | ||
56 | * Used if @match_type is %V4L2_ASYNC_MATCH_DEVNAME. | ||
57 | * @match.i2c: embedded struct with I2C parameters to be matched. | ||
58 | * Both @match.i2c.adapter_id and @match.i2c.address | ||
59 | * should be matched. | ||
60 | * Used if @match_type is %V4L2_ASYNC_MATCH_I2C. | ||
61 | * @match.i2c.adapter_id: | ||
62 | * I2C adapter ID to be matched. | ||
63 | * Used if @match_type is %V4L2_ASYNC_MATCH_I2C. | ||
64 | * @match.i2c.address: | ||
65 | * I2C address to be matched. | ||
66 | * Used if @match_type is %V4L2_ASYNC_MATCH_I2C. | ||
67 | * @match.custom: | ||
68 | * Driver-specific match criteria. | ||
69 | * Used if @match_type is %V4L2_ASYNC_MATCH_CUSTOM. | ||
70 | * @match.custom.match: | ||
71 | * Driver-specific match function to be used if | ||
72 | * %V4L2_ASYNC_MATCH_CUSTOM. | ||
73 | * @match.custom.priv: | ||
74 | * Driver-specific private struct with match parameters | ||
75 | * to be used if %V4L2_ASYNC_MATCH_CUSTOM. | ||
51 | * @list: used to link struct v4l2_async_subdev objects, waiting to be | 76 | * @list: used to link struct v4l2_async_subdev objects, waiting to be |
52 | * probed, to a notifier->waiting list | 77 | * probed, to a notifier->waiting list |
53 | * | 78 | * |
@@ -58,12 +83,8 @@ enum v4l2_async_match_type { | |||
58 | struct v4l2_async_subdev { | 83 | struct v4l2_async_subdev { |
59 | enum v4l2_async_match_type match_type; | 84 | enum v4l2_async_match_type match_type; |
60 | union { | 85 | union { |
61 | struct { | 86 | struct fwnode_handle *fwnode; |
62 | struct fwnode_handle *fwnode; | 87 | const char *device_name; |
63 | } fwnode; | ||
64 | struct { | ||
65 | const char *name; | ||
66 | } device_name; | ||
67 | struct { | 88 | struct { |
68 | int adapter_id; | 89 | int adapter_id; |
69 | unsigned short address; | 90 | unsigned short address; |
@@ -167,7 +188,7 @@ void v4l2_async_notifier_cleanup(struct v4l2_async_notifier *notifier); | |||
167 | 188 | ||
168 | /** | 189 | /** |
169 | * v4l2_async_register_subdev - registers a sub-device to the asynchronous | 190 | * v4l2_async_register_subdev - registers a sub-device to the asynchronous |
170 | * subdevice framework | 191 | * subdevice framework |
171 | * | 192 | * |
172 | * @sd: pointer to &struct v4l2_subdev | 193 | * @sd: pointer to &struct v4l2_subdev |
173 | */ | 194 | */ |
@@ -197,7 +218,7 @@ int __must_check v4l2_async_register_subdev_sensor_common( | |||
197 | 218 | ||
198 | /** | 219 | /** |
199 | * v4l2_async_unregister_subdev - unregisters a sub-device to the asynchronous | 220 | * v4l2_async_unregister_subdev - unregisters a sub-device to the asynchronous |
200 | * subdevice framework | 221 | * subdevice framework |
201 | * | 222 | * |
202 | * @sd: pointer to &struct v4l2_subdev | 223 | * @sd: pointer to &struct v4l2_subdev |
203 | */ | 224 | */ |