aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2011-04-07 08:38:53 (GMT)
committerHans Verkuil <hverkuil@xs4all.nl>2011-04-07 08:38:53 (GMT)
commitcd83b3f0f6a3a734147665a907f573e95c58dce2 (patch)
tree0e9c05d69f26e84507c6aec7cebe6b4be276d2b2
parent139af0392c9b3bb0cf13235762931b2f93f89c61 (diff)
Add missing find_next_bit_le and find_next_zero_bit_le for kernels < 2.6.39.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
-rw-r--r--v4l/compat.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/v4l/compat.h b/v4l/compat.h
index bc8d71f..c081032 100644
--- a/v4l/compat.h
+++ b/v4l/compat.h
@@ -20,6 +20,21 @@
#define EXPERIMENTAL_TREE
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 39)
+#include <asm/bitops.h>
+static inline unsigned long find_next_zero_bit_le(const void *addr,
+ unsigned long size, unsigned long offset)
+{
+ return find_next_zero_bit(addr, size, offset);
+}
+
+static inline unsigned long find_next_bit_le(const void *addr,
+ unsigned long size, unsigned long offset)
+{
+ return find_next_bit(addr, size, offset);
+}
+#endif
+
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 34)
#define usb_alloc_coherent(dev, size, mem_flags, dma) usb_buffer_alloc(dev, size, mem_flags, dma)
#define usb_free_coherent(dev, size, addr, dma) usb_buffer_free(dev, size, addr, dma)

Privacy Policy