projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2b59125
)
V4L/DVB: Video : pwc : Fix regression in pwc_set_shutter_speed caused by bad constan...
author
Martin Fuzzey
<
[email protected]
>
Thu, 11 Feb 2010 13:50:31 +0000
(10:50 -0300)
committer
Mauro Carvalho Chehab
<
[email protected]
>
Fri, 19 Feb 2010 05:19:02 +0000
(
03:19
-0200)
Regression was caused by my commit
6b35ca0d3d586b8ecb8396821af21186e20afaf0
which determined message size using sizeof rather than hardcoded constants.
Unfortunately pwc_set_shutter_speed reuses a 2 byte buffer for a one byte
message too so the sizeof was bogus in this case.
All other uses of sizeof checked and are ok.
Acked-by: Laurent Pinchart <
[email protected]
>
Cc:
[email protected]
Signed-off-by: Martin Fuzzey <
[email protected]
>
Signed-off-by: Mauro Carvalho Chehab <
[email protected]
>
drivers/media/video/pwc/pwc-ctrl.c
patch
|
blob
|
history
diff --git
a/drivers/media/video/pwc/pwc-ctrl.c
b/drivers/media/video/pwc/pwc-ctrl.c
index 50b415e07edaba9280516850d8856a487cc29d44..f7f7e04cf4853e02a5c0cd11d051433e6387f1a5 100644
(file)
--- a/
drivers/media/video/pwc/pwc-ctrl.c
+++ b/
drivers/media/video/pwc/pwc-ctrl.c
@@
-753,7
+753,7
@@
int pwc_set_shutter_speed(struct pwc_device *pdev, int mode, int value)
buf[0] = 0xff; /* fixed */
ret = send_control_msg(pdev,
- SET_LUM_CTL, SHUTTER_MODE_FORMATTER, &buf,
sizeof(buf)
);
+ SET_LUM_CTL, SHUTTER_MODE_FORMATTER, &buf,
1
);
if (!mode && ret >= 0) {
if (value < 0)