The patch number 10879 was added via Hans Verkuil <[email protected]>
to http://linuxtv.org/hg/v4l-dvb master development tree.
Kernel patches in this development tree may be modified to be backward
compatible with older kernels. Compatibility modifications will be
removed before inclusion into the mainstream Kernel
If anyone has any objections, please let us know by sending a message to:
Linux Media Mailing List <[email protected]>
------
From: Hans Verkuil <[email protected]>
v4l/compat.h: add clamp_val
Priority: normal
Signed-off-by: Hans Verkuil <[email protected]>
---
v4l/compat.h | 6 ++++++
1 file changed, 6 insertions(+)
diff -r 6bd427caa0cb -r fb2e5a22c5b2 v4l/compat.h
--- a/v4l/compat.h Fri Mar 06 08:31:39 2009 -0300
+++ b/v4l/compat.h Fri Mar 06 17:43:12 2009 +0100
@@ -238,6 +238,12 @@ static inline int list_is_singular(const
min_t( __typeof__( x ), \
( h ), \
( x ) ) )
+#define clamp_val(val, min, max) ({ \
+ typeof(val) __val = (val); \
+ typeof(val) __min = (min); \
+ typeof(val) __max = (max); \
+ __val = __val < __min ? __min : __val; \
+ __val > __max ? __max : __val; })
#endif
#ifdef NEED_ALGO_CONTROL
---
Patch is available at:
http://linuxtv.org/hg/v4l-dvb/rev/fb2e5a22c5b2e1d6741b158b4168534895586071
_______________________________________________
linuxtv-commits mailing list
[email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits