summaryrefslogtreecommitdiff
path: root/v4l/compat.h
AgeCommit message (Collapse)Author
2007-01-30include config-compat.h with gcc -include commandTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> The kernel's config settings from autoconf.h are overridden by the file config-compat.h, which is included from compat.h. Code compiled before compat.h is included will see the kernel's settings, while code compiled after will see v4l-dvb's version of the settings. This has caused hard to track down bugs on more than one occasion. Always including compat.h first will not work, as some of the compatibility code requires that certain kernel headers be included first in order to work correctly. This patch makes config-compat.h be included second (after the kernel's autoconf.h) for every file by using a gcc "-include" command line option, the same way the kernel autoconf.h file is included. This should eliminate the problem of config-compat.h not being included in the right spot. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-01-30compat: Handle input_register_device() change and some othersTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> input_register_device() was changed to return an error code instead of being void in 2.6.15. Handle it with a macro wrapper in config.h. For this to work, linux/input.h must be included before config.h. This required some trivial header re-ordering in budget-ci.c and ttusb_dec.c. In kernel 2.6.15-rc1 a helper function called setup_timer() was added to linux/timer.h. Add to compat.h, but require that linux/timer.h be included first to give the definition of struct timer_list. A new 4GB DMA zone, __GFP_DMA32, was added in 2.6.15-rc2. Alias it to __GFP_DMA on older kernels. Handle another 2.6.15 "input_dev->dev to input_dev->cdev.dev" change for some recently added code in cinergyT2.c. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-01-09Fix compilation on some webcamsMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> The recent updates on some webcams replaced vmalloc_32 by vmallo_32_user. However, it seems that this doesn't exist before kernel 2.6.19 Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-11-19compat: Use kernel version to control PCIAGP_FAIL compat codeTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> PCIAGP_FAIL is a new pci quirk added in 2.6.19. The code in compat.h was checking if PCIAGP_FAIL was already defined to determine whether or not to include the backward compatibility code. This didn't work in a number of cases when compat.h was included before linux/pci.h, as PCIAGP_FAIL would get defined by compat.h and then re-defined by linux/pci.h. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2006-10-04Add compat for true/falseMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> true/false were incorporated at a common code on pre-kernel 2.6.19. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-09-14Currently, PCIAGP_FAIL only exists on 2.6.18-rc6-mm1Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-08-27Add compat code for usb_to_input_id() which appeared in 2.6.13Trent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Put static inline usb_to_input_id() inside compat.h for pre 2.6.13. This needs linux/usb.h to be included first! Drivers that need linux/usb_input.h compatibility must include linux/usb.h before they include compat.h. There is just no way around it. linux/usb.h cannot be unconditionally included in compat.h because that will break other, non-usb, drivers. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2006-07-25bttv: clean up some pre-2.6.0 class device compat stuffTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Add bit of compat code for class_device_create_file() to compat.h for pre-2.6.0 kernels. This allows an #ifdef to be removed from bttv-driver.c, and helps other code which never had one. Changed the code to turn on for pre-2.6.0, rather than pre-2.5.0, as the class device stuff was added in 2.5.69. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2006-07-19[PATCH] irq-flags: media: Use the new IRQF_ constantsMauro Carvalho Chehab
From: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: "David S. Miller" <davem@davemloft.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-07-15Add compat.h code for schedule_timeout_interruptible()Trent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Add a static inline version of schedule_timeout_interruptible(), it's only two lines, to compat.h. This will make bt866 and ks0127 compile with pre 2.6.14 kernels. Remove #if/#else code from msp3400, saa7134-tvaudio, and vivi that used to handle this. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2006-07-15Whitespace cleanupTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> From the whitespace script Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2006-05-29compat: handle input key definitions added in 2.6.14Michael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2006-05-07fix ability to pass compile-time build options when building from the hg repoMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> When building in-kernel, compile-time build options are passed into the compiler using '#include <linux/config.h>' . This file #include's <linux/autoconf.h> , which is created on the fly by the kbuild system. However, this does not work correctly when building from the mercurial repository, since the kernel is built indepentently of v4l/.myconfig This creates a "config-compat.h", which will be #include'd by compat.h and will emulate <linux/config.h> for the local build. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2006-04-25remove forced dvb frontend module dependencies left around from old build methodMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2006-02-06implemented compat.h for mutex_trylock()Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Fixed also a small mistake at including mutex.h kernel-sync Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-01-15V4L/DVB (3354e): bttv semaphore to mutex conversionMauro Carvalho Chehab
From: Ingo Molnar <mingo@elte.hu> Semaphore to mutex conversion. The conversion was generated via scripts, and the result was validated automatically via a script as well. build-tested. Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> kernel-sync
2005-12-11Makes v4l compile under 2.4 kernelsMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@brturbo.com.br> kernel-sync - Makes V4L compile with kernel 2.4 - em28xx doesn't compile with 2.4 kernels. Additional work is necessary to make it compile. Thanks-to: Stefan Leichter <Stefan.Leichter@camLine.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-12-10make tree to compile against kernel 2.5.31Mauro Carvalho Chehab
kernel-sync Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-12-08Revert my changes from this morning. I was wrong :-(Michael Krufky
- Revert my changes from this morning. I was wrong :-( Thanks to Laurent Pinchart <laurent.pinchart@skynet.be> for pointing out my error. Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-12-08fix compat.h inputdev changesMichael Krufky
Removed linux version check, #include <linux/input.h> ...Should now work for everybody. Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-12-08Restore 2.6.15 check in compat.h for inputdev changesMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-12-08fixed backwards compatability for non-vanilla 2.6.14 kernels.Michael Krufky
Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-12-04Backport of Dmitry Torokhov's input layer changes at mainline kernelRicardo Cerqueira
From: Ricardo Cerqueira <v4l@cerqueira.org> kernel-sync Ported changes by Dmitry Torokhov <dtor_core@ameritech.net> and added backwards compatibility checks for kernels < 2.6.15 Signed-off-by: Ricardo Cerqueira <v4l@cerqueira.org>
2005-11-23remove repeated codeMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-11-232.6.12 backwards compatability for dvbdev.c in dvb+v4l merged-trees.Michael Krufky
Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-11-23add dvb-core to v4l/dvb merged-trees build environmentMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-11-20Enable cx24123 dvb frontend moduleMichael Krufky
- Enable cx24123 dvb frontend module in merged v4l/dvb cvs trees and kernel >= 2.6.16 Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-11-1264-bit fixes esp. for broken compat_ioctl32.Hans Verkuil
From: Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
2005-11-09Fix backward kernel compatibity (nothing for upstream)Nickolay V. Shmyrev
From: Tyler Trafford <tatrafford@comcast.net> Signed-off-by: Nickolay V. Shmyrev <nshmyrev@yandex.ru>
2005-11-08 * ../linux/drivers/media/video/saa7134/saa7134-alsa.c:Nickolay V. Shmyrev
* ../v4l/compat.h: Fix compilation with older kernels. Signed-off-by: Nickolay V. Shmyrev <nshmyrev@yandex.ru>
2005-11-06 - #elsif removed, since it breaks gentree stuff.Mauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-10-27 * ../linux/drivers/media/video/tuner-simple.c:Michael Krufky
(default_set_tv_freq): - ISO C90 forbids mixed declarations and code * ../v4l/compat.h: - Do not build support for nxt200x unless at least one of the following is true: a) KERNEL_VERSION >= 2.6.15 b) v4l / dvb merge-trees build environment. Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-10-20 * ../v4l/compat.h:Nickolay V. Shmyrev
- Fix kcalloc error with kernel < 2.6.9. Signed-off-by: Nickolay V. Shmyrev <<nshmyrev@yandex.ru>>
2005-10-20 * ../v4l/compat.h:Nickolay V. Shmyrev
Fix build of em driver with 2.6.8 kernel. Signed-off-by: Nickolay V. Shmyrev <nshmyrev@yandex.ru>
2005-10-14Several Improvement on I2C IR handling for em2820:Mauro Carvalho Chehab
- moved Pinnacle IR table (ir_codes_em2820) to em2820-input.c - IR struct renamed and moved to a header file. - New file to handle em2820-specific IR. - Some cleanups. - attach now detects I2C IR and calls em2820-specific IR code - IR compat code moved to compat.h - New header with struct IR_i2c there, to allow it to be used by board-specific input handlers. Some improvements at em28xx board detection: - Board detection message improved to show interface and class. - Now it doesn't touch audio interfaces. Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-10-11 * v4l/compat.h:Nickolay V. Shmyrev
- Fix compilation with 2.6.8. Signed-off-by: Nickolay V. Shmyrev <<nshmyrev@yandex.ru>>
2005-10-11added support for the terratec cinergy 250 usb tv remoteMarkus Rechberger
Signed-off-by: Markus Rechberger <mrechberger@gmail.com>
2005-10-09From: Mauro Carvalho Chehab <mchehab@brturbo.com.br>Mauro Carvalho Chehab
- Lots of small changes to allow compiling with kernel 2.4. Compilation result not tested yet. - After this patch, .version should be removed, since its syntax has changed. Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-10-06From Markus Rechberger <mrechberger@gmail.com>,Ludovico Cavedon ↵Mauro Carvalho Chehab
<cavedon@sssup.it>,Mauro Carvalho Chehab <mchehab@brturbo.com.br> - Added support for Empia EM2820/2840 USB video capture devices. Current support is working for: Terratec Cinergy 250 USB Pinnacle PCTV USB 2 Hauppauge WinTV USB 2 Support is not working for: Terratec Cinergy 250 USB (em2800 based) MSI VOX USB 2.0 (saa7114 decoder based) Signed-off-by: Markus Rechberger <mrechberger@gmail.com> Signed-off-by: Ludovico Cavedon <cavedon@sssup.it> Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-09-24 * compat.h:Michael Krufky
- Allow tda1004x & lgdt330x support in tree-merge for all kernels. Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-09-21 * compat.h:Michael Krufky
* cx88-dvb.c: * saa7134-dvb.c: * scripts/merge-trees.sh: * scripts/unmerge-trees.sh: - move some #if kernel version into compat.h Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-09-19 * saa6588.c: (saa6588_probe):Michael Krufky
- fix build for 2.6.14 * compat.h: * ir-kbd-i2c.c: (ir_probe): * saa7134-i2c.c: * tvaudio.c: (chip_probe): - removed some #if kernel version > 2.6.13 ... using compat.h instead. Signed-off-by: Michael Krufky <mkrufky@m1k.net>
2005-09-08 * i2c-kbd-gpio.c:Nickolay V. Shmyrev
- Use KEY_MEDIA instead of KEY_VIDEOMODESWITCH since it fix build with older kernels. Signed-off-by: Nickolay V. Shmyrev <nshmyrev@yandex.ru> Signed-off-by: James Schettine <james@NOSPAM.MyVnc.com>
2005-09-08Fixed build with older kernelsNickolay V. Shmyrev
2005-08-12 * compat.h:Nickolay V. Shmyrev
- Fix build with kernel earlier than 2.6.9. Signed-off-by: Nickolay V. Shmyrev <nshmyrev@yandex.ru>
2005-07-15DVB Stuff removed. Makefile now doesn't need it also.Mauro Carvalho Chehab
compat.h changed to reflect latest API change. Included a script to make ChangeLog Generation easier. Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-07-13 - Linux/version.h removed. Replaced by linux/utsname.hMauro Carvalho Chehab
where KERNEL_VERSION is required. - incremented versions for CX88, BTTV and SAA7134. * compat.h: - Included linux/version.h. This change is required to be compatible with a patch applied at Kernel by Olaf Hering <olh@suse.de> this patch does reduce kernel dependency of its version number. Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
2005-06-13 * saa7134-cards.c, saa7134-dvb.c, saa7134.h:Nickolay V. Shmyrev
- Add new Typhoon DVB-T Cardbus. Thanks to Juergen Orschiedt <jorschiedt@web.de> cx88-core.c: - Fix compilation with gcc4.0
2005-06-12 * audiochip.h, compat.h, cx22702.h, cx88-core.c, cx88-dvb.c,Mauro Carvalho Chehab
cx88-i2c.c, cx88-vbi.c, cx88-video.c, dpl3518.c, dpl3518.h, i2c-compat.h, id.h, msp3400.h, or51132.c, or51132.h, plx9054.h, rds-saa6588.c, saa7134-dvb.c, tda7432.c, tda9875.c, tvaudio.c, tveeprom.h, tvmixer.c, v4l1-compat.c, video-buf-dvb.h: - Minor changes to synchronize with -mm series; - PAL-60 code maintained for SAA7134. However, -mm has different values; - Now, every .c or .h file has cvs field ID.
2005-05-22Large changes. Mostly merged patches from mm kernel branch and 2.6.12-rc4.Nickolay V. Shmyrev
Update entries for Lifiview Platinum FM and Avermedia cards