summaryrefslogtreecommitdiff
path: root/drivers/media/dvb/dvb-usb/dvb-usb-init.c
diff options
context:
space:
mode:
authorPatrick Boettcher <pb@linuxtv.org>2005-09-10 00:02:47 +0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-10 00:57:41 +0400
commit47dc3d688d04f06d8ef90a06c48930906fbc4a8c (patch)
tree705fc3f433180d96e357bdcf4814408169367018 /drivers/media/dvb/dvb-usb/dvb-usb-init.c
parent62703b9d72114a563488cd4be6d0827618395589 (diff)
downloadlinux-47dc3d688d04f06d8ef90a06c48930906fbc4a8c.tar.xz
[PATCH] dvb: usb: core: change dvb_usb_device_init() API
Change the init call to optionally return the new dvb_usb_device directly. Signed-off-by: Patrick Boettcher <pb@linuxtv.org> Signed-off-by: Johannes Stezenbach <js@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/media/dvb/dvb-usb/dvb-usb-init.c')
-rw-r--r--drivers/media/dvb/dvb-usb/dvb-usb-init.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/media/dvb/dvb-usb/dvb-usb-init.c b/drivers/media/dvb/dvb-usb/dvb-usb-init.c
index ea1098a6c7a8..a902059812a2 100644
--- a/drivers/media/dvb/dvb-usb/dvb-usb-init.c
+++ b/drivers/media/dvb/dvb-usb/dvb-usb-init.c
@@ -128,7 +128,9 @@ static struct dvb_usb_device_description * dvb_usb_find_device(struct usb_device
/*
* USB
*/
-int dvb_usb_device_init(struct usb_interface *intf, struct dvb_usb_properties *props, struct module *owner)
+
+int dvb_usb_device_init(struct usb_interface *intf, struct dvb_usb_properties
+ *props, struct module *owner,struct dvb_usb_device **du)
{
struct usb_device *udev = interface_to_usbdev(intf);
struct dvb_usb_device *d = NULL;
@@ -170,6 +172,9 @@ int dvb_usb_device_init(struct usb_interface *intf, struct dvb_usb_properties *p
usb_set_intfdata(intf, d);
+ if (du != NULL)
+ *du = d;
+
ret = dvb_usb_init(d);
}