From ec6beccf0b090e484de9b056da423de36d12a785 Mon Sep 17 00:00:00 2001 From: Michael Hunold Date: Tue, 14 Oct 2003 09:53:12 +0000 Subject: Pass thorugh return value of register_chrdev() --- linux/drivers/media/dvb/dvb-core/dvbdev.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'linux/drivers/media') diff --git a/linux/drivers/media/dvb/dvb-core/dvbdev.c b/linux/drivers/media/dvb/dvb-core/dvbdev.c index b7978047f..cf5850799 100644 --- a/linux/drivers/media/dvb/dvb-core/dvbdev.c +++ b/linux/drivers/media/dvb/dvb-core/dvbdev.c @@ -348,18 +348,18 @@ int dvb_unregister_adapter(struct dvb_adapter *adap) static int __init init_dvbdev(void) { + int retval; #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)) dvb_devfs_handle = devfs_mk_dir (NULL, "dvb", NULL); #else devfs_mk_dir("dvb"); #endif #ifndef CONFIG_DVB_DEVFS_ONLY - if(register_chrdev(DVB_MAJOR,"DVB", &dvb_device_fops)) { + retval register_chrdev(DVB_MAJOR,"DVB", &dvb_device_fops); + if(0 != retval) { printk("video_dev: unable to get major %d\n", DVB_MAJOR); - return -EIO; - } #endif - return 0; + return retval; } -- cgit v1.2.3