summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTrent Piepho <xyzzy@speakeasy.org>2006-11-19 12:11:32 -0800
committerTrent Piepho <xyzzy@speakeasy.org>2006-11-19 12:11:32 -0800
commit4069ba86398882e0670b383ee0622f82e3ffe5a7 (patch)
treeebef43933fa1d7cc13bd92e07b7a3453aa46fa54
parent3c979bbe86b21226fde432c617dfa3080141f0bc (diff)
downloadmediapointer-dvb-s2-4069ba86398882e0670b383ee0622f82e3ffe5a7.tar.gz
mediapointer-dvb-s2-4069ba86398882e0670b383ee0622f82e3ffe5a7.tar.bz2
compat: Use kernel version to control PCIAGP_FAIL compat code
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>
-rw-r--r--v4l/compat.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/v4l/compat.h b/v4l/compat.h
index b245c95e2..19d648d5e 100644
--- a/v4l/compat.h
+++ b/v4l/compat.h
@@ -311,8 +311,8 @@ usb_to_input_id(const struct usb_device *dev, struct input_id *id)
}
#endif
-#ifndef PCIAGP_FAIL
- #define PCIAGP_FAIL 0
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19)
+# define PCIAGP_FAIL 0
#endif
#ifndef true