aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/dvb/dvb-core/dvbdev.c
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw2@shinybook.infradead.org>2005-05-19 11:54:00 +0100
committerDavid Woodhouse <dwmw2@shinybook.infradead.org>2005-05-19 11:54:00 +0100
commit7063e6c717f6108c4b3fc3135a516c86ef944870 (patch)
treeec6eec10b4dc93474100e6e366df028bd3314fda /drivers/media/dvb/dvb-core/dvbdev.c
parent7ca0026495dbb644b4e32ede76be44072cb2bc7a (diff)
parent05d3794aa8bd3b2c9f7920a05003c331cdeb75c5 (diff)
Merge with master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
Diffstat (limited to 'drivers/media/dvb/dvb-core/dvbdev.c')
-rw-r--r--drivers/media/dvb/dvb-core/dvbdev.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/media/dvb/dvb-core/dvbdev.c b/drivers/media/dvb/dvb-core/dvbdev.c
index cf4ffe38fda..9d9662f4b8e 100644
--- a/drivers/media/dvb/dvb-core/dvbdev.c
+++ b/drivers/media/dvb/dvb-core/dvbdev.c
@@ -286,9 +286,8 @@ skip:
}
-int dvb_register_adapter(struct dvb_adapter **padap, const char *name, struct module *module)
+int dvb_register_adapter(struct dvb_adapter *adap, const char *name, struct module *module)
{
- struct dvb_adapter *adap;
int num;
if (down_interruptible (&dvbdev_register_lock))
@@ -299,11 +298,6 @@ int dvb_register_adapter(struct dvb_adapter **padap, const char *name, struct mo
return -ENFILE;
}
- if (!(*padap = adap = kmalloc(sizeof(struct dvb_adapter), GFP_KERNEL))) {
- up(&dvbdev_register_lock);
- return -ENOMEM;
- }
-
memset (adap, 0, sizeof(struct dvb_adapter));
INIT_LIST_HEAD (&adap->device_list);
@@ -331,7 +325,6 @@ int dvb_unregister_adapter(struct dvb_adapter *adap)
return -ERESTARTSYS;
list_del (&adap->list_head);
up (&dvbdev_register_lock);
- kfree (adap);
return 0;
}
EXPORT_SYMBOL(dvb_unregister_adapter);