summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2007-08-17 03:08:46 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-08-17 03:08:46 -0300
commit45a54903feaab08ae3980a1aa4ce8635480d105b (patch)
tree3366df442c5ecbd93e9102fb42b06391833d1d6c /linux
parentfac62b36a8544d767f1454b136254c114ab6ae9d (diff)
downloadmediapointer-dvb-s2-45a54903feaab08ae3980a1aa4ce8635480d105b.tar.gz
mediapointer-dvb-s2-45a54903feaab08ae3980a1aa4ce8635480d105b.tar.bz2
Make dvbdev compatible again with older kernel versions
From: Mauro Carvalho Chehab <mchehab@infradead.org> class_device_create/class_device_destroy are being replaced by device_create/device_destroy. This patch make it backward compatible. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux')
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvbdev.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/drivers/media/dvb/dvb-core/dvbdev.c b/linux/drivers/media/dvb/dvb-core/dvbdev.c
index f44ab30de..564c57b79 100644
--- a/linux/drivers/media/dvb/dvb-core/dvbdev.c
+++ b/linux/drivers/media/dvb/dvb-core/dvbdev.c
@@ -211,7 +211,11 @@ int dvb_register_device(struct dvb_adapter *adap, struct dvb_device **pdvbdev,
{
struct dvb_device *dvbdev;
struct file_operations *dvbdevfops;
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,23)
struct device *clsdev;
+#else
+ struct class_device *clsdev;
+#endif
int id;
mutex_lock(&dvbdev_register_lock);