summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/ivtv/ivtv-driver.h
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/video/ivtv/ivtv-driver.h')
-rw-r--r--linux/drivers/media/video/ivtv/ivtv-driver.h24
1 files changed, 17 insertions, 7 deletions
diff --git a/linux/drivers/media/video/ivtv/ivtv-driver.h b/linux/drivers/media/video/ivtv/ivtv-driver.h
index 389eded7f..3daf1a9fc 100644
--- a/linux/drivers/media/video/ivtv/ivtv-driver.h
+++ b/linux/drivers/media/video/ivtv/ivtv-driver.h
@@ -53,7 +53,9 @@
#include <linux/byteorder/swab.h>
#include <linux/pagemap.h>
#include <linux/workqueue.h>
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15)
#include <linux/mutex.h>
+#endif
#include <asm/uaccess.h>
#include <asm/system.h>
@@ -63,7 +65,7 @@
#include <media/tuner.h>
#include <media/cx2341x.h>
-//#define HAVE_XC3028 1
+/* #define HAVE_XC3028 1 */
#include <media/ivtv.h>
@@ -97,13 +99,13 @@
extern const u32 yuv_offset[4];
-// Maximum ivtv driver instances.
-// Based on 6 PVR500s each with two PVR15s...
-// TODO: make this dynamic. I believe it is only a global in order to support
-// ivtv-fb. There must be a better way to do that.
+/* Maximum ivtv driver instances.
+ Based on 6 PVR500s each with two PVR15s...
+ TODO: make this dynamic. I believe it is only a global in order to support
+ ivtv-fb. There must be a better way to do that. */
#define IVTV_MAX_CARDS 12
-// Supported cards
+/* Supported cards */
#define IVTV_CARD_PVR_250 0 /* WinTV PVR 250 */
#define IVTV_CARD_PVR_350 1 /* encoder, decoder, tv-out */
#define IVTV_CARD_PVR_150 2 /* WinTV PVR 150 and PVR 500 (really just two
@@ -413,7 +415,11 @@ struct ivtv_SG_element {
};
struct ivtv_user_dma {
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15)
struct mutex lock;
+#else
+ struct semaphore lock;
+#endif
int page_count;
struct page *map[IVTV_DMA_SG_OSD_ENT];
@@ -703,7 +709,7 @@ struct ivtv {
u32 v4l2_cap; /* V4L2 capabilities of card */
u32 hw_flags; /* Hardware description of the board */
- // controlling Video decoder function
+ /* controlling Video decoder function */
int (*video_dec_func)(struct ivtv *, unsigned int, void *);
struct ivtv_options options; /* User options */
@@ -778,7 +784,11 @@ struct ivtv {
struct i2c_adapter i2c_adap;
struct i2c_algo_bit_data i2c_algo;
struct i2c_client i2c_client;
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15)
struct mutex i2c_bus_lock;
+#else
+ struct semaphore i2c_bus_lock;
+#endif
int i2c_state;
struct i2c_client *i2c_clients[I2C_CLIENTS_MAX];