diff options
author | Andy Walls <awalls@md.metrocast.net> | 2010-12-18 10:48:17 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-12-29 08:17:10 -0200 |
commit | b0c45686c8e8aecc7b0cd04d9b6af48d74418d53 (patch) | |
tree | d817077c5820d2ecec94d9cecf508a1e5df51513 /drivers/media/video/ivtv/ivtv-vbi.h | |
parent | 754f9969c323559a12bce1475f3c1e6574129856 (diff) | |
download | kernel_samsung_smdk4412-b0c45686c8e8aecc7b0cd04d9b6af48d74418d53.zip kernel_samsung_smdk4412-b0c45686c8e8aecc7b0cd04d9b6af48d74418d53.tar.gz kernel_samsung_smdk4412-b0c45686c8e8aecc7b0cd04d9b6af48d74418d53.tar.bz2 |
[media] ivtv: ivtv_write_vbi() should use copy_from_user() for user data buffers
ivtv_write_vbi() is used for both VBI data that came from the
driver internally and VBI data that came from the user. However,
it did not use copy_from_user() for reading the VBI data from the
user buffers.
This change adds a new version of the function,
ivtv_write_vbi_from_user(), that uses copy_from_user() to read the VBI
data provided via user buffers.
This should resolve a sparse build warning reported by Dave Gilbert.
Reported-by: Dr. David Alan Gilbert <linux at treblig.org>
Signed-off-by: Andy Walls <awalls@md.metrocast.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/ivtv/ivtv-vbi.h')
-rw-r--r-- | drivers/media/video/ivtv/ivtv-vbi.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/media/video/ivtv/ivtv-vbi.h b/drivers/media/video/ivtv/ivtv-vbi.h index 970567b..eda38d0 100644 --- a/drivers/media/video/ivtv/ivtv-vbi.h +++ b/drivers/media/video/ivtv/ivtv-vbi.h @@ -20,7 +20,9 @@ #ifndef IVTV_VBI_H #define IVTV_VBI_H -void ivtv_write_vbi(struct ivtv *itv, const struct v4l2_sliced_vbi_data *sliced, size_t count); +void ivtv_write_vbi_from_user(struct ivtv *itv, + const struct v4l2_sliced_vbi_data __user *sliced, + size_t count); void ivtv_process_vbi_data(struct ivtv *itv, struct ivtv_buffer *buf, u64 pts_stamp, int streamtype); int ivtv_used_line(struct ivtv *itv, int line, int field); |