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

[media] v4l2-common.h: Add documentation for other functions

Not all functions at v4l2-common.h are documented. Add
documentation for some other ones.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

+38 -5
+38 -5
include/media/v4l2-common.h
··· 78 78 v4l2_printk(KERN_DEBUG, dev, fmt , ## arg); \ 79 79 } while (0) 80 80 81 - /* ------------------------------------------------------------------------- */ 81 + /** 82 + * v4l2_ctrl_query_fill- Fill in a struct v4l2_queryctrl 83 + * 84 + * @qctrl: pointer to the &struct v4l2_queryctrl to be filled 85 + * @min: minimum value for the control 86 + * @max: maximum value for the control 87 + * @step: control step 88 + * @def: default value for the control 89 + * 90 + * Fills the &struct v4l2_queryctrl fields for the query control. 91 + * 92 + * .. note:: 93 + * 94 + * This function assumes that the @qctrl->id field is filled. 95 + * 96 + * Returns -EINVAL if the control is not known by the V4L2 core, 0 on success. 97 + */ 82 98 83 - int v4l2_ctrl_query_fill(struct v4l2_queryctrl *qctrl, s32 min, s32 max, s32 step, s32 def); 99 + int v4l2_ctrl_query_fill(struct v4l2_queryctrl *qctrl, 100 + s32 min, s32 max, s32 step, s32 def); 84 101 85 102 /* ------------------------------------------------------------------------- */ 86 103 ··· 189 172 190 173 struct spi_device; 191 174 192 - /* Load an spi module and return an initialized v4l2_subdev struct. 193 - The client_type argument is the name of the chip that's on the adapter. */ 175 + /** 176 + * v4l2_spi_new_subdev - Load an spi module and return an initialized 177 + * &struct v4l2_subdev. 178 + * 179 + * 180 + * @v4l2_dev: pointer to &struct v4l2_device. 181 + * @master: pointer to struct spi_master. 182 + * @info: pointer to struct spi_board_info. 183 + * 184 + * returns a &struct v4l2_subdev pointer. 185 + */ 194 186 struct v4l2_subdev *v4l2_spi_new_subdev(struct v4l2_device *v4l2_dev, 195 187 struct spi_master *master, struct spi_board_info *info); 196 188 197 - /* Initialize a v4l2_subdev with data from an spi_device struct */ 189 + /** 190 + * v4l2_spi_subdev_init - Initialize a v4l2_subdev with data from an 191 + * spi_device struct. 192 + * 193 + * @sd: pointer to &struct v4l2_subdev 194 + * @spi: pointer to struct spi_device. 195 + * @ops: pointer to &struct v4l2_subdev_ops 196 + */ 198 197 void v4l2_spi_subdev_init(struct v4l2_subdev *sd, struct spi_device *spi, 199 198 const struct v4l2_subdev_ops *ops); 200 199 #endif