]> git.karo-electronics.de Git - linux-beck.git/commit
[media] v4l2-ctrls: rewrite copy routines to operate on union v4l2_ctrl_ptr
authorHans Verkuil <hans.verkuil@cisco.com>
Sun, 27 Apr 2014 06:26:30 +0000 (03:26 -0300)
committerMauro Carvalho Chehab <m.chehab@samsung.com>
Thu, 17 Jul 2014 14:56:48 +0000 (11:56 -0300)
commit000e4f9a5bcf86fb52914c445ce5634b65e910a2
tree88e6df0acadda540020be1d364fcdde2ab8cac91
parent0176077a813933a547b7a913377a87d615b7c108
[media] v4l2-ctrls: rewrite copy routines to operate on union v4l2_ctrl_ptr

In order to implement array support and (for the future) configuration stores
we need to have more generic copy routines that all operate on the v4l2_ctrl_ptr
union. So instead of e.g. using ctrl->cur.string it uses ptr.p_char. This makes
e.g. cur_to_user generic so it can be used to copy any v4l2_ctrl_ptr value to
userspace, not just the (hardcoded) current value.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/v4l2-core/v4l2-ctrls.c