diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2008-07-08 17:40:58 +0200 |
---|---|---|
committer | Hans Verkuil <hverkuil@xs4all.nl> | 2008-07-08 17:40:58 +0200 |
commit | e9314ad63401c89bffe82b165eb7ae630c05a75d (patch) | |
tree | b31a77f9ccfea646348025aae7452e900e61a761 | |
parent | d784aba6717da44bfef18007146f6d00280e39fe (diff) | |
download | mediapointer-dvb-s2-e9314ad63401c89bffe82b165eb7ae630c05a75d.tar.gz mediapointer-dvb-s2-e9314ad63401c89bffe82b165eb7ae630c05a75d.tar.bz2 |
v4l-dvb: remove support for kernels < 2.6.16
From: Hans Verkuil <hverkuil@xs4all.nl>
Phase 4 removes the compatibility support for kernels < 2.6.16.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
146 files changed, 4 insertions, 1241 deletions
diff --git a/linux/drivers/media/common/ir-functions.c b/linux/drivers/media/common/ir-functions.c index 2adbb6e9f..3653b6d37 100644 --- a/linux/drivers/media/common/ir-functions.c +++ b/linux/drivers/media/common/ir-functions.c @@ -67,10 +67,6 @@ void ir_input_init(struct input_dev *dev, struct ir_input_state *ir, if (ir_codes) memcpy(ir->ir_codes, ir_codes, sizeof(ir->ir_codes)); -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) - init_input_dev(dev); -#endif - dev->keycode = ir->ir_codes; dev->keycodesize = sizeof(IR_KEYTAB_TYPE); dev->keycodemax = IR_KEYTAB_SIZE; diff --git a/linux/drivers/media/common/tuners/tda18271-priv.h b/linux/drivers/media/common/tuners/tda18271-priv.h index 2ed61a31f..78417b7c1 100644 --- a/linux/drivers/media/common/tuners/tda18271-priv.h +++ b/linux/drivers/media/common/tuners/tda18271-priv.h @@ -24,11 +24,7 @@ #include <linux/kernel.h> #include <linux/types.h> #include "compat.h" -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include "tuner-i2c.h" #include "tda18271.h" @@ -127,11 +123,7 @@ struct tda18271_priv { struct tda18271_std_map std; struct tda18271_rf_tracking_filter_cal rf_cal_state[8]; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex lock; -#else - struct semaphore lock; -#endif u32 frequency; u32 bandwidth; diff --git a/linux/drivers/media/common/tuners/tuner-xc2028.c b/linux/drivers/media/common/tuners/tuner-xc2028.c index 9d3f397e3..88fd2c91c 100644 --- a/linux/drivers/media/common/tuners/tuner-xc2028.c +++ b/linux/drivers/media/common/tuners/tuner-xc2028.c @@ -14,11 +14,7 @@ #include <linux/videodev2.h> #include <linux/delay.h> #include <media/tuner.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include "compat.h" #include <asm/unaligned.h> #include "tuner-i2c.h" @@ -95,11 +91,7 @@ struct xc2028_data { struct firmware_properties cur_fw; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) struct mutex lock; -#else - struct semaphore lock; -#endif }; #define i2c_send(priv, buf, size) ({ \ diff --git a/linux/drivers/media/dvb/b2c2/flexcop-common.h b/linux/drivers/media/dvb/b2c2/flexcop-common.h index 22fc0490d..166f0fb09 100644 --- a/linux/drivers/media/dvb/b2c2/flexcop-common.h +++ b/linux/drivers/media/dvb/b2c2/flexcop-common.h @@ -10,9 +10,7 @@ #include <linux/pci.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "flexcop-reg.h" @@ -84,11 +82,7 @@ struct flexcop_device { int (*fe_sleep) (struct dvb_frontend *); struct flexcop_i2c_adapter fc_i2c_adap[3]; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex i2c_mutex; -#else - struct semaphore i2c_mutex; -#endif struct module *owner; /* options and status */ diff --git a/linux/drivers/media/dvb/b2c2/flexcop-usb.c b/linux/drivers/media/dvb/b2c2/flexcop-usb.c index d523dd5bf..4be298e90 100644 --- a/linux/drivers/media/dvb/b2c2/flexcop-usb.c +++ b/linux/drivers/media/dvb/b2c2/flexcop-usb.c @@ -550,9 +550,6 @@ MODULE_DEVICE_TABLE (usb, flexcop_usb_table); /* usb specific object needed to register this driver with the usb subsystem */ static struct usb_driver flexcop_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "b2c2_flexcop_usb", .probe = flexcop_usb_probe, .disconnect = flexcop_usb_disconnect, diff --git a/linux/drivers/media/dvb/bt8xx/bt878.h b/linux/drivers/media/dvb/bt8xx/bt878.h index 9bef8bbdb..8319457f7 100644 --- a/linux/drivers/media/dvb/bt8xx/bt878.h +++ b/linux/drivers/media/dvb/bt8xx/bt878.h @@ -26,9 +26,7 @@ #include <linux/sched.h> #include <linux/spinlock.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "bt848.h" #include "bttv.h" @@ -107,11 +105,7 @@ extern int bt878_num; struct bt878 { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex gpio_lock; -#else - struct semaphore gpio_lock; -#endif unsigned int nr; unsigned int bttv_nr; struct i2c_adapter *adapter; diff --git a/linux/drivers/media/dvb/bt8xx/dst_common.h b/linux/drivers/media/dvb/bt8xx/dst_common.h index 47b62ef3c..40e6a88a9 100644 --- a/linux/drivers/media/dvb/bt8xx/dst_common.h +++ b/linux/drivers/media/dvb/bt8xx/dst_common.h @@ -25,9 +25,7 @@ #include <linux/dvb/frontend.h> #include <linux/device.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "bt878.h" #include "dst_ca.h" @@ -140,11 +138,7 @@ struct dst_state { u8 board_info[8]; u32 tuner_type; char *tuner_name; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex dst_mutex; -#else - struct semaphore dst_mutex; -#endif u8 fw_name[8]; struct dvb_device *dst_ca; }; diff --git a/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.c b/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.c index 27d092448..5fb213cf9 100644 --- a/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.c +++ b/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.c @@ -804,15 +804,8 @@ static int __devinit dvb_bt8xx_load_card(struct dvb_bt8xx_card *card, u32 type) return 0; } -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -static int dvb_bt8xx_probe(struct device *dev) -#else static int __devinit dvb_bt8xx_probe(struct bttv_sub_device *sub) -#endif { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - struct bttv_sub_device *sub = to_bttv_sub_dev(dev); -#endif struct dvb_bt8xx_card *card; struct pci_dev* bttv_pci_dev; int ret; @@ -921,25 +914,13 @@ static int __devinit dvb_bt8xx_probe(struct bttv_sub_device *sub) return ret; } -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - dev_set_drvdata(dev, card); -#else dev_set_drvdata(&sub->dev, card); -#endif return 0; } -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -static int dvb_bt8xx_remove(struct device *dev) -#else static void dvb_bt8xx_remove(struct bttv_sub_device *sub) -#endif { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - struct dvb_bt8xx_card *card = dev_get_drvdata(dev); -#else struct dvb_bt8xx_card *card = dev_get_drvdata(&sub->dev); -#endif dprintk("dvb_bt8xx: unloading card%d\n", card->bttv_nr); @@ -957,25 +938,12 @@ static void dvb_bt8xx_remove(struct bttv_sub_device *sub) dvb_unregister_adapter(&card->dvb_adapter); kfree(card); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - return (0); -#endif } static struct bttv_sub_driver driver = { .drv = { .name = "dvb-bt8xx", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .probe = dvb_bt8xx_probe, - .remove = dvb_bt8xx_remove, - /* FIXME: - * .shutdown = dvb_bt8xx_shutdown, - * .suspend = dvb_bt8xx_suspend, - * .resume = dvb_bt8xx_resume, - */ -#endif }, -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) .probe = dvb_bt8xx_probe, .remove = dvb_bt8xx_remove, /* FIXME: @@ -983,7 +951,6 @@ static struct bttv_sub_driver driver = { * .suspend = dvb_bt8xx_suspend, * .resume = dvb_bt8xx_resume, */ -#endif }; static int __init dvb_bt8xx_init(void) diff --git a/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.h b/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.h index 6b4ed25c7..a87b3a417 100644 --- a/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.h +++ b/linux/drivers/media/dvb/bt8xx/dvb-bt8xx.h @@ -27,9 +27,7 @@ #include <linux/i2c.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvbdev.h" #include "dvb_net.h" #include "bttv.h" @@ -44,11 +42,7 @@ #include "tuner-simple.h" struct dvb_bt8xx_card { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif int nfeeds; char card_name[32]; struct dvb_adapter dvb_adapter; diff --git a/linux/drivers/media/dvb/cinergyT2/cinergyT2.c b/linux/drivers/media/dvb/cinergyT2/cinergyT2.c index e1d76b111..52f104d2b 100644 --- a/linux/drivers/media/dvb/cinergyT2/cinergyT2.c +++ b/linux/drivers/media/dvb/cinergyT2/cinergyT2.c @@ -29,9 +29,7 @@ #include <linux/input.h> #include <linux/dvb/frontend.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/mm.h> #include <asm/io.h> @@ -63,15 +61,6 @@ MODULE_PARM_DESC(debug, "Turn on/off debugging (default:off)."); DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define dprintk(level, args...) \ -do { \ - if ((debug & level)) { \ - printk("%s: %s(): ", __stringify(KBUILD_MODNAME), \ - __FUNCTION__); \ - printk(args); } \ -} while (0) -#else #define dprintk(level, args...) \ do { \ if ((debug & level)) { \ @@ -79,7 +68,6 @@ do { \ __func__); \ printk(args); } \ } while (0) -#endif enum cinergyt2_ep1_cmd { CINERGYT2_EP1_PID_TABLE_RESET = 0x01, @@ -132,13 +120,8 @@ static struct dvb_frontend_info cinergyt2_fe_info = { struct cinergyt2 { struct dvb_demux demux; struct usb_device *udev; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex sem; struct mutex wq_sem; -#else - struct semaphore sem; - struct semaphore wq_sem; -#endif struct dvb_adapter adapter; struct dvb_device *fedev; struct dmxdev dmxdev; @@ -896,11 +879,7 @@ static int cinergyt2_register_rc(struct cinergyt2 *cinergyt2) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &cinergyt2->udev->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &cinergyt2->udev->dev; -#else - input_dev->dev = &cinergyt2->udev->dev; -#endif #endif err = input_register_device(input_dev); @@ -1141,9 +1120,6 @@ static const struct usb_device_id cinergyt2_table [] __devinitdata = { MODULE_DEVICE_TABLE(usb, cinergyt2_table); static struct usb_driver cinergyt2_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "cinergyT2", .probe = cinergyt2_probe, .disconnect = cinergyt2_disconnect, diff --git a/linux/drivers/media/dvb/dvb-core/dmxdev.h b/linux/drivers/media/dvb/dvb-core/dmxdev.h index bb416e6c2..7e8137d0b 100644 --- a/linux/drivers/media/dvb/dvb-core/dmxdev.h +++ b/linux/drivers/media/dvb/dvb-core/dmxdev.h @@ -31,9 +31,7 @@ #include <linux/fs.h> #include <linux/string.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/dvb/dmx.h> @@ -76,11 +74,7 @@ struct dmxdev_filter { struct dmxdev *dev; struct dvb_ringbuffer buffer; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex mutex; -#else - struct semaphore mutex; -#endif /* only for sections */ struct timer_list timer; @@ -106,11 +100,7 @@ struct dmxdev { struct dvb_ringbuffer dvr_buffer; #define DVR_BUFFER_SIZE (10*188*1024) -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex mutex; -#else - struct semaphore mutex; -#endif spinlock_t lock; }; diff --git a/linux/drivers/media/dvb/dvb-core/dvb_demux.h b/linux/drivers/media/dvb/dvb-core/dvb_demux.h index 099b149e5..933397c24 100644 --- a/linux/drivers/media/dvb/dvb-core/dvb_demux.h +++ b/linux/drivers/media/dvb/dvb-core/dvb_demux.h @@ -27,9 +27,7 @@ #include <linux/timer.h> #include <linux/spinlock.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "demux.h" @@ -128,11 +126,7 @@ struct dvb_demux { u8 tsbuf[204]; int tsbufp; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex mutex; -#else - struct semaphore mutex; -#endif spinlock_t lock; }; diff --git a/linux/drivers/media/dvb/dvb-core/dvb_frontend.h b/linux/drivers/media/dvb/dvb-core/dvb_frontend.h index fc3213fec..aa4133f0b 100644 --- a/linux/drivers/media/dvb/dvb-core/dvb_frontend.h +++ b/linux/drivers/media/dvb/dvb-core/dvb_frontend.h @@ -35,9 +35,7 @@ #include <linux/module.h> #include <linux/errno.h> #include <linux/delay.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/dvb/frontend.h> @@ -181,11 +179,7 @@ struct dvb_fe_events { int eventr; int overflow; wait_queue_head_t wait_queue; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex mtx; -#else - struct semaphore mtx; -#endif }; struct dvb_frontend { diff --git a/linux/drivers/media/dvb/dvb-core/dvb_net.c b/linux/drivers/media/dvb/dvb-core/dvb_net.c index 2d2da4dff..3c0106f65 100644 --- a/linux/drivers/media/dvb/dvb-core/dvb_net.c +++ b/linux/drivers/media/dvb/dvb-core/dvb_net.c @@ -63,9 +63,7 @@ #include <asm/uaccess.h> #include <linux/crc32.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvb_demux.h" #include "dvb_net.h" @@ -161,11 +159,7 @@ struct dvb_net_priv { unsigned char ule_bridged; /* Whether the ULE_BRIDGED extension header was found. */ int ule_sndu_remain; /* Nr. of bytes still required for current ULE SNDU. */ unsigned long ts_count; /* Current ts cell counter. */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex mutex; -#else - struct semaphore mutex; -#endif }; diff --git a/linux/drivers/media/dvb/dvb-core/dvbdev.c b/linux/drivers/media/dvb/dvb-core/dvbdev.c index 2da27de38..0ae0e5852 100644 --- a/linux/drivers/media/dvb/dvb-core/dvbdev.c +++ b/linux/drivers/media/dvb/dvb-core/dvbdev.c @@ -32,9 +32,7 @@ #include <linux/fs.h> #include <linux/cdev.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvbdev.h" static int dvbdev_debug; diff --git a/linux/drivers/media/dvb/dvb-usb/a800.c b/linux/drivers/media/dvb/dvb-usb/a800.c index de7194ee7..dc8c8784c 100644 --- a/linux/drivers/media/dvb/dvb-usb/a800.c +++ b/linux/drivers/media/dvb/dvb-usb/a800.c @@ -164,9 +164,6 @@ static struct dvb_usb_device_properties a800_properties = { }; static struct usb_driver a800_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_a800", .probe = a800_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/af9005.c b/linux/drivers/media/dvb/dvb-usb/af9005.c index 04270dd3d..cfe71feef 100644 --- a/linux/drivers/media/dvb/dvb-usb/af9005.c +++ b/linux/drivers/media/dvb/dvb-usb/af9005.c @@ -1099,9 +1099,6 @@ static struct dvb_usb_device_properties af9005_properties = { /* usb specific object needed to register this driver with the usb subsystem */ static struct usb_driver af9005_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_af9005", .probe = af9005_usb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/anysee.c b/linux/drivers/media/dvb/dvb-usb/anysee.c index 224919559..adfd4fc82 100644 --- a/linux/drivers/media/dvb/dvb-usb/anysee.c +++ b/linux/drivers/media/dvb/dvb-usb/anysee.c @@ -521,9 +521,6 @@ static struct dvb_usb_device_properties anysee_properties = { }; static struct usb_driver anysee_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_anysee", .probe = anysee_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/au6610.c b/linux/drivers/media/dvb/dvb-usb/au6610.c index fc3375c60..eb34cc389 100644 --- a/linux/drivers/media/dvb/dvb-usb/au6610.c +++ b/linux/drivers/media/dvb/dvb-usb/au6610.c @@ -225,9 +225,6 @@ static struct dvb_usb_device_properties au6610_properties = { }; static struct usb_driver au6610_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_au6610", .probe = au6610_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/cxusb.c b/linux/drivers/media/dvb/dvb-usb/cxusb.c index 843ff4769..9a3e97247 100644 --- a/linux/drivers/media/dvb/dvb-usb/cxusb.c +++ b/linux/drivers/media/dvb/dvb-usb/cxusb.c @@ -1306,9 +1306,6 @@ static struct dvb_usb_device_properties cxusb_aver_a868r_properties = { }; static struct usb_driver cxusb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_cxusb", .probe = cxusb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c b/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c index 2ac86685d..eeef50bff 100644 --- a/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c +++ b/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c @@ -436,9 +436,6 @@ static struct dvb_usb_device_properties artec_t1_usb2_properties = { }; static struct usb_driver dibusb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_dibusb_mb", .probe = dibusb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c b/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c index b1658ac6b..059cec955 100644 --- a/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c +++ b/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c @@ -124,9 +124,6 @@ static struct dvb_usb_device_properties dibusb_mc_properties = { }; static struct usb_driver dibusb_mc_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_dibusb_mc", .probe = dibusb_mc_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/digitv.c b/linux/drivers/media/dvb/dvb-usb/digitv.c index 1394b3e6b..b545cf3ea 100644 --- a/linux/drivers/media/dvb/dvb-usb/digitv.c +++ b/linux/drivers/media/dvb/dvb-usb/digitv.c @@ -330,9 +330,6 @@ static struct dvb_usb_device_properties digitv_properties = { }; static struct usb_driver digitv_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_digitv", .probe = digitv_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/dtt200u.c b/linux/drivers/media/dvb/dvb-usb/dtt200u.c index 5fcae7925..81a6cbf60 100644 --- a/linux/drivers/media/dvb/dvb-usb/dtt200u.c +++ b/linux/drivers/media/dvb/dvb-usb/dtt200u.c @@ -334,9 +334,6 @@ static struct dvb_usb_device_properties wt220u_miglia_properties = { /* usb specific object needed to register this driver with the usb subsystem */ static struct usb_driver dtt200u_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_dtt200u", .probe = dtt200u_usb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c b/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c index b2fae925a..ec95bdf90 100644 --- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c +++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c @@ -125,10 +125,8 @@ int dvb_usb_remote_init(struct dvb_usb_device *d) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &d->udev->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &d->udev->dev; #endif -#endif /* set the bits for the keys */ deb_rc("key map size: %d\n", d->props.rc_key_map_size); diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb.h b/linux/drivers/media/dvb/dvb-usb/dvb-usb.h index f8528bf74..72503e2da 100644 --- a/linux/drivers/media/dvb/dvb-usb/dvb-usb.h +++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb.h @@ -14,9 +14,7 @@ #include <linux/usb.h> #include <linux/firmware.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvb_frontend.h" #include "dvb_demux.h" @@ -354,18 +352,10 @@ struct dvb_usb_device { int powered; /* locking */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex usb_mutex; -#else - struct semaphore usb_mutex; -#endif /* i2c */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex i2c_mutex; -#else - struct semaphore i2c_mutex; -#endif struct i2c_adapter i2c_adap; int num_adapters_initialized; diff --git a/linux/drivers/media/dvb/dvb-usb/gl861.c b/linux/drivers/media/dvb/dvb-usb/gl861.c index 36700b67d..6f596ed41 100644 --- a/linux/drivers/media/dvb/dvb-usb/gl861.c +++ b/linux/drivers/media/dvb/dvb-usb/gl861.c @@ -200,9 +200,6 @@ static struct dvb_usb_device_properties gl861_properties = { }; static struct usb_driver gl861_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_gl861", .probe = gl861_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/gp8psk.c b/linux/drivers/media/dvb/dvb-usb/gp8psk.c index 0a152fcb5..6eb8cc37f 100644 --- a/linux/drivers/media/dvb/dvb-usb/gp8psk.c +++ b/linux/drivers/media/dvb/dvb-usb/gp8psk.c @@ -279,9 +279,6 @@ static struct dvb_usb_device_properties gp8psk_properties = { /* usb specific object needed to register this driver with the usb subsystem */ static struct usb_driver gp8psk_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_gp8psk", .probe = gp8psk_usb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/m920x.c b/linux/drivers/media/dvb/dvb-usb/m920x.c index 5a7766fab..54626a0db 100644 --- a/linux/drivers/media/dvb/dvb-usb/m920x.c +++ b/linux/drivers/media/dvb/dvb-usb/m920x.c @@ -894,9 +894,6 @@ static struct dvb_usb_device_properties dposh_properties = { }; static struct usb_driver m920x_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_m920x", .probe = m920x_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c b/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c index a346040ca..07fb843c7 100644 --- a/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c +++ b/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c @@ -214,9 +214,6 @@ static struct dvb_usb_device_properties nova_t_properties = { }; static struct usb_driver nova_t_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_nova_t_usb2", .probe = nova_t_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/umt-010.c b/linux/drivers/media/dvb/dvb-usb/umt-010.c index b6a3cbc44..118aab1a3 100644 --- a/linux/drivers/media/dvb/dvb-usb/umt-010.c +++ b/linux/drivers/media/dvb/dvb-usb/umt-010.c @@ -135,9 +135,6 @@ static struct dvb_usb_device_properties umt_properties = { }; static struct usb_driver umt_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_umt_010", .probe = umt_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/vp702x.c b/linux/drivers/media/dvb/dvb-usb/vp702x.c index 9d286d430..c1db3271f 100644 --- a/linux/drivers/media/dvb/dvb-usb/vp702x.c +++ b/linux/drivers/media/dvb/dvb-usb/vp702x.c @@ -351,9 +351,6 @@ static struct dvb_usb_device_properties vp702x_properties = { /* usb specific object needed to register this driver with the usb subsystem */ static struct usb_driver vp702x_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_vp702x", .probe = vp702x_usb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/dvb-usb/vp7045.c b/linux/drivers/media/dvb/dvb-usb/vp7045.c index b45498911..8fc2ba02a 100644 --- a/linux/drivers/media/dvb/dvb-usb/vp7045.c +++ b/linux/drivers/media/dvb/dvb-usb/vp7045.c @@ -288,9 +288,6 @@ static struct dvb_usb_device_properties vp7045_properties = { /* usb specific object needed to register this driver with the usb subsystem */ static struct usb_driver vp7045_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif .name = "dvb_usb_vp7045", .probe = vp7045_usb_probe, .disconnect = dvb_usb_device_exit, diff --git a/linux/drivers/media/dvb/frontends/bcm3510.c b/linux/drivers/media/dvb/frontends/bcm3510.c index ca9a55ae9..1cd63a4df 100644 --- a/linux/drivers/media/dvb/frontends/bcm3510.c +++ b/linux/drivers/media/dvb/frontends/bcm3510.c @@ -39,9 +39,7 @@ #include <linux/string.h> #include <linux/slab.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvb_frontend.h" #include "bcm3510.h" @@ -54,11 +52,7 @@ struct bcm3510_state { struct dvb_frontend frontend; /* demodulator private data */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex hab_mutex; -#else - struct semaphore hab_mutex; -#endif u8 firmware_loaded:1; unsigned long next_status_check; diff --git a/linux/drivers/media/dvb/ttpci/av7110.h b/linux/drivers/media/dvb/ttpci/av7110.h index 6cbf79c3e..61e4a7569 100644 --- a/linux/drivers/media/dvb/ttpci/av7110.h +++ b/linux/drivers/media/dvb/ttpci/av7110.h @@ -14,9 +14,7 @@ #include <linux/dvb/osd.h> #include <linux/dvb/net.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvbdev.h" #include "demux.h" @@ -154,11 +152,7 @@ struct av7110 { /* DEBI and polled command interface */ spinlock_t debilock; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex dcomlock; -#else - struct semaphore dcomlock; -#endif volatile int debitype; volatile int debilen; @@ -177,11 +171,7 @@ struct av7110 { int osdwin; /* currently active window */ u16 osdbpp[8]; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex osd_mutex; -#else - struct semaphore osd_mutex; -#endif /* CA */ @@ -206,11 +196,7 @@ struct av7110 { struct tasklet_struct vpe_tasklet; int fe_synced; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex pid_mutex; -#else - struct semaphore pid_mutex; -#endif int video_blank; struct video_status videostate; diff --git a/linux/drivers/media/dvb/ttpci/av7110_ir.c b/linux/drivers/media/dvb/ttpci/av7110_ir.c index 084164147..e0f9f760a 100644 --- a/linux/drivers/media/dvb/ttpci/av7110_ir.c +++ b/linux/drivers/media/dvb/ttpci/av7110_ir.c @@ -358,11 +358,7 @@ int __devinit av7110_ir_init(struct av7110 *av7110) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &av7110->dev->pci->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &av7110->dev->pci->dev; -#else - input_dev->dev = &av7110->dev->pci->dev; -#endif #endif /* initial keymap */ memcpy(av7110->ir.key_map, default_key_map, sizeof av7110->ir.key_map); diff --git a/linux/drivers/media/dvb/ttpci/budget-ci.c b/linux/drivers/media/dvb/ttpci/budget-ci.c index 8234c397c..f7388e5fc 100644 --- a/linux/drivers/media/dvb/ttpci/budget-ci.c +++ b/linux/drivers/media/dvb/ttpci/budget-ci.c @@ -211,11 +211,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &saa->pci->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &saa->pci->dev; -#else - input_dev->dev = &saa->pci->dev; -#endif #endif /* Select keymap and address */ diff --git a/linux/drivers/media/dvb/ttpci/budget.h b/linux/drivers/media/dvb/ttpci/budget.h index 0e8e596d6..6539c0171 100644 --- a/linux/drivers/media/dvb/ttpci/budget.h +++ b/linux/drivers/media/dvb/ttpci/budget.h @@ -12,9 +12,7 @@ #include <linux/module.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <media/saa7146.h> @@ -24,13 +22,8 @@ extern int budget_debug; #undef dprintk #endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define dprintk(level,args...) \ - do { if ((budget_debug & level)) { printk("%s: %s(): ",__stringify(KBUILD_MODNAME), __func__); printk(args); } } while (0) -#else #define dprintk(level,args...) \ do { if ((budget_debug & level)) { printk("%s: %s(): ", KBUILD_MODNAME, __func__); printk(args); } } while (0) -#endif struct budget_info { char *name; diff --git a/linux/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c b/linux/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c index fa84a6b49..8786d3d6f 100644 --- a/linux/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c +++ b/linux/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c @@ -19,9 +19,7 @@ #include <linux/errno.h> #include <linux/jiffies.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dvb_frontend.h" #include "dmxdev.h" @@ -87,13 +85,8 @@ struct ttusb { struct dvb_net dvbnet; /* and one for USB access. */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex semi2c; struct mutex semusb; -#else - struct semaphore semi2c; - struct semaphore semusb; -#endif struct dvb_adapter adapter; struct usb_device *dev; diff --git a/linux/drivers/media/dvb/ttusb-dec/ttusb_dec.c b/linux/drivers/media/dvb/ttusb-dec/ttusb_dec.c index 052979dc9..8491913aa 100644 --- a/linux/drivers/media/dvb/ttusb-dec/ttusb_dec.c +++ b/linux/drivers/media/dvb/ttusb-dec/ttusb_dec.c @@ -33,9 +33,7 @@ #include <linux/input.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dmxdev.h" #include "dvb_demux.h" @@ -120,11 +118,7 @@ struct ttusb_dec { unsigned int out_pipe; unsigned int irq_pipe; enum ttusb_dec_interface interface; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex usb_mutex; -#else - struct semaphore usb_mutex; -#endif void *irq_buffer; struct urb *irq_urb; @@ -133,11 +127,7 @@ struct ttusb_dec { dma_addr_t iso_dma_handle; struct urb *iso_urb[ISO_BUF_COUNT]; int iso_stream_count; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex iso_mutex; -#else - struct semaphore iso_mutex; -#endif u8 packet[MAX_PVA_LENGTH + 4]; enum ttusb_dec_packet_type packet_type; diff --git a/linux/drivers/media/radio/miropcm20-rds-core.c b/linux/drivers/media/radio/miropcm20-rds-core.c index a29942cdf..e18e2a4a8 100644 --- a/linux/drivers/media/radio/miropcm20-rds-core.c +++ b/linux/drivers/media/radio/miropcm20-rds-core.c @@ -19,9 +19,7 @@ #include <linux/init.h> #include <linux/slab.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <asm/io.h> #include "oss/aci.h" @@ -29,11 +27,7 @@ #define DEBUG 0 -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) static struct mutex aci_rds_mutex; -#else -static struct semaphore aci_rds_mutex; -#endif #define RDS_DATASHIFT 2 /* Bit 2 */ #define RDS_DATAMASK (1 << RDS_DATASHIFT) diff --git a/linux/drivers/media/radio/radio-aimslab.c b/linux/drivers/media/radio/radio-aimslab.c index 7b9afd7e6..06313a334 100644 --- a/linux/drivers/media/radio/radio-aimslab.c +++ b/linux/drivers/media/radio/radio-aimslab.c @@ -47,11 +47,7 @@ static int io = CONFIG_RADIO_RTRACK_PORT; static int radio_nr = -1; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) static struct mutex lock; -#else -static struct semaphore lock; -#endif struct rt_device { diff --git a/linux/drivers/media/radio/radio-aztech.c b/linux/drivers/media/radio/radio-aztech.c index 3e18a7687..1fbf32d15 100644 --- a/linux/drivers/media/radio/radio-aztech.c +++ b/linux/drivers/media/radio/radio-aztech.c @@ -66,11 +66,7 @@ static struct v4l2_queryctrl radio_qctrl[] = { static int io = CONFIG_RADIO_AZTECH_PORT; static int radio_nr = -1; static int radio_wait_time = 1000; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) static struct mutex lock; -#else -static struct semaphore lock; -#endif struct az_device { diff --git a/linux/drivers/media/radio/radio-maxiradio.c b/linux/drivers/media/radio/radio-maxiradio.c index 17fa03d5f..ae3fe626e 100644 --- a/linux/drivers/media/radio/radio-maxiradio.c +++ b/linux/drivers/media/radio/radio-maxiradio.c @@ -39,9 +39,7 @@ #include <linux/delay.h> #include <asm/io.h> #include <asm/uaccess.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/pci.h> #include <linux/videodev2.h> @@ -121,11 +119,7 @@ static struct radio_device unsigned long freq; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif } radio_unit = { .muted =1, .freq = FREQ_LO, diff --git a/linux/drivers/media/radio/radio-sf16fmi.c b/linux/drivers/media/radio/radio-sf16fmi.c index e559eae5a..adc140f7b 100644 --- a/linux/drivers/media/radio/radio-sf16fmi.c +++ b/linux/drivers/media/radio/radio-sf16fmi.c @@ -28,9 +28,7 @@ #include <linux/isapnp.h> #include <asm/io.h> /* outb, outb_p */ #include <asm/uaccess.h> /* copy to/from user */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #define RADIO_VERSION KERNEL_VERSION(0,0,2) @@ -56,11 +54,7 @@ struct fmi_device static int io = -1; static int radio_nr = -1; static struct pnp_dev *dev = NULL; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) static struct mutex lock; -#else -static struct semaphore lock; -#endif /* freq is in 1/16 kHz to internal number, hw precision is 50 kHz */ /* It is only useful to give freq in intervall of 800 (=0.05Mhz), diff --git a/linux/drivers/media/radio/radio-sf16fmr2.c b/linux/drivers/media/radio/radio-sf16fmr2.c index 72f302009..2cb47a0c8 100644 --- a/linux/drivers/media/radio/radio-sf16fmr2.c +++ b/linux/drivers/media/radio/radio-sf16fmr2.c @@ -23,13 +23,9 @@ #include "compat.h" #include <linux/videodev2.h> /* kernel radio structs */ #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> static struct mutex lock; -#else -static struct semaphore lock; -#endif #include <linux/version.h> /* for KERNEL_VERSION MACRO */ #define RADIO_VERSION KERNEL_VERSION(0,0,2) diff --git a/linux/drivers/media/radio/radio-si470x.c b/linux/drivers/media/radio/radio-si470x.c index b41eddd4f..55c1a9b7b 100644 --- a/linux/drivers/media/radio/radio-si470x.c +++ b/linux/drivers/media/radio/radio-si470x.c @@ -132,9 +132,7 @@ #include <linux/version.h> #include "compat.h" #include <linux/videodev2.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) #include <linux/mutex.h> -#endif #include <media/v4l2-common.h> #include <media/rds.h> #include <asm/unaligned.h> @@ -463,11 +461,7 @@ struct si470x_device { struct delayed_work work; #endif wait_queue_head_t read_queue; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) struct mutex lock; /* buffer locking */ -#else - struct semaphore lock; /* buffer locking */ -#endif unsigned char *buffer; /* size is always multiple of three */ unsigned int buf_size; unsigned int rd_index; diff --git a/linux/drivers/media/radio/radio-typhoon.c b/linux/drivers/media/radio/radio-typhoon.c index 5db38526e..9b69eaf5a 100644 --- a/linux/drivers/media/radio/radio-typhoon.c +++ b/linux/drivers/media/radio/radio-typhoon.c @@ -85,11 +85,7 @@ struct typhoon_device { int muted; unsigned long curfreq; unsigned long mutefreq; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; static void typhoon_setvol_generic(struct typhoon_device *dev, int vol); diff --git a/linux/drivers/media/radio/radio-zoltrix.c b/linux/drivers/media/radio/radio-zoltrix.c index 68f30a456..197379ae6 100644 --- a/linux/drivers/media/radio/radio-zoltrix.c +++ b/linux/drivers/media/radio/radio-zoltrix.c @@ -74,11 +74,7 @@ struct zol_device { unsigned long curfreq; int muted; unsigned int stereo; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; static int zol_setvol(struct zol_device *dev, int vol) diff --git a/linux/drivers/media/video/arv.c b/linux/drivers/media/video/arv.c index 88507ed9b..8d8d339b5 100644 --- a/linux/drivers/media/video/arv.c +++ b/linux/drivers/media/video/arv.c @@ -30,9 +30,7 @@ #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) #include <linux/mutex.h> -#endif #include <asm/uaccess.h> #include <asm/m32r.h> @@ -118,11 +116,7 @@ struct ar_device { int width, height; int frame_bytes, line_bytes; wait_queue_head_t wait; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) struct mutex lock; -#else - struct semaphore lock; -#endif }; static int video_nr = -1; /* video device number (first free) */ diff --git a/linux/drivers/media/video/au0828/au0828-core.c b/linux/drivers/media/video/au0828/au0828-core.c index 5642058ae..123422f82 100644 --- a/linux/drivers/media/video/au0828/au0828-core.c +++ b/linux/drivers/media/video/au0828/au0828-core.c @@ -23,9 +23,7 @@ #include <linux/videodev2.h> #include <media/v4l2-common.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) #include <linux/mutex.h> -#endif #include "au0828.h" @@ -218,9 +216,6 @@ static struct usb_driver au0828_usb_driver = { .probe = au0828_usb_probe, .disconnect = au0828_usb_disconnect, .id_table = au0828_usb_id_table, -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) - .owner = THIS_MODULE, -#endif }; static int __init au0828_init(void) diff --git a/linux/drivers/media/video/au0828/au0828.h b/linux/drivers/media/video/au0828/au0828.h index b00d8cda5..7beb57179 100644 --- a/linux/drivers/media/video/au0828/au0828.h +++ b/linux/drivers/media/video/au0828/au0828.h @@ -44,11 +44,7 @@ struct au0828_board { }; struct au0828_dvb { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex lock; -#else - struct semaphore lock; -#endif struct dvb_adapter adapter; struct dvb_frontend *frontend; struct dvb_demux demux; @@ -60,11 +56,7 @@ struct au0828_dvb { }; struct au0828_dev { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex mutex; -#else - struct semaphore mutex; -#endif struct usb_device *usbdev; int board; u8 ctrlmsg[64]; diff --git a/linux/drivers/media/video/bt8xx/bt832.c b/linux/drivers/media/video/bt8xx/bt832.c index e860f7725..b677916bf 100644 --- a/linux/drivers/media/video/bt8xx/bt832.c +++ b/linux/drivers/media/video/bt8xx/bt832.c @@ -250,17 +250,9 @@ bt832_command(struct i2c_client *client, unsigned int cmd, void *arg) /* ----------------------------------------------------------------------- */ static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .name = "bt832", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "bt832", }, -#endif .id = 0, /* FIXME */ .attach_adapter = bt832_probe, .detach_client = bt832_detach, @@ -269,9 +261,6 @@ static struct i2c_driver driver = { static struct i2c_client client_template = { .name = "bt832", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_CLIENT_ALLOW_USE, -#endif .driver = &driver, }; diff --git a/linux/drivers/media/video/bt8xx/bttv-cards.c b/linux/drivers/media/video/bt8xx/bttv-cards.c index 4d283be22..df2dfd2ba 100644 --- a/linux/drivers/media/video/bt8xx/bttv-cards.c +++ b/linux/drivers/media/video/bt8xx/bttv-cards.c @@ -4868,13 +4868,8 @@ void __init bttv_check_chipset(void) } if (UNSET != latency) printk(KERN_INFO "bttv: pci latency fixup [%d]\n",latency); -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,13) while ((dev = pci_get_device(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82441, dev))) { -#else - while ((dev = pci_find_device(PCI_VENDOR_ID_INTEL, - PCI_DEVICE_ID_INTEL_82441, dev))) { -#endif unsigned char b; pci_read_config_byte(dev, 0x53, &b); if (bttv_debug) diff --git a/linux/drivers/media/video/bt8xx/bttv-driver.c b/linux/drivers/media/video/bt8xx/bttv-driver.c index 36efd08f8..9877a7124 100644 --- a/linux/drivers/media/video/bt8xx/bttv-driver.c +++ b/linux/drivers/media/video/bt8xx/bttv-driver.c @@ -4545,11 +4545,7 @@ static int bttv_suspend(struct pci_dev *pci_dev, pm_message_t state) struct bttv_buffer_set idle; unsigned long flags; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,13) dprintk("bttv%d: suspend %d\n", btv->c.nr, state.event); -#else - dprintk("bttv%d: suspend %d\n", btv->c.nr, state); -#endif /* stop dma + irqs */ spin_lock_irqsave(&btv->s_lock,flags); diff --git a/linux/drivers/media/video/bt8xx/bttv-gpio.c b/linux/drivers/media/video/bt8xx/bttv-gpio.c index 9b161b8dd..dce6dae57 100644 --- a/linux/drivers/media/video/bt8xx/bttv-gpio.c +++ b/linux/drivers/media/video/bt8xx/bttv-gpio.c @@ -47,7 +47,6 @@ static int bttv_sub_bus_match(struct device *dev, struct device_driver *drv) return 0; } -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) static int bttv_sub_probe(struct device *dev) { struct bttv_sub_device *sdev = to_bttv_sub_dev(dev); @@ -66,17 +65,11 @@ static int bttv_sub_remove(struct device *dev) return 0; } -#endif struct bus_type bttv_sub_bus_type = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .name = "bttv-sub", - .match = &bttv_sub_bus_match, -#else .name = "bttv-sub", .match = &bttv_sub_bus_match, .probe = bttv_sub_probe, .remove = bttv_sub_remove, -#endif }; static void release_sub_device(struct device *dev) diff --git a/linux/drivers/media/video/bt8xx/bttv-i2c.c b/linux/drivers/media/video/bt8xx/bttv-i2c.c index 4f48dfb26..bcd2cd240 100644 --- a/linux/drivers/media/video/bt8xx/bttv-i2c.c +++ b/linux/drivers/media/video/bt8xx/bttv-i2c.c @@ -277,11 +277,7 @@ static int attach_inform(struct i2c_client *client) if (bttv_debug) printk(KERN_DEBUG "bttv%d: %s i2c attach [addr=0x%x,client=%s]\n", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - btv->c.nr, client->driver->name, client->addr, -#else btv->c.nr, client->driver->driver.name, client->addr, -#endif client->name); if (!client->driver->command) return 0; diff --git a/linux/drivers/media/video/bt8xx/bttv-input.c b/linux/drivers/media/video/bt8xx/bttv-input.c index ada104826..09dc5ac77 100644 --- a/linux/drivers/media/video/bt8xx/bttv-input.c +++ b/linux/drivers/media/video/bt8xx/bttv-input.c @@ -326,11 +326,7 @@ int bttv_input_init(struct bttv *btv) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &btv->c.pci->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &btv->c.pci->dev; -#else - input_dev->dev = &btv->c.pci->dev; -#endif #endif btv->remote = ir; diff --git a/linux/drivers/media/video/bt8xx/bttv.h b/linux/drivers/media/video/bt8xx/bttv.h index dab61e62e..3441c0226 100644 --- a/linux/drivers/media/video/bt8xx/bttv.h +++ b/linux/drivers/media/video/bt8xx/bttv.h @@ -312,10 +312,8 @@ struct bttv_sub_device { struct bttv_sub_driver { struct device_driver drv; char wanted[BUS_ID_SIZE]; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) int (*probe)(struct bttv_sub_device *sub); void (*remove)(struct bttv_sub_device *sub); -#endif }; #define to_bttv_sub_drv(x) container_of((x), struct bttv_sub_driver, drv) diff --git a/linux/drivers/media/video/bt8xx/bttvp.h b/linux/drivers/media/video/bt8xx/bttvp.h index c3d1703ac..63d1d4451 100644 --- a/linux/drivers/media/video/bt8xx/bttvp.h +++ b/linux/drivers/media/video/bt8xx/bttvp.h @@ -35,9 +35,7 @@ #include <linux/videodev.h> #include <linux/pci.h> #include <linux/input.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/scatterlist.h> #include <asm/io.h> #include "compat.h" @@ -366,11 +364,7 @@ struct bttv { /* locking */ spinlock_t s_lock; -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - struct semaphore lock; -#else struct mutex lock; -#endif int resources; #ifdef VIDIOC_G_PRIORITY struct v4l2_prio_state prio; diff --git a/linux/drivers/media/video/bw-qcam.c b/linux/drivers/media/video/bw-qcam.c index 787da47f5..e587fb332 100644 --- a/linux/drivers/media/video/bw-qcam.c +++ b/linux/drivers/media/video/bw-qcam.c @@ -75,9 +75,7 @@ OTHER DEALINGS IN THE SOFTWARE. #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <asm/uaccess.h> #include "bw-qcam.h" diff --git a/linux/drivers/media/video/bw-qcam.h b/linux/drivers/media/video/bw-qcam.h index f023c465f..6701dafbc 100644 --- a/linux/drivers/media/video/bw-qcam.h +++ b/linux/drivers/media/video/bw-qcam.h @@ -55,11 +55,7 @@ struct qcam_device { struct video_device vdev; struct pardevice *pdev; struct parport *pport; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif int width, height; int bpp; int mode; diff --git a/linux/drivers/media/video/c-qcam.c b/linux/drivers/media/video/c-qcam.c index a5f5b8a4a..0755931e7 100644 --- a/linux/drivers/media/video/c-qcam.c +++ b/linux/drivers/media/video/c-qcam.c @@ -36,9 +36,7 @@ #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/jiffies.h> #include <asm/uaccess.h> @@ -53,11 +51,7 @@ struct qcam_device { int contrast, brightness, whitebal; int top, left; unsigned int bidirectional; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; /* cameras maximum */ diff --git a/linux/drivers/media/video/cpia.c b/linux/drivers/media/video/cpia.c index 5d043643a..d5941cc15 100644 --- a/linux/drivers/media/video/cpia.c +++ b/linux/drivers/media/video/cpia.c @@ -37,9 +37,7 @@ #include <linux/pagemap.h> #include <linux/delay.h> #include <asm/io.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #ifdef CONFIG_KMOD #include <linux/kmod.h> diff --git a/linux/drivers/media/video/cpia.h b/linux/drivers/media/video/cpia.h index d579b5edb..f90857a39 100644 --- a/linux/drivers/media/video/cpia.h +++ b/linux/drivers/media/video/cpia.h @@ -47,9 +47,7 @@ #include <linux/videodev.h> #include <media/v4l2-common.h> #include <linux/list.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "compat.h" struct cpia_camera_ops @@ -250,11 +248,7 @@ enum v4l_camstates { struct cam_data { struct list_head cam_data_list; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex busy_lock; /* guard against SMP multithreading */ -#else - struct semaphore busy_lock; /* guard against SMP multithreading */ -#endif struct cpia_camera_ops *ops; /* lowlevel driver operations */ void *lowlevel_data; /* private data for lowlevel driver */ u8 *raw_image; /* buffer for raw image data */ @@ -269,11 +263,7 @@ struct cam_data { u8 mainsFreq; /* for flicker control */ /* proc interface */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex param_lock; /* params lock for this camera */ -#else - struct semaphore param_lock; /* params lock for this camera */ -#endif struct cam_params params; /* camera settings */ struct proc_dir_entry *proc_entry; /* /proc/cpia/videoX */ diff --git a/linux/drivers/media/video/cpia2/cpia2.h b/linux/drivers/media/video/cpia2/cpia2.h index 24c47092e..bbb0e221f 100644 --- a/linux/drivers/media/video/cpia2/cpia2.h +++ b/linux/drivers/media/video/cpia2/cpia2.h @@ -379,11 +379,7 @@ struct cpia2_fh { struct camera_data { /* locks */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex busy_lock; /* guard against SMP multithreading */ -#else - struct semaphore busy_lock; -#endif struct v4l2_prio_state prio; /* camera status */ diff --git a/linux/drivers/media/video/cx18/cx18-driver.h b/linux/drivers/media/video/cx18/cx18-driver.h index e4f1accd2..b78d0e38d 100644 --- a/linux/drivers/media/video/cx18/cx18-driver.h +++ b/linux/drivers/media/video/cx18/cx18-driver.h @@ -41,9 +41,7 @@ #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 <linux/dvb/video.h> #include <linux/dvb/audio.h> @@ -232,13 +230,7 @@ struct cx18_dvb { struct dvb_net dvbnet; int enabled; int feeding; - -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex feedlock; -#else - struct semaphore feedlock; -#endif - }; struct cx18; /* forward reference */ @@ -383,11 +375,7 @@ struct cx18 { /* Digitizer type */ int digitizer; /* 0x00EF = saa7114 0x00FO = saa7115 0x0106 = mic */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex serialize_lock; /* mutex used to serialize open/close/start/stop/ioctl operations */ -#else - struct semaphore serialize_lock;/* mutex used to serialize open/close/start/stop/ioctl operations */ -#endif struct cx18_options options; /* User options */ int stream_buf_size[CX18_MAX_STREAMS]; /* Stream buffer size */ struct cx18_stream streams[CX18_MAX_STREAMS]; /* Stream data */ @@ -433,11 +421,7 @@ struct cx18 { struct i2c_algo_bit_data i2c_algo[2]; struct cx18_i2c_algo_callback_data i2c_algo_cb_data[2]; struct i2c_client i2c_client[2]; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex i2c_bus_lock[2]; -#else - struct semaphore i2c_bus_lock[2]; -#endif struct i2c_client *i2c_clients[I2C_CLIENTS_MAX]; /* gpio */ diff --git a/linux/drivers/media/video/cx23885/cx23885.h b/linux/drivers/media/video/cx23885/cx23885.h index 11ad18af6..9a0b4bf3a 100644 --- a/linux/drivers/media/video/cx23885/cx23885.h +++ b/linux/drivers/media/video/cx23885/cx23885.h @@ -36,9 +36,7 @@ #include "media/cx2341x.h" #include <linux/version.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #define CX23885_VERSION_CODE KERNEL_VERSION(0,0,1) @@ -286,11 +284,7 @@ struct cx23885_dev { struct cx23885_i2c i2c_bus[3]; int nr; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif /* board details */ unsigned int board; diff --git a/linux/drivers/media/video/cx88/cx88-core.c b/linux/drivers/media/video/cx88/cx88-core.c index 6efb1c61a..a63915bdf 100644 --- a/linux/drivers/media/video/cx88/cx88-core.c +++ b/linux/drivers/media/video/cx88/cx88-core.c @@ -37,9 +37,7 @@ #include <linux/delay.h> #include "compat.h" #include <linux/videodev2.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "cx88.h" #include <media/v4l2-common.h> diff --git a/linux/drivers/media/video/cx88/cx88-i2c.c b/linux/drivers/media/video/cx88/cx88-i2c.c index df615f19a..d7406a994 100644 --- a/linux/drivers/media/video/cx88/cx88-i2c.c +++ b/linux/drivers/media/video/cx88/cx88-i2c.c @@ -101,14 +101,8 @@ static int attach_inform(struct i2c_client *client) { struct cx88_core *core = i2c_get_adapdata(client->adapter); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - dprintk(1, "%s i2c attach [addr=0x%x,client=%s]\n", - client->driver->name, client->addr, client->name); -#else dprintk(1, "%s i2c attach [addr=0x%x,client=%s]\n", client->driver->driver.name, client->addr, client->name); -#endif - return 0; } diff --git a/linux/drivers/media/video/cx88/cx88-input.c b/linux/drivers/media/video/cx88/cx88-input.c index 4796e3ba1..7d174382e 100644 --- a/linux/drivers/media/video/cx88/cx88-input.c +++ b/linux/drivers/media/video/cx88/cx88-input.c @@ -362,11 +362,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &pci->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &pci->dev; -#else - input_dev->dev = &pci->dev; -#endif #endif /* record handles to ourself */ ir->core = core; diff --git a/linux/drivers/media/video/cx88/cx88.h b/linux/drivers/media/video/cx88/cx88.h index 161b3cc13..3e4b80617 100644 --- a/linux/drivers/media/video/cx88/cx88.h +++ b/linux/drivers/media/video/cx88/cx88.h @@ -41,9 +41,7 @@ #include "tuner-xc2028.h" #include <linux/version.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #define CX88_VERSION_CODE KERNEL_VERSION(0,0,6) #define UNSET (-1U) @@ -345,11 +343,7 @@ struct cx88_core { /* IR remote control state */ struct cx88_IR *ir; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif /* various v4l controls */ u32 freq; diff --git a/linux/drivers/media/video/dabusb.c b/linux/drivers/media/video/dabusb.c index 7f69d4043..4efe3f839 100644 --- a/linux/drivers/media/video/dabusb.c +++ b/linux/drivers/media/video/dabusb.c @@ -38,9 +38,7 @@ #include <linux/delay.h> #include <linux/usb.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "dabusb.h" #include "dabfirmware.h" diff --git a/linux/drivers/media/video/dabusb.h b/linux/drivers/media/video/dabusb.h index 761461910..00eb34c86 100644 --- a/linux/drivers/media/video/dabusb.h +++ b/linux/drivers/media/video/dabusb.h @@ -18,11 +18,7 @@ typedef enum { _stopped=0, _started } driver_state_t; typedef struct { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex mutex; -#else - struct semaphore mutex; -#endif struct usb_device *usbdev; wait_queue_head_t wait; wait_queue_head_t remove_ok; diff --git a/linux/drivers/media/video/em28xx/em28xx-dvb.c b/linux/drivers/media/video/em28xx/em28xx-dvb.c index b8a5c61ce..adf2a6552 100644 --- a/linux/drivers/media/video/em28xx/em28xx-dvb.c +++ b/linux/drivers/media/video/em28xx/em28xx-dvb.c @@ -55,11 +55,7 @@ struct em28xx_dvb { struct dvb_frontend *frontend; /* feed count management */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex lock; -#else - struct semaphore lock; -#endif int nfeeds; /* general boilerplate stuff */ diff --git a/linux/drivers/media/video/em28xx/em28xx-i2c.c b/linux/drivers/media/video/em28xx/em28xx-i2c.c index 4d6f650da..97853384c 100644 --- a/linux/drivers/media/video/em28xx/em28xx-i2c.c +++ b/linux/drivers/media/video/em28xx/em28xx-i2c.c @@ -519,9 +519,6 @@ static struct i2c_adapter em28xx_adap_template = { static struct i2c_client em28xx_client_template = { .name = "em28xx internal", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) - .flags = I2C_CLIENT_ALLOW_USE, -#endif }; /* ----------------------------------------------------------- */ diff --git a/linux/drivers/media/video/em28xx/em28xx-input.c b/linux/drivers/media/video/em28xx/em28xx-input.c index e83e3bebd..8d21eaad9 100644 --- a/linux/drivers/media/video/em28xx/em28xx-input.c +++ b/linux/drivers/media/video/em28xx/em28xx-input.c @@ -205,11 +205,7 @@ void em28xx_register_snapshot_button(struct em28xx *dev) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 22) input_dev->dev.parent = &dev->udev->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 15) input_dev->cdev.dev = &dev->udev->dev; -#else - input_dev->dev = &dev->udev->dev; -#endif #endif err = input_register_device(input_dev); diff --git a/linux/drivers/media/video/em28xx/em28xx-video.c b/linux/drivers/media/video/em28xx/em28xx-video.c index 5929d0860..4f7a51e66 100644 --- a/linux/drivers/media/video/em28xx/em28xx-video.c +++ b/linux/drivers/media/video/em28xx/em28xx-video.c @@ -34,9 +34,7 @@ #include <linux/i2c.h> #include <linux/version.h> #include <linux/mm.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) #include <linux/mutex.h> -#endif #include "em28xx.h" #include <media/v4l2-common.h> @@ -2341,9 +2339,6 @@ static void em28xx_usb_disconnect(struct usb_interface *interface) } static struct usb_driver em28xx_usb_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) - .owner = THIS_MODULE, -#endif .name = "em28xx", .probe = em28xx_usb_probe, .disconnect = em28xx_usb_disconnect, diff --git a/linux/drivers/media/video/em28xx/em28xx.h b/linux/drivers/media/video/em28xx/em28xx.h index 18b3bc134..6db96db0f 100644 --- a/linux/drivers/media/video/em28xx/em28xx.h +++ b/linux/drivers/media/video/em28xx/em28xx.h @@ -30,9 +30,7 @@ #include <media/videobuf-vmalloc.h> #include <linux/i2c.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) #include <linux/mutex.h> -#endif #include <media/ir-kbd-i2c.h> #if defined(CONFIG_VIDEO_EM28XX_DVB) || defined(CONFIG_VIDEO_EM28XX_DVB_MODULE) #include <media/videobuf-dvb.h> @@ -395,11 +393,7 @@ struct em28xx { struct work_struct request_module_wk; /* locks */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 15) struct mutex lock; -#else - struct semaphore lock, fileop_lock; -#endif /* spinlock_t queue_lock; */ struct list_head inqueue, outqueue; wait_queue_head_t open, wait_frame, wait_stream; diff --git a/linux/drivers/media/video/et61x251/et61x251.h b/linux/drivers/media/video/et61x251/et61x251.h index 64ff5de0d..d39eabc9d 100644 --- a/linux/drivers/media/video/et61x251/et61x251.h +++ b/linux/drivers/media/video/et61x251/et61x251.h @@ -34,9 +34,7 @@ #include <linux/types.h> #include <linux/param.h> #include <linux/rwsem.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/stddef.h> #include <linux/string.h> #include <linux/kref.h> @@ -167,11 +165,7 @@ struct et61x251_device { u8 users; struct completion probe; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex open_mutex, fileop_mutex; -#else - struct semaphore open_mutex, fileop_mutex; -#endif spinlock_t queue_lock; wait_queue_head_t wait_open, wait_frame, wait_stream; }; diff --git a/linux/drivers/media/video/ir-kbd-i2c.c b/linux/drivers/media/video/ir-kbd-i2c.c index 85806fe10..fc668f5b5 100644 --- a/linux/drivers/media/video/ir-kbd-i2c.c +++ b/linux/drivers/media/video/ir-kbd-i2c.c @@ -328,15 +328,9 @@ static int ir_detach(struct i2c_client *client); static int ir_probe(struct i2c_adapter *adap); static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "ir-kbd-i2c", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "ir-kbd-i2c", }, -#endif .id = I2C_DRIVERID_INFRARED, .attach_adapter = ir_probe, .detach_client = ir_detach, diff --git a/linux/drivers/media/video/ivtv/ivtv-driver.h b/linux/drivers/media/video/ivtv/ivtv-driver.h index 5134d8a09..7bae21e5b 100644 --- a/linux/drivers/media/video/ivtv/ivtv-driver.h +++ b/linux/drivers/media/video/ivtv/ivtv-driver.h @@ -53,9 +53,7 @@ #include <linux/pagemap.h> #include <linux/scatterlist.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> @@ -274,11 +272,7 @@ struct ivtv_sg_host_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]; /* Needed when dealing with highmem userspace buffers */ @@ -640,12 +634,7 @@ struct ivtv { /* Locking */ spinlock_t lock; /* lock access to this struct */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex serialize_lock; /* mutex used to serialize open/close/start/stop/ioctl operations */ -#else - struct semaphore serialize_lock;/* mutex used to serialize open/close/start/stop/ioctl operations */ -#endif - /* Streams */ int stream_buf_size[IVTV_MAX_STREAMS]; /* stream buffer size */ @@ -686,11 +675,7 @@ struct ivtv { struct i2c_client i2c_client; struct i2c_client *i2c_clients[I2C_CLIENTS_MAX];/* pointers to all I2C clients */ int i2c_state; /* i2c bit state */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex i2c_bus_lock; /* lock i2c bus */ -#else - struct semaphore i2c_bus_lock; /* lock i2c bus */ -#endif /* Program Index information */ diff --git a/linux/drivers/media/video/meye.h b/linux/drivers/media/video/meye.h index c5c8d0a0a..4c0c031d3 100644 --- a/linux/drivers/media/video/meye.h +++ b/linux/drivers/media/video/meye.h @@ -263,9 +263,7 @@ /* private API definitions */ #include <linux/meye.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif /* Enable jpg software correction */ @@ -308,11 +306,7 @@ struct meye { /* list of buffers */ struct meye_grab_buffer grab_buffer[MEYE_MAX_BUFNBRS]; int vma_use_count[MEYE_MAX_BUFNBRS]; /* mmap count */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; /* mutex for open/mmap... */ -#else - struct semaphore lock; /* mutex for open/mmap... */ -#endif struct kfifo *grabq; /* queue for buffers to be grabbed */ spinlock_t grabq_lock; /* lock protecting the queue */ struct kfifo *doneq; /* queue for grabbed buffers */ diff --git a/linux/drivers/media/video/ov511.h b/linux/drivers/media/video/ov511.h index e797d3c9c..62f0cb4d7 100644 --- a/linux/drivers/media/video/ov511.h +++ b/linux/drivers/media/video/ov511.h @@ -6,12 +6,7 @@ #include <linux/videodev.h> #include <media/v4l2-common.h> #include <linux/usb.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#else -/* Having a version check for each mutex defined is annoying */ -#define mutex semaphore -#endif #define OV511_DEBUG /* Turn on debug messages */ diff --git a/linux/drivers/media/video/planb.c b/linux/drivers/media/video/planb.c index 282c9dd27..358dc2996 100644 --- a/linux/drivers/media/video/planb.c +++ b/linux/drivers/media/video/planb.c @@ -50,9 +50,7 @@ #include <asm/pgtable.h> #include <asm/page.h> #include <asm/irq.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) #include <linux/mutex.h> -#endif #include "planb.h" #include "saa7196.h" diff --git a/linux/drivers/media/video/planb.h b/linux/drivers/media/video/planb.h index 944e4960a..e21b5735c 100644 --- a/linux/drivers/media/video/planb.h +++ b/linux/drivers/media/video/planb.h @@ -174,11 +174,7 @@ struct planb { int user; unsigned int tab_size; int maxlines; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) struct mutex lock; -#else - struct semaphore lock; -#endif unsigned int irq; /* interrupt number */ volatile unsigned int intr_mask; struct pci_dev *dev; /* Our PCI device */ diff --git a/linux/drivers/media/video/pms.c b/linux/drivers/media/video/pms.c index c10296c07..bf9858257 100644 --- a/linux/drivers/media/video/pms.c +++ b/linux/drivers/media/video/pms.c @@ -31,9 +31,7 @@ #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <asm/uaccess.h> @@ -49,11 +47,7 @@ struct pms_device struct video_picture picture; int height; int width; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; struct i2c_info diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-context.h b/linux/drivers/media/video/pvrusb2/pvrusb2-context.h index c7cbc28a8..61801291c 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-context.h +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-context.h @@ -19,11 +19,7 @@ #ifndef __PVRUSB2_BASE_H #define __PVRUSB2_BASE_H -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include <linux/usb.h> #include <linux/workqueue.h> @@ -49,11 +45,7 @@ struct pvr2_context { struct pvr2_context *notify_prev; struct pvr2_hdw *hdw; struct pvr2_context_stream video_stream; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex mutex; -#else - struct semaphore mutex; -#endif int notify_flag; int initialized_flag; int disconnect_flag; diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-ctrl.c b/linux/drivers/media/video/pvrusb2/pvrusb2-ctrl.c index 5c8942e93..3b982d963 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-ctrl.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-ctrl.c @@ -23,11 +23,7 @@ #include "compat.h" #include <linux/errno.h> #include <linux/string.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif static int pvr2_ctrl_range_check(struct pvr2_ctrl *cptr,int val) diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-dvb.h b/linux/drivers/media/video/pvrusb2/pvrusb2-dvb.h index c13ecfb13..884ff916a 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-dvb.h +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-dvb.h @@ -23,11 +23,7 @@ struct pvr2_dvb_adapter { int max_feed_count; struct task_struct *thread; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif unsigned int stream_run:1; diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h b/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h index f75dd1613..657f86159 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h @@ -35,11 +35,7 @@ #include <linux/videodev2.h> #include <linux/i2c.h> #include <linux/workqueue.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include "pvrusb2-hdw.h" #include "pvrusb2-io.h" #include <media/cx2341x.h> @@ -195,11 +191,7 @@ struct pvr2_hdw { struct pvr2_stream *vid_stream; /* Mutex for all hardware state control */ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex big_lock_mutex; -#else - struct semaphore big_lock_mutex; -#endif int big_lock_held; /* For debugging */ char name[32]; @@ -215,22 +207,14 @@ struct pvr2_hdw { unsigned long i2c_stale_mask; /* Pending broadcast change bits */ unsigned long i2c_active_mask; /* All change bits currently in use */ struct list_head i2c_clients; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex i2c_list_lock; -#else - struct semaphore i2c_list_lock; -#endif /* Frequency table */ unsigned int freqTable[FREQTABLE_SIZE]; unsigned int freqProgSlot; /* Stuff for handling low level control interaction with device */ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex ctl_lock_mutex; -#else - struct semaphore ctl_lock_mutex; -#endif int ctl_lock_held; /* For debugging */ struct urb *ctl_write_urb; struct urb *ctl_read_urb; diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c b/linux/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c index 797017066..ef741d1fc 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c @@ -606,17 +606,9 @@ static int pvr2_i2c_core_singleton(struct i2c_client *cp, if (!cp) return -EINVAL; if (!(cp->driver)) return -EINVAL; if (!(cp->driver->command)) return -EINVAL; -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) - if (!try_module_get(cp->driver->owner)) return -EAGAIN; -#else if (!try_module_get(cp->driver->driver.owner)) return -EAGAIN; -#endif stat = cp->driver->command(cp,cmd,arg); -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) - module_put(cp->driver->owner); -#else module_put(cp->driver->driver.owner); -#endif return stat; } diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-io.c b/linux/drivers/media/video/pvrusb2/pvrusb2-io.c index bf7bd5906..2bc69812d 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-io.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-io.c @@ -23,11 +23,7 @@ #include <linux/errno.h> #include <linux/string.h> #include <linux/slab.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include "compat.h" static const char *pvr2_buffer_state_decode(enum pvr2_buffer_state); @@ -91,11 +87,7 @@ struct pvr2_stream { int endpoint; /* Overhead for mutex enforcement */ spinlock_t list_lock; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex mutex; -#else - struct semaphore mutex; -#endif /* Tracking state for tolerating errors */ unsigned int fail_count; unsigned int fail_tolerance; diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-ioread.c b/linux/drivers/media/video/pvrusb2/pvrusb2-ioread.c index fb3ad639f..fa599a1bf 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-ioread.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-ioread.c @@ -23,11 +23,7 @@ #include <linux/errno.h> #include <linux/string.h> #include <linux/slab.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include <asm/uaccess.h> #include "compat.h" @@ -51,11 +47,7 @@ struct pvr2_ioread { char *c_data_ptr; unsigned int c_data_len; unsigned int c_data_offs; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex mutex; -#else - struct semaphore mutex; -#endif }; static int pvr2_ioread_init(struct pvr2_ioread *cp) diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-main.c b/linux/drivers/media/video/pvrusb2/pvrusb2-main.c index ff85b381c..9a3ad0905 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-main.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-main.c @@ -107,9 +107,6 @@ static void pvr_disconnect(struct usb_interface *intf) } static struct usb_driver pvr_driver = { -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) - .owner = THIS_MODULE, -#endif .name = "pvrusb2", .id_table = pvr2_device_table, .probe = pvr_probe, diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-sysfs.c b/linux/drivers/media/video/pvrusb2/pvrusb2-sysfs.c index f6ace8abe..90cb36435 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-sysfs.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-sysfs.c @@ -776,9 +776,7 @@ struct pvr2_sysfs_class *pvr2_sysfs_class_create(void) #else clp->class.dev_release = pvr2_sysfs_release; #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) - clp->class.hotplug = pvr2_sysfs_hotplug; -#elif LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19) +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19) clp->class.uevent = pvr2_sysfs_hotplug; #endif if (class_register(&clp->class)) { diff --git a/linux/drivers/media/video/pwc/pwc.h b/linux/drivers/media/video/pwc/pwc.h index c5fe0e13d..d01548d2c 100644 --- a/linux/drivers/media/video/pwc/pwc.h +++ b/linux/drivers/media/video/pwc/pwc.h @@ -31,11 +31,7 @@ #include <linux/wait.h> #include <linux/smp_lock.h> #include <linux/version.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include <asm/errno.h> #include "compat.h" #include <linux/videodev.h> @@ -250,11 +246,7 @@ struct pwc_device int image_read_pos; /* In case we read data in pieces, keep track of were we are in the imagebuffer */ int image_used[MAX_IMAGES]; /* For MCAPTURE and SYNC */ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex modlock; /* to prevent races in video_open(), etc */ -#else - struct semaphore modlock; /* to prevent races in video_open(), etc */ -#endif spinlock_t ptrlock; /* for manipulating the buffer pointers */ /*** motorized pan/tilt feature */ diff --git a/linux/drivers/media/video/saa5246a.c b/linux/drivers/media/video/saa5246a.c index 2ea5d70a9..59b95caef 100644 --- a/linux/drivers/media/video/saa5246a.c +++ b/linux/drivers/media/video/saa5246a.c @@ -47,9 +47,7 @@ #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "saa5246a.h" @@ -62,11 +60,7 @@ struct saa5246a_device u8 pgbuf[NUM_DAUS][VTX_VIRTUALSIZE]; int is_searching[NUM_DAUS]; struct i2c_client *client; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; static struct video_device saa_template; /* Declared near bottom */ diff --git a/linux/drivers/media/video/saa5249.c b/linux/drivers/media/video/saa5249.c index 4443a023c..3bc0f0604 100644 --- a/linux/drivers/media/video/saa5249.c +++ b/linux/drivers/media/video/saa5249.c @@ -58,9 +58,7 @@ #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <asm/io.h> @@ -111,11 +109,7 @@ struct saa5249_device int disp_mode; int virtual_mode; struct i2c_client *client; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; diff --git a/linux/drivers/media/video/saa6588.c b/linux/drivers/media/video/saa6588.c index 5efa5ab66..ab41d9526 100644 --- a/linux/drivers/media/video/saa6588.c +++ b/linux/drivers/media/video/saa6588.c @@ -500,15 +500,9 @@ static int saa6588_command(struct i2c_client *client, unsigned int cmd, /* ----------------------------------------------------------------------- */ static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "saa6588", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "saa6588", }, -#endif .id = -1, /* FIXME */ .attach_adapter = saa6588_probe, .detach_client = saa6588_detach, @@ -517,9 +511,6 @@ static struct i2c_driver driver = { static struct i2c_client client_template = { .name = "saa6588", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_CLIENT_ALLOW_USE, -#endif .driver = &driver, }; diff --git a/linux/drivers/media/video/saa7134/saa6752hs.c b/linux/drivers/media/video/saa7134/saa6752hs.c index 0143c8b28..c5c19a2e3 100644 --- a/linux/drivers/media/video/saa7134/saa6752hs.c +++ b/linux/drivers/media/video/saa7134/saa6752hs.c @@ -797,15 +797,9 @@ saa6752hs_command(struct i2c_client *client, unsigned int cmd, void *arg) /* ----------------------------------------------------------------------- */ static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "saa6752hs", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "saa6752hs", }, -#endif .id = I2C_DRIVERID_SAA6752HS, .attach_adapter = saa6752hs_probe, .detach_client = saa6752hs_detach, @@ -815,9 +809,6 @@ static struct i2c_driver driver = { static struct i2c_client client_template = { .name = "saa6752hs", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_CLIENT_ALLOW_USE, -#endif .driver = &driver, }; diff --git a/linux/drivers/media/video/saa7134/saa7134-core.c b/linux/drivers/media/video/saa7134/saa7134-core.c index 511941bca..8f3d280af 100644 --- a/linux/drivers/media/video/saa7134/saa7134-core.c +++ b/linux/drivers/media/video/saa7134/saa7134-core.c @@ -29,9 +29,7 @@ #include <linux/sound.h> #include <linux/interrupt.h> #include <linux/delay.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/dma-mapping.h> #include <linux/pm.h> diff --git a/linux/drivers/media/video/saa7134/saa7134-i2c.c b/linux/drivers/media/video/saa7134/saa7134-i2c.c index 610e506b5..bdec276e0 100644 --- a/linux/drivers/media/video/saa7134/saa7134-i2c.c +++ b/linux/drivers/media/video/saa7134/saa7134-i2c.c @@ -331,11 +331,7 @@ static int attach_inform(struct i2c_client *client) struct saa7134_dev *dev = client->adapter->algo_data; d1printk( "%s i2c attach [addr=0x%x,client=%s]\n", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - client->driver->name, client->addr, client->name); -#else client->driver->driver.name, client->addr, client->name); -#endif if (client->addr == 0x20 && client->driver && client->driver->command) dev->mpeg_i2c_client = client; @@ -349,11 +345,7 @@ static int attach_inform(struct i2c_client *client) { struct IR_i2c *ir = i2c_get_clientdata(client); d1printk("%s i2c IR detected (%s).\n", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - client->driver->name,ir->phys); -#else client->driver->driver.name, ir->phys); -#endif saa7134_set_i2c_ir(dev,ir); break; } diff --git a/linux/drivers/media/video/saa7134/saa7134-input.c b/linux/drivers/media/video/saa7134/saa7134-input.c index c12184a38..0ad81e690 100644 --- a/linux/drivers/media/video/saa7134/saa7134-input.c +++ b/linux/drivers/media/video/saa7134/saa7134-input.c @@ -476,11 +476,7 @@ int saa7134_input_init1(struct saa7134_dev *dev) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &dev->pci->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &dev->pci->dev; -#else - input_dev->dev = &dev->pci->dev; -#endif #endif dev->remote = ir; diff --git a/linux/drivers/media/video/saa7134/saa7134.h b/linux/drivers/media/video/saa7134/saa7134.h index 08bc1d0fa..6afbc0c57 100644 --- a/linux/drivers/media/video/saa7134/saa7134.h +++ b/linux/drivers/media/video/saa7134/saa7134.h @@ -29,9 +29,7 @@ #include <linux/input.h> #include <linux/notifier.h> #include <linux/delay.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <asm/io.h> @@ -415,11 +413,7 @@ struct saa7134_fh { /* dmasound dsp status */ struct saa7134_dmasound { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif int minor_mixer; int minor_dsp; unsigned int users_dsp; @@ -473,11 +467,7 @@ struct saa7134_mpeg_ops { /* global device status */ struct saa7134_dev { struct list_head devlist; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif spinlock_t slock; struct v4l2_prio_state prio; /* workstruct for loading modules */ diff --git a/linux/drivers/media/video/se401.h b/linux/drivers/media/video/se401.h index bdbb20f75..81f2c2c74 100644 --- a/linux/drivers/media/video/se401.h +++ b/linux/drivers/media/video/se401.h @@ -6,9 +6,7 @@ #include "compat.h" #include <linux/videodev.h> #include <media/v4l2-common.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #define se401_DEBUG /* Turn on debug messages */ @@ -193,11 +191,7 @@ struct usb_se401 { int maxframesize; int cframesize; /* current framesize */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif int user; /* user count for exclusive use */ int removed; /* device disconnected */ diff --git a/linux/drivers/media/video/sn9c102/sn9c102.h b/linux/drivers/media/video/sn9c102/sn9c102.h index c6e41428d..491a803e5 100644 --- a/linux/drivers/media/video/sn9c102/sn9c102.h +++ b/linux/drivers/media/video/sn9c102/sn9c102.h @@ -33,9 +33,7 @@ #include <linux/types.h> #include <linux/param.h> #include <linux/rwsem.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/string.h> #include <linux/stddef.h> #include <linux/kref.h> @@ -131,11 +129,7 @@ struct sn9c102_device { u8 users; struct completion probe; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex open_mutex, fileop_mutex; -#else - struct semaphore open_mutex, fileop_mutex; -#endif spinlock_t queue_lock; wait_queue_head_t wait_open, wait_frame, wait_stream; }; diff --git a/linux/drivers/media/video/stv680.c b/linux/drivers/media/video/stv680.c index 8bc396533..7aa94abfd 100644 --- a/linux/drivers/media/video/stv680.c +++ b/linux/drivers/media/video/stv680.c @@ -67,9 +67,7 @@ #include <linux/videodev.h> #include <media/v4l2-common.h> #include <linux/usb.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "compat.h" #include "stv680.h" diff --git a/linux/drivers/media/video/stv680.h b/linux/drivers/media/video/stv680.h index cbbcd4f25..a08f1b08a 100644 --- a/linux/drivers/media/video/stv680.h +++ b/linux/drivers/media/video/stv680.h @@ -118,11 +118,7 @@ struct usb_stv { int origGain; int origMode; /* original camera mode */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; /* to lock the structure */ -#else - struct semaphore lock; /* to lock the structure */ -#endif int user; /* user count for exclusive use */ int removed; /* device disconnected */ int streaming; /* Are we streaming video? */ diff --git a/linux/drivers/media/video/tda7432.c b/linux/drivers/media/video/tda7432.c index 1305820d2..29bcbd0f7 100644 --- a/linux/drivers/media/video/tda7432.c +++ b/linux/drivers/media/video/tda7432.c @@ -509,15 +509,9 @@ static int tda7432_command(struct i2c_client *client, } static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tda7432", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tda7432", }, -#endif .id = I2C_DRIVERID_TDA7432, .attach_adapter = tda7432_probe, .detach_client = tda7432_detach, diff --git a/linux/drivers/media/video/tda9840.c b/linux/drivers/media/video/tda9840.c index 537a06492..f4ebfd84b 100644 --- a/linux/drivers/media/video/tda9840.c +++ b/linux/drivers/media/video/tda9840.c @@ -35,13 +35,9 @@ static int debug; /* insmod parameter */ module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Turn on/off device debugging (default:off)."); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define dprintk(args...) \ - do { if (debug) { printk("%s: %s()[%d]: ",__stringify(KBUILD_MODNAME), __func__, __LINE__); printk(args); } } while (0) -#else + #define dprintk(args...) \ do { if (debug) { printk("%s: %s()[%d]: ", KBUILD_MODNAME, __func__, __LINE__); printk(args); } } while (0) -#endif #define SWITCH 0x00 #define LEVEL_ADJUST 0x02 @@ -228,15 +224,9 @@ static int detach(struct i2c_client *client) } static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tda9840", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tda9840", }, -#endif .id = I2C_DRIVERID_TDA9840, .attach_adapter = attach, .detach_client = detach, diff --git a/linux/drivers/media/video/tda9875.c b/linux/drivers/media/video/tda9875.c index 86e721656..5c3d43082 100644 --- a/linux/drivers/media/video/tda9875.c +++ b/linux/drivers/media/video/tda9875.c @@ -433,15 +433,9 @@ static int tda9875_command(struct i2c_client *client, static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tda9875", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tda9875", }, -#endif .id = I2C_DRIVERID_TDA9875, .attach_adapter = tda9875_probe, .detach_client = tda9875_detach, diff --git a/linux/drivers/media/video/tea6415c.c b/linux/drivers/media/video/tea6415c.c index cb700dde7..da654bd15 100644 --- a/linux/drivers/media/video/tea6415c.c +++ b/linux/drivers/media/video/tea6415c.c @@ -37,13 +37,9 @@ static int debug; /* insmod parameter */ module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Turn on/off device debugging (default:off)."); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define dprintk(args...) \ - do { if (debug) { printk("%s: %s()[%d]: ",__stringify(KBUILD_MODNAME), __func__, __LINE__); printk(args); } } while (0) -#else + #define dprintk(args...) \ do { if (debug) { printk("%s: %s()[%d]: ", KBUILD_MODNAME, __func__, __LINE__); printk(args); } } while (0) -#endif #define TEA6415C_NUM_INPUTS 8 #define TEA6415C_NUM_OUTPUTS 6 @@ -197,15 +193,9 @@ static int command(struct i2c_client *client, unsigned int cmd, void *arg) } static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tea6415c", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tea6415c", }, -#endif .id = I2C_DRIVERID_TEA6415C, .attach_adapter = attach, .detach_client = detach, diff --git a/linux/drivers/media/video/tea6420.c b/linux/drivers/media/video/tea6420.c index f1bba1568..d0c63703c 100644 --- a/linux/drivers/media/video/tea6420.c +++ b/linux/drivers/media/video/tea6420.c @@ -37,13 +37,9 @@ static int debug; /* insmod parameter */ module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Turn on/off device debugging (default:off)."); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define dprintk(args...) \ - do { if (debug) { printk("%s: %s()[%d]: ",__stringify(KBUILD_MODNAME), __func__, __LINE__); printk(args); } } while (0) -#else + #define dprintk(args...) \ do { if (debug) { printk("%s: %s()[%d]: ", KBUILD_MODNAME, __func__, __LINE__); printk(args); } } while (0) -#endif /* addresses to scan, found only at 0x4c and/or 0x4d (7-Bit) */ static unsigned short normal_i2c[] = { I2C_ADDR_TEA6420_1, I2C_ADDR_TEA6420_2, I2C_CLIENT_END }; @@ -173,15 +169,9 @@ static int command(struct i2c_client *client, unsigned int cmd, void *arg) } static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tea6420", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tea6420", }, -#endif .id = I2C_DRIVERID_TEA6420, .attach_adapter = attach, .detach_client = detach, diff --git a/linux/drivers/media/video/tuner-core.c b/linux/drivers/media/video/tuner-core.c index d80f7ee91..60d26aa03 100644 --- a/linux/drivers/media/video/tuner-core.c +++ b/linux/drivers/media/video/tuner-core.c @@ -32,11 +32,7 @@ #define UNSET (-1U) -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 15) -#define PREFIX t->i2c->driver->name -#else #define PREFIX t->i2c->driver->driver.name -#endif /** This macro allows us to probe dynamically, avoiding static links */ #ifdef CONFIG_MEDIA_ATTACH @@ -500,15 +496,9 @@ static void set_type(struct i2c_client *c, unsigned int type, set_freq(c, (V4L2_TUNER_RADIO == t->mode) ? t->radio_freq : t->tv_freq); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - tuner_dbg("%s %s I2C addr 0x%02x with type %d used for 0x%02x\n", - c->adapter->name, c->driver->name, c->addr << 1, type, - t->mode_mask); -#else tuner_dbg("%s %s I2C addr 0x%02x with type %d used for 0x%02x\n", c->adapter->name, c->driver->driver.name, c->addr << 1, type, t->mode_mask); -#endif tuner_i2c_address_check(t); return; diff --git a/linux/drivers/media/video/tvmixer.c b/linux/drivers/media/video/tvmixer.c index 2862efa93..b50e0942e 100644 --- a/linux/drivers/media/video/tvmixer.c +++ b/linux/drivers/media/video/tvmixer.c @@ -216,15 +216,9 @@ static int tvmixer_release(struct inode *inode, struct file *file) } static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tvmixer", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tvmixer", }, -#endif .id = I2C_DRIVERID_TVMIXER, #ifndef I2C_DF_DUMMY .detach_adapter = tvmixer_adapters, diff --git a/linux/drivers/media/video/tvp5150.c b/linux/drivers/media/video/tvp5150.c index 3c0e2b316..6ac63245d 100644 --- a/linux/drivers/media/video/tvp5150.c +++ b/linux/drivers/media/video/tvp5150.c @@ -32,21 +32,6 @@ static int debug; module_param(debug, int, 0); MODULE_PARM_DESC(debug, "Debug level (0-1)"); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define tvp5150_err(fmt, arg...) do { \ - printk(KERN_INFO "%s %d-%04x: " fmt, c->driver->name, \ - i2c_adapter_id(c->adapter), c->addr , ## arg); } while (0) -#define tvp5150_info(fmt, arg...) do { \ - printk(KERN_INFO "%s %d-%04x: " fmt, c->driver->name, \ - i2c_adapter_id(c->adapter), c->addr , ## arg); } while (0) -#define tvp5150_dbg(num, fmt, arg...) \ - do { \ - if (debug >= num) \ - printk(KERN_DEBUG "%s debug %d-%04x: " fmt,\ - c->driver->name, \ - i2c_adapter_id(c->adapter), \ - c->addr , ## arg); } while (0) -#else #define tvp5150_err(fmt, arg...) do { \ printk(KERN_ERR "%s %d-%04x: " fmt, c->driver->driver.name, \ i2c_adapter_id(c->adapter), c->addr , ## arg); } while (0) @@ -60,7 +45,6 @@ MODULE_PARM_DESC(debug, "Debug level (0-1)"); c->driver->driver.name, \ i2c_adapter_id(c->adapter), \ c->addr , ## arg); } while (0) -#endif /* supported controls */ static struct v4l2_queryctrl tvp5150_qctrl[] = { @@ -1133,9 +1117,6 @@ static struct i2c_driver driver; static struct i2c_client client_template = { .name = "(unset)", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_CLIENT_ALLOW_USE, -#endif .driver = &driver, }; @@ -1225,15 +1206,9 @@ static int tvp5150_detach_client(struct i2c_client *c) /* ----------------------------------------------------------------------- */ static struct i2c_driver driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, - .name = "tvp5150", - .flags = I2C_DF_NOTIFY, -#else .driver = { .name = "tvp5150", }, -#endif .id = I2C_DRIVERID_TVP5150, .attach_adapter = tvp5150_attach_adapter, diff --git a/linux/drivers/media/video/usbvideo/konicawc.c b/linux/drivers/media/video/usbvideo/konicawc.c index 6fef59557..25f9b4286 100644 --- a/linux/drivers/media/video/usbvideo/konicawc.c +++ b/linux/drivers/media/video/usbvideo/konicawc.c @@ -244,11 +244,7 @@ static void konicawc_register_input(struct konicawc *cam, struct usb_device *dev #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &dev->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &dev->dev; -#else - input_dev->dev = &dev->dev; -#endif #endif input_dev->evbit[0] = BIT_MASK(EV_KEY); diff --git a/linux/drivers/media/video/usbvideo/quickcam_messenger.c b/linux/drivers/media/video/usbvideo/quickcam_messenger.c index 69f0fc770..f079e8d66 100644 --- a/linux/drivers/media/video/usbvideo/quickcam_messenger.c +++ b/linux/drivers/media/video/usbvideo/quickcam_messenger.c @@ -108,11 +108,7 @@ static void qcm_register_input(struct qcm *cam, struct usb_device *dev) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22) input_dev->dev.parent = &dev->dev; #else -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15) input_dev->cdev.dev = &dev->dev; -#else - input_dev->dev = &dev->dev; -#endif #endif input_dev->evbit[0] = BIT_MASK(EV_KEY); diff --git a/linux/drivers/media/video/usbvideo/usbvideo.h b/linux/drivers/media/video/usbvideo/usbvideo.h index c1f892825..03b3add3d 100644 --- a/linux/drivers/media/video/usbvideo/usbvideo.h +++ b/linux/drivers/media/video/usbvideo/usbvideo.h @@ -19,9 +19,7 @@ #include <linux/videodev.h> #include <media/v4l2-common.h> #include <linux/usb.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "compat.h" /* Most helpful debugging aid */ @@ -217,11 +215,7 @@ struct uvd { unsigned long flags; /* FLAGS_USBVIDEO_xxx */ unsigned long paletteBits; /* Which palettes we accept? */ unsigned short defaultPalette; /* What palette to use for read() */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif int user; /* user count for exclusive use */ videosize_t videosize; /* Current setting */ @@ -280,11 +274,7 @@ struct usbvideo { int num_cameras; /* As allocated */ struct usb_driver usbdrv; /* Interface to the USB stack */ char drvName[80]; /* Driver name */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; /* Mutex protecting camera structures */ -#else - struct semaphore lock; -#endif struct usbvideo_cb cb; /* Table of callbacks (virtual methods) */ struct video_device vdt; /* Video device template */ struct uvd *cam; /* Array of camera structures */ diff --git a/linux/drivers/media/video/usbvideo/vicam.c b/linux/drivers/media/video/usbvideo/vicam.c index 049f588ae..17f542dfb 100644 --- a/linux/drivers/media/video/usbvideo/vicam.c +++ b/linux/drivers/media/video/usbvideo/vicam.c @@ -42,9 +42,7 @@ #include <linux/usb.h> #include <linux/vmalloc.h> #include <linux/slab.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "usbvideo.h" // #define VICAM_DEBUG @@ -406,11 +404,7 @@ struct vicam_camera { struct usb_device *udev; // usb device /* guard against simultaneous accesses to the camera */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex cam_lock; -#else - struct semaphore cam_lock; -#endif int is_initialized; u8 open_count; diff --git a/linux/drivers/media/video/usbvision/usbvision-i2c.c b/linux/drivers/media/video/usbvision/usbvision-i2c.c index 1b6180573..9d2f6b985 100644 --- a/linux/drivers/media/video/usbvision/usbvision-i2c.c +++ b/linux/drivers/media/video/usbvision/usbvision-i2c.c @@ -29,9 +29,7 @@ #include <linux/delay.h> #include <linux/slab.h> #include <linux/version.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,14) #include <linux/utsname.h> -#endif #include <linux/init.h> #include <asm/uaccess.h> #include <linux/ioport.h> @@ -521,9 +519,6 @@ static struct i2c_adapter i2c_adap_template = { static struct i2c_client i2c_client_template = { .name = "usbvision internal", -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_CLIENT_ALLOW_USE, -#endif }; /* diff --git a/linux/drivers/media/video/usbvision/usbvision-video.c b/linux/drivers/media/video/usbvision/usbvision-video.c index 073d30454..cd6c41d67 100644 --- a/linux/drivers/media/video/usbvision/usbvision-video.c +++ b/linux/drivers/media/video/usbvision/usbvision-video.c @@ -1625,19 +1625,10 @@ static struct usb_usbvision *usbvision_alloc(struct usb_device *dev) { struct usb_usbvision *usbvision; -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) - if ((usbvision = kmalloc(sizeof(struct usb_usbvision), GFP_KERNEL)) == - NULL) { - goto err_exit; - } - - memset(usbvision, 0, sizeof(struct usb_usbvision)); -#else if ((usbvision = kzalloc(sizeof(struct usb_usbvision), GFP_KERNEL)) == NULL) { goto err_exit; } -#endif usbvision->dev = dev; @@ -1900,9 +1891,6 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf) } static struct usb_driver usbvision_driver = { -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) - .owner = THIS_MODULE, -#endif .name = "usbvision", .id_table = usbvision_table, .probe = usbvision_probe, diff --git a/linux/drivers/media/video/usbvision/usbvision.h b/linux/drivers/media/video/usbvision/usbvision.h index 371c6987f..590ff1e19 100644 --- a/linux/drivers/media/video/usbvision/usbvision.h +++ b/linux/drivers/media/video/usbvision/usbvision.h @@ -34,9 +34,7 @@ #include <linux/list.h> #include <linux/usb.h> #include <linux/i2c.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <media/v4l2-common.h> #include <media/tuner.h> #include <linux/videodev2.h> @@ -395,11 +393,7 @@ struct usb_usbvision { unsigned char iface; /* Video interface number */ unsigned char ifaceAlt; /* Alt settings */ unsigned char Vin_Reg2_Preset; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif struct timer_list powerOffTimer; struct work_struct powerOffWork; int power; /* is the device powered on? */ diff --git a/linux/drivers/media/video/v4l2-common.c b/linux/drivers/media/video/v4l2-common.c index c8b3da9f6..1e795e928 100644 --- a/linux/drivers/media/video/v4l2-common.c +++ b/linux/drivers/media/video/v4l2-common.c @@ -724,9 +724,6 @@ int v4l2_i2c_attach(struct i2c_adapter *adapter, int address, struct i2c_driver client->addr = address; client->adapter = adapter; client->driver = driver; -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - client->flags = I2C_CLIENT_ALLOW_USE; -#endif strlcpy(client->name, name, sizeof(client->name)); err = probe(client, NULL); diff --git a/linux/drivers/media/video/videodev.c b/linux/drivers/media/video/videodev.c index 91fcf1695..7ac11d5fb 100644 --- a/linux/drivers/media/video/videodev.c +++ b/linux/drivers/media/video/videodev.c @@ -42,9 +42,6 @@ #include <linux/slab.h> #include <asm/uaccess.h> #include <asm/system.h> -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#include <asm/semaphore.h> -#endif #define __OLD_VIDIOC_ /* To allow fixing old calls*/ #include <linux/videodev2.h> diff --git a/linux/drivers/media/video/vino.c b/linux/drivers/media/video/vino.c index bf15e2eb2..60527b164 100644 --- a/linux/drivers/media/video/vino.c +++ b/linux/drivers/media/video/vino.c @@ -41,9 +41,7 @@ #include <linux/videodev.h> #include <media/v4l2-common.h> #include <linux/video_decoder.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) #include <linux/mutex.h> -#endif #include <asm/paccess.h> #include <asm/io.h> @@ -247,11 +245,7 @@ struct vino_framebuffer_queue { struct vino_framebuffer *buffer[VINO_FRAMEBUFFER_COUNT_MAX]; spinlock_t queue_lock; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) struct mutex queue_mutex; -#else - struct semaphore queue_mutex; -#endif wait_queue_head_t frame_wait_queue; }; @@ -289,11 +283,7 @@ struct vino_channel_settings { /* the driver is currently processing the queue */ int capturing; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) struct mutex mutex; -#else - struct semaphore mutex; -#endif spinlock_t capture_lock; unsigned int users; diff --git a/linux/drivers/media/video/vivi.c b/linux/drivers/media/video/vivi.c index 98ee2225c..78108a4e0 100644 --- a/linux/drivers/media/video/vivi.c +++ b/linux/drivers/media/video/vivi.c @@ -25,11 +25,7 @@ #include <linux/pci.h> #include <linux/random.h> #include <linux/version.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include "compat.h" #include <linux/videodev2.h> #include <linux/dma-mapping.h> diff --git a/linux/drivers/media/video/w9968cf.h b/linux/drivers/media/video/w9968cf.h index 8e1742cb7..15ea445e5 100644 --- a/linux/drivers/media/video/w9968cf.h +++ b/linux/drivers/media/video/w9968cf.h @@ -31,12 +31,7 @@ #include <linux/param.h> #include <linux/types.h> #include <linux/rwsem.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#else -/* Having a version check for each mutex defined is annoying */ -#define mutex semaphore -#endif #include <media/ovcamchip.h> #include "compat.h" diff --git a/linux/drivers/media/video/zc0301/zc0301.h b/linux/drivers/media/video/zc0301/zc0301.h index d0e258176..a7c7b1116 100644 --- a/linux/drivers/media/video/zc0301/zc0301.h +++ b/linux/drivers/media/video/zc0301/zc0301.h @@ -33,9 +33,7 @@ #include <linux/wait.h> #include <linux/types.h> #include <linux/param.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/rwsem.h> #include <linux/stddef.h> #include <linux/string.h> @@ -130,11 +128,7 @@ struct zc0301_device { u8 users; struct completion probe; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex open_mutex, fileop_mutex; -#else - struct semaphore open_mutex, fileop_mutex; -#endif spinlock_t queue_lock; wait_queue_head_t wait_open, wait_frame, wait_stream; }; diff --git a/linux/drivers/media/video/zoran.h b/linux/drivers/media/video/zoran.h index baa5f423d..46b7ad477 100644 --- a/linux/drivers/media/video/zoran.h +++ b/linux/drivers/media/video/zoran.h @@ -390,11 +390,7 @@ struct zoran { struct videocodec *codec; /* video codec */ struct videocodec *vfe; /* video front end */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex resource_lock; /* prevent evil stuff */ -#else - struct semaphore resource_lock; /* prevent evil stuff */ -#endif u8 initialized; /* flag if zoran has been correctly initalized */ int user; /* number of current users */ diff --git a/linux/drivers/media/video/zoran_card.c b/linux/drivers/media/video/zoran_card.c index b517ce4f1..56d8edecc 100644 --- a/linux/drivers/media/video/zoran_card.c +++ b/linux/drivers/media/video/zoran_card.c @@ -50,9 +50,7 @@ #include <linux/interrupt.h> #include <linux/video_decoder.h> #include <linux/video_encoder.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <asm/io.h> diff --git a/linux/drivers/media/video/zoran_driver.c b/linux/drivers/media/video/zoran_driver.c index 73546a20d..844c688e8 100644 --- a/linux/drivers/media/video/zoran_driver.c +++ b/linux/drivers/media/video/zoran_driver.c @@ -81,9 +81,7 @@ #include <linux/video_decoder.h> #include <linux/video_encoder.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include "zoran.h" #include "zoran_device.h" #include "zoran_card.h" diff --git a/linux/drivers/media/video/zr364xx.c b/linux/drivers/media/video/zr364xx.c index 2e7cf6f26..b1a65e3f5 100644 --- a/linux/drivers/media/video/zr364xx.c +++ b/linux/drivers/media/video/zr364xx.c @@ -115,11 +115,7 @@ struct zr364xx_camera { int width; int height; int method; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif }; diff --git a/linux/include/media/saa7146.h b/linux/include/media/saa7146.h index e4a7aa2aa..daed75624 100644 --- a/linux/include/media/saa7146.h +++ b/linux/include/media/saa7146.h @@ -12,9 +12,7 @@ #include <asm/io.h> /* for accessing devices */ #include <linux/stringify.h> #include "compat.h" -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#endif #include <linux/scatterlist.h> #include <linux/vmalloc.h> /* for vmalloc() */ @@ -27,23 +25,14 @@ extern unsigned int saa7146_debug; -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -//#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),__stringify(KBUILD_MODNAME),__FUNCTION__) -#else //#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),KBUILD_MODNAME,__FUNCTION__) -#endif #ifndef DEBUG_VARIABLE #define DEBUG_VARIABLE saa7146_debug #endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define DEBUG_PROLOG printk("%s: %s(): ",__stringify(KBUILD_MODNAME),__FUNCTION__) -#define INFO(x) { printk("%s: ",__stringify(KBUILD_MODNAME)); printk x; } -#else #define DEBUG_PROLOG printk("%s: %s(): ",KBUILD_MODNAME,__FUNCTION__) #define INFO(x) { printk("%s: ",KBUILD_MODNAME); printk x; } -#endif #define ERR(x) { DEBUG_PROLOG; printk x; } @@ -124,11 +113,7 @@ struct saa7146_dev /* different device locks */ spinlock_t slock; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif unsigned char __iomem *mem; /* pointer to mapped IO memory */ u32 revision; /* chip revision; needed for bug-workarounds*/ @@ -149,11 +134,7 @@ struct saa7146_dev void (*vv_callback)(struct saa7146_dev *dev, unsigned long status); /* i2c-stuff */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex i2c_lock; -#else - struct semaphore i2c_lock; -#endif u32 i2c_bitrate; struct saa7146_dma d_i2c; /* pointer to i2c memory */ @@ -170,11 +151,7 @@ int saa7146_i2c_adapter_prepare(struct saa7146_dev *dev, struct i2c_adapter *i2c /* from saa7146_core.c */ extern struct list_head saa7146_devices; -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) extern struct mutex saa7146_devices_lock; -#else -extern struct semaphore saa7146_devices_lock; -#endif int saa7146_register_extension(struct saa7146_extension*); int saa7146_unregister_extension(struct saa7146_extension*); struct saa7146_format* format_by_fourcc(struct saa7146_dev *dev, int fourcc); diff --git a/linux/include/media/v4l2-common.h b/linux/include/media/v4l2-common.h index 47cc48ea9..020d05758 100644 --- a/linux/include/media/v4l2-common.h +++ b/linux/include/media/v4l2-common.h @@ -40,15 +40,9 @@ #define v4l_printk(level, name, adapter, addr, fmt, arg...) \ printk(level "%s %d-%04x: " fmt, name, i2c_adapter_id(adapter), addr , ## arg) -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define v4l_client_printk(level, client, fmt, arg...) \ - v4l_printk(level, (client)->driver->name, (client)->adapter, \ - (client)->addr, fmt , ## arg) -#else #define v4l_client_printk(level, client, fmt, arg...) \ v4l_printk(level, (client)->driver->driver.name, (client)->adapter, \ (client)->addr, fmt , ## arg) -#endif #define v4l_err(client, fmt, arg...) \ v4l_client_printk(KERN_ERR, client, fmt , ## arg) diff --git a/linux/include/media/v4l2-dev.h b/linux/include/media/v4l2-dev.h index fb356eb57..aa0fd8c94 100644 --- a/linux/include/media/v4l2-dev.h +++ b/linux/include/media/v4l2-dev.h @@ -15,11 +15,7 @@ #include <linux/poll.h> #include <linux/fs.h> #include <linux/device.h> -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include <linux/compiler.h> /* need __user */ #ifdef CONFIG_VIDEO_V4L1_COMPAT #include <linux/videodev.h> @@ -359,11 +355,7 @@ void *priv; /* for videodev.c intenal usage -- please don't touch */ int users; /* video_exclusive_{open|close} ... */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; /* ... helper function uses these */ -#else - struct semaphore lock; /* ... helper function uses these */ -#endif }; /* Class-dev to video-device */ diff --git a/linux/include/media/v4l2-i2c-drv-legacy.h b/linux/include/media/v4l2-i2c-drv-legacy.h index 738f87454..31d6e103c 100644 --- a/linux/include/media/v4l2-i2c-drv-legacy.h +++ b/linux/include/media/v4l2-i2c-drv-legacy.h @@ -77,19 +77,11 @@ static int v4l2_i2c_drv_detach_legacy(struct i2c_client *client) return 0; } -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,14) #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,20) static int v4l2_i2c_drv_suspend_helper(struct i2c_client *client, pm_message_t state) #else static int v4l2_i2c_drv_suspend_helper(struct device * dev, pm_message_t state) #endif -#else -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,13) -static int v4l2_i2c_drv_suspend_helper(struct device * dev, pm_message_t state, u32 level) -#else -static int v4l2_i2c_drv_suspend_helper(struct device * dev, u32 state, u32 level) -#endif -#endif { #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20) struct i2c_client *client = container_of(dev, struct i2c_client, dev); @@ -97,15 +89,11 @@ static int v4l2_i2c_drv_suspend_helper(struct device * dev, u32 state, u32 level return v4l2_i2c_data.suspend ? v4l2_i2c_data.suspend(client, state) : 0; } -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,14) #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,20) static int v4l2_i2c_drv_resume_helper(struct i2c_client *client) #else static int v4l2_i2c_drv_resume_helper(struct device * dev) #endif -#else -static int v4l2_i2c_drv_resume_helper(struct device * dev, u32 level) -#endif { #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20) struct i2c_client *client = container_of(dev, struct i2c_client, dev); @@ -117,16 +105,8 @@ static int v4l2_i2c_drv_resume_helper(struct device * dev, u32 level) /* i2c implementation */ static struct i2c_driver v4l2_i2c_driver_legacy = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_DF_NOTIFY, -#endif .driver = { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) .owner = THIS_MODULE, -#endif #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20) .suspend = v4l2_i2c_drv_suspend_helper, .resume = v4l2_i2c_drv_resume_helper, @@ -166,11 +146,7 @@ static int __init v4l2_i2c_drv_init(void) if (v4l2_i2c_data.legacy_class == 0) v4l2_i2c_data.legacy_class = I2C_CLASS_TV_ANALOG; -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - strlcpy(v4l2_i2c_driver_legacy.name, v4l2_i2c_drv_name_legacy, sizeof(v4l2_i2c_driver_legacy.name)); -#else v4l2_i2c_driver_legacy.driver.name = v4l2_i2c_drv_name_legacy; -#endif v4l2_i2c_driver_legacy.id = v4l2_i2c_data.driverid; v4l2_i2c_driver_legacy.command = v4l2_i2c_data.command; err = i2c_add_driver(&v4l2_i2c_driver_legacy); diff --git a/linux/include/media/v4l2-i2c-drv.h b/linux/include/media/v4l2-i2c-drv.h index f74c8a64a..9333e56b3 100644 --- a/linux/include/media/v4l2-i2c-drv.h +++ b/linux/include/media/v4l2-i2c-drv.h @@ -111,19 +111,11 @@ static int v4l2_i2c_drv_detach_legacy(struct i2c_client *client) return 0; } -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,14) #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,20) static int v4l2_i2c_drv_suspend_helper(struct i2c_client *client, pm_message_t state) #else static int v4l2_i2c_drv_suspend_helper(struct device * dev, pm_message_t state) #endif -#else -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,13) -static int v4l2_i2c_drv_suspend_helper(struct device * dev, pm_message_t state, u32 level) -#else -static int v4l2_i2c_drv_suspend_helper(struct device * dev, u32 state, u32 level) -#endif -#endif { #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20) struct i2c_client *client = container_of(dev, struct i2c_client, dev); @@ -131,15 +123,11 @@ static int v4l2_i2c_drv_suspend_helper(struct device * dev, u32 state, u32 level return v4l2_i2c_data.suspend ? v4l2_i2c_data.suspend(client, state) : 0; } -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,14) #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,20) static int v4l2_i2c_drv_resume_helper(struct i2c_client *client) #else static int v4l2_i2c_drv_resume_helper(struct device * dev) #endif -#else -static int v4l2_i2c_drv_resume_helper(struct device * dev, u32 level) -#endif { #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20) struct i2c_client *client = container_of(dev, struct i2c_client, dev); @@ -150,16 +138,8 @@ static int v4l2_i2c_drv_resume_helper(struct device * dev, u32 level) /* ----------------------------------------------------------------------- */ static struct i2c_driver v4l2_i2c_driver = { -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .owner = THIS_MODULE, -#endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - .flags = I2C_DF_NOTIFY, -#endif .driver = { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) .owner = THIS_MODULE, -#endif #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20) .suspend = v4l2_i2c_drv_suspend_helper, .resume = v4l2_i2c_drv_resume_helper, @@ -180,11 +160,7 @@ static int __init v4l2_i2c_drv_init(void) if (v4l2_i2c_data.legacy_class == 0) v4l2_i2c_data.legacy_class = I2C_CLASS_TV_ANALOG; -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) - strlcpy(v4l2_i2c_driver.name, v4l2_i2c_data.name, sizeof(v4l2_i2c_driver.name)); -#else v4l2_i2c_driver.driver.name = v4l2_i2c_data.name; -#endif v4l2_i2c_driver.id = v4l2_i2c_data.driverid; v4l2_i2c_driver.command = v4l2_i2c_data.command; return i2c_add_driver(&v4l2_i2c_driver); diff --git a/linux/include/media/videobuf-core.h b/linux/include/media/videobuf-core.h index a2f55ff24..874f1340d 100644 --- a/linux/include/media/videobuf-core.h +++ b/linux/include/media/videobuf-core.h @@ -153,11 +153,7 @@ struct videobuf_qtype_ops { }; struct videobuf_queue { -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex vb_lock; -#else - struct semaphore vb_lock; -#endif spinlock_t *irqlock; struct device *dev; diff --git a/linux/include/media/videobuf-dvb.h b/linux/include/media/videobuf-dvb.h index 84886be5e..b77748696 100644 --- a/linux/include/media/videobuf-dvb.h +++ b/linux/include/media/videobuf-dvb.h @@ -11,11 +11,7 @@ struct videobuf_dvb { struct videobuf_queue dvbq; /* video-buf-dvb state info */ -#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15) struct mutex lock; -#else - struct semaphore lock; -#endif struct task_struct *thread; int nfeeds; diff --git a/linux/sound/oss/aci.c b/linux/sound/oss/aci.c index a8021c8c0..4c407b77f 100644 --- a/linux/sound/oss/aci.c +++ b/linux/sound/oss/aci.c @@ -56,11 +56,7 @@ #include <linux/module.h> #include <linux/proc_fs.h> #include <linux/slab.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include <asm/io.h> #include <asm/uaccess.h> @@ -85,11 +81,7 @@ static int aci_micpreamp=3; /* microphone preamp-level that can't be * * checked with ACI versions prior to 0xb0 */ static int mixer_device; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) static struct mutex aci_mutex; -#else -static struct semaphore aci_mutex; -#endif #ifdef MODULE static int reset; diff --git a/linux/sound/oss/btaudio.c b/linux/sound/oss/btaudio.c index 92438ac2f..9aa5f866f 100644 --- a/linux/sound/oss/btaudio.c +++ b/linux/sound/oss/btaudio.c @@ -32,11 +32,7 @@ #include <linux/soundcard.h> #include <linux/slab.h> #include <linux/kdev_t.h> -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include <linux/mutex.h> -#else -#include <asm/semaphore.h> -#endif #include <asm/uaccess.h> #include <asm/io.h> @@ -115,11 +111,7 @@ struct btaudio { /* locking */ int users; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) struct mutex lock; -#else - struct semaphore lock; -#endif /* risc instructions */ unsigned int risc_size; diff --git a/linux/sound/pci/bt87x.c b/linux/sound/pci/bt87x.c index f9775c090..c33300f22 100644 --- a/linux/sound/pci/bt87x.c +++ b/linux/sound/pci/bt87x.c @@ -409,21 +409,13 @@ static int snd_bt87x_set_digital_hw(struct snd_bt87x *chip, struct snd_pcm_runti static int snd_bt87x_set_analog_hw(struct snd_bt87x *chip, struct snd_pcm_runtime *runtime) { -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) static struct snd_ratnum analog_clock = { -#else - static ratnum_t analog_clock = { -#endif .num = ANALOG_CLOCK, .den_min = CLOCK_DIV_MIN, .den_max = CLOCK_DIV_MAX, .den_step = 1 }; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) static struct snd_pcm_hw_constraint_ratnums constraint_rates = { -#else - static snd_pcm_hw_constraint_ratnums_t constraint_rates = { -#endif .nrats = 1, .rats = &analog_clock }; @@ -750,11 +742,7 @@ static int __devinit snd_bt87x_create(struct snd_card *card, { struct snd_bt87x *chip; int err; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) static struct snd_device_ops ops = { -#else - static snd_device_ops_t ops = { -#endif .dev_free = snd_bt87x_dev_free }; diff --git a/v4l/compat.h b/v4l/compat.h index b59d0ed04..d32806e9b 100644 --- a/v4l/compat.h +++ b/v4l/compat.h @@ -39,19 +39,6 @@ # define I2C_M_IGNORE_NAK 0x1000 #endif -/* vm_insert_page() was added in 2.6.15 */ -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) && defined(_LINUX_MM_H) -static inline int vm_insert_page(struct vm_area_struct *vma, - unsigned long addr, struct page *page) -{ - return remap_pfn_range(vma, addr, page_to_pfn(page), PAGE_SIZE, - vma->vm_page_prot); -} -#endif - -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) -# define class_device_create(a, b, c, d, e, f, g, h) class_device_create(a, c, d, e, f, g, h) -#endif /* device_create/destroy added in 2.6.18 */ #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18) /* on older kernels, class_device_create will in turn be a compat macro */ @@ -59,42 +46,6 @@ static inline int vm_insert_page(struct vm_area_struct *vma, # define device_destroy(a, b) class_device_destroy(a, b) #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) -# define input_allocate_device() kzalloc(sizeof(struct input_dev),GFP_KERNEL); -# define input_free_device(input_dev) kfree(input_dev) -# ifdef _INPUT_H /* input.h must be included _before_ compat.h for this to work */ - /* input_register_device() was changed to return an error code in 2.6.15 */ -# define input_register_device(x) (input_register_device(x), 0) -# endif -#endif - -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) -#define DEFINE_MUTEX(a) DECLARE_MUTEX(a) -#define mutex_lock_interruptible(a) down_interruptible(a) -#define mutex_unlock(a) up(a) -#define mutex_lock(a) down(a) -#define mutex_init(a) init_MUTEX(a) -#define mutex_trylock(a) down_trylock(a) -#endif - -/* New 4GB DMA zone was added in 2.6.15-rc2 */ -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) -# define __GFP_DMA32 __GFP_DMA -#endif - -/* setup_timer() helper added 10/31/05, 2.6.15-rc1 */ -/* Need linux/timer.h to be included for struct timer_list */ -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,15) && defined(_LINUX_TIMER_H) -static inline void setup_timer(struct timer_list * timer, - void (*function)(unsigned long), - unsigned long data) -{ - timer->function = function; - timer->data = data; - init_timer(timer); -} -#endif - #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18) #define IRQF_SHARED SA_SHIRQ #define IRQF_DISABLED SA_INTERRUPT @@ -136,32 +87,6 @@ static inline u8 v4l_compat_pci_rev(struct pci_dev *pci) { u8 rev; pci_read_config_byte(pci, PCI_REVISION_ID, &rev); return rev; } #endif -/* ALSA removed a bunch of typedefs and renamed some structs in 2.6.16 */ -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) -# ifdef __SOUND_CORE_H -# define snd_card _snd_card /* struct _snd_card became struct snd_card */ -# define snd_pcm _snd_pcm -# undef snd_device -# define snd_device _snd_device -# endif -# ifdef __SOUND_PCM_H -# define snd_pcm_substream _snd_pcm_substream -# define snd_pcm_hardware _snd_pcm_hardware -# define snd_pcm_runtime _snd_pcm_runtime -# define snd_pcm_ops _snd_pcm_ops -# endif -# ifdef __SOUND_ASOUND_H -# define snd_pcm_hw_params sndrv_pcm_hw_params -# define snd_ctl_elem_info sndrv_ctl_elem_info -# define snd_ctl_elem_value sndrv_ctl_elem_value -# endif -# ifdef __SOUND_CONTROL_H -# undef snd_kcontrol -# define snd_kcontrol _snd_kcontrol -# define snd_kcontrol_new _snd_kcontrol_new -# endif -#endif - #if defined(COMPAT_PCM_TO_RATE_BIT) && defined(__SOUND_PCM_H) /* New alsa core utility function */ static inline unsigned int snd_pcm_rate_to_rate_bit(unsigned int rate) diff --git a/v4l/versions.txt b/v4l/versions.txt index a31b8ca56..086403c33 100644 --- a/v4l/versions.txt +++ b/v4l/versions.txt @@ -34,232 +34,3 @@ VIDEO_PVRUSB2_SYSFS # DVB_CORE_ATTACH relies on symbol_put_addr which hangs pre-2.6.17 [2.6.17] DVB_CORE_ATTACH - -# Those are architecture-dependent -[2.6.16] -VIDEO_VINO -VIDEO_M32R_AR_M64278 -# Not tested with versions bellow 2.6.16 -VIDEO_OV7670 - -# Changes in struct i2c_driver, i2c_add_driver() -[2.6.16] -VIDEO_ZORAN_BUZ -VIDEO_ZORAN_DC10 -VIDEO_ZORAN_DC30 -VIDEO_ZORAN_LML33 -VIDEO_ZORAN_LML33R10 -VIDEO_ZORAN_AVS6EYES -VIDEO_ZORAN_ZR36060 -VIDEO_SAA5246A -VIDEO_SAA5249 -VIDEO_MXB -VIDEO_DPC -VIDEO_OVCAMCHIP -TUNER_3036 -TUNER_XC2028 - -# Changes to usb_input.h, struct input_dev -[2.6.15] - -# Uses vm_insert_page() -[2.6.15] - -# Uses struct device -[2.6.13] -USB_ET61X251 -USB_SN9C102 -USB_OV511 -USB_PWC -USB_PWC_DEBUG -USB_STV680 -VIDEO_PVRUSB2 -VIDEO_PVRUSB2_24XXX -VIDEO_PVRUSB2_DEBUGIFC -VIDEO_USBVISION - -[2.6.11] -VIDEO_VIVI -VIDEO_DEV -VIDEO_V4L1 -VIDEO_V4L2 -VIDEO_V4L1_COMPAT -VIDEO_ADV_DEBUG -VIDEO_BT848 -VIDEO_BT848_DVB -VIDEO_SAA6588 -VIDEO_CPIA2 -VIDEO_SAA7134 -VIDEO_SAA7134_ALSA -VIDEO_SAA7134_OSS -VIDEO_SAA7134_DVB -VIDEO_SAA7134_DVB_ALL_FRONTENDS -VIDEO_SAA7134_DVB_MT352 -VIDEO_SAA7134_DVB_TDA1004X -VIDEO_SAA7134_DVB_NXT200X -VIDEO_HEXIUM_ORION -VIDEO_HEXIUM_GEMINI -VIDEO_CX88_VP3054 -VIDEO_CX88 -VIDEO_CX88_ALSA -VIDEO_CX88_BLACKBIRD -VIDEO_CX88_DVB -VIDEO_CX88_DVB_ALL_FRONTENDS -VIDEO_CX88_DVB_MT352 -VIDEO_CX88_DVB_VP3054 -VIDEO_CX88_DVB_ZL10353 -VIDEO_CX88_DVB_OR51132 -VIDEO_CX88_DVB_CX22702 -VIDEO_CX88_DVB_LGDT330X -VIDEO_CX88_DVB_NXT200X -VIDEO_CX88_DVB_CX24123 -VIDEO_CX23885 -VIDEO_MSP3400 -VIDEO_CS5345 -VIDEO_CS53L32A -VIDEO_M52790 -VIDEO_WM8775 -VIDEO_WM8739 -VIDEO_VP27SMPX -VIDEO_CX25840 -VIDEO_SAA711X -VIDEO_SAA717X -VIDEO_SAA7127 -VIDEO_UPD64031A -VIDEO_UPD64083 -VIDEO_IVTV -VIDEO_CX18 -VIDEO_EM28XX -VIDEO_AU0828 -DVB -DVB_CORE -DVB_AV7110 -DVB_AV7110_FIRMWARE -DVB_AV7110_FIRMWARE_FILE -DVB_AV7110_OSD -DVB_BUDGET -DVB_BUDGET_CI -DVB_BUDGET_AV -DVB_BUDGET_PATCH -DVB_USB -DVB_USB_DEBUG -DVB_USB_A800 -DVB_USB_DIBUSB_MB -DVB_USB_DIBUSB_MB_FAULTY -DVB_USB_DIBUSB_MC -DVB_USB_UMT_010 -DVB_USB_CXUSB -DVB_USB_M920X -DVB_USB_GL861 -DVB_USB_AU6610 -DVB_USB_DIGITV -DVB_USB_VP7045 -DVB_USB_VP702X -DVB_USB_NOVA_T_USB2 -DVB_USB_DTT200U -DVB_USB_GP8PSK -DVB_USB_TTUSB2 -DVB_TTUSB_BUDGET -DVB_TTUSB_DEC -DVB_CINERGYT2 -DVB_CINERGYT2_TUNING -DVB_B2C2_FLEXCOP -DVB_B2C2_FLEXCOP_PCI -DVB_B2C2_FLEXCOP_USB -DVB_B2C2_FLEXCOP_DEBUG -DVB_BT8XX -DVB_PLUTO2 -DVB_STV0299 -DVB_CX24110 -DVB_CX24123 -DVB_TDA8083 -DVB_MT312 -DVB_VES1X93 -DVB_S5H1420 -DVB_SP8870 -DVB_SP887X -DVB_CX22700 -DVB_CX22702 -DVB_L64781 -DVB_TDA1004X -DVB_NXT6000 -DVB_MT352 -DVB_ZL10353 -DVB_DIB3000MB -DVB_DIB3000MC -DVB_DIB7000M -DVB_DIB7000P -DVB_VES1820 -DVB_TDA10021 -DVB_STV0297 -DVB_NXT200X -DVB_OR51211 -DVB_OR51132 -DVB_BCM3510 -DVB_LGDT330X -DVB_S5H1409 -DVB_TUNER_XC5000 -DVB_LNBP21 -DVB_ISL6421 -DVB_TUNER_MT2060 -DVB_TUNER_MT2131 -DVB_TDA827X -DVB_TDA18271 -DVB_AU8522 -DVB_TDA10048 -DVB_S5H1411 -VIDEO_SAA7146 -VIDEO_SAA7146_VV -VIDEO_TUNER -VIDEO_BTCX -VIDEO_IR -VIDEO_TVEEPROM -VIDEO_CX2341X -VIDEO_USBVIDEO -TUNER_MT20XX -TUNER_TDA8290 -TUNER_TEA5761 -TUNER_TEA5767 -TUNER_SIMPLE -USB_VICAM -USB_IBMCAM -VIDEO_TLV320AIC23B -VIDEO_ZORAN -VIDEO_BWQCAM -VIDEO_CQCAM -VIDEO_W9966 -VIDEO_PMS -VIDEO_STRADIS -VIDEO_CPIA -VIDEO_CPIA_PP -VIDEO_CPIA_USB -VIDEO_MEYE -USB_DABUSB -USB_DSBR -USB_SE401 -USB_W9968CF -VIDEO_M32R_AR -RADIO_CADET -RADIO_RTRACK -RADIO_RTRACK2 -RADIO_AZTECH -RADIO_GEMTEK -RADIO_GEMTEK_PCI -RADIO_MAXIRADIO -RADIO_MAESTRO -RADIO_MIROPCM20 -RADIO_MIROPCM20_RDS -RADIO_SF16FMI -RADIO_SF16FMR2 -RADIO_TERRATEC -RADIO_TRUST -RADIO_TYPHOON -RADIO_TYPHOON_PROC_FS -RADIO_ZOLTRIX -VIDEO_SAA7110 -SOUND_ACI_MIXER -USB_KONICAWC -USB_QUICKCAM_MESSENGER -USB_ZC0301 -USB_ZR364XX - |