[Mplayer-cvslog] CVS: main/drivers mga_vid.c,1.45,1.46

Arpi of Ize arpi at mplayerhq.hu
Tue May 14 00:10:13 CEST 2002


Update of /cvsroot/mplayer/main/drivers
In directory mail:/var/tmp.root/cvs-serv3878

Modified Files:
	mga_vid.c 
Log Message:
devfs fallback support?

Index: mga_vid.c
===================================================================
RCS file: /cvsroot/mplayer/main/drivers/mga_vid.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -r1.45 -r1.46
--- mga_vid.c	28 Apr 2002 17:22:40 -0000	1.45
+++ mga_vid.c	13 May 2002 22:10:11 -0000	1.46
@@ -1580,8 +1580,8 @@
 					S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IFCHR,
 					&mga_vid_fops, NULL)) == NULL)
 	{
-		printk(KERN_ERR "mga_vid: unable to get major: %d (devfs)\n", MGA_VID_MAJOR);
-		return -EIO;
+		printk(KERN_ERR "mga_vid: unable to get major: %d (devfs) => fallback to non-devfs mode\n", MGA_VID_MAJOR);
+//		return -EIO;
 	}
 #endif		
 	if(register_chrdev(MGA_VID_MAJOR, "mga_vid", &mga_vid_fops))
@@ -1594,7 +1594,7 @@
 	{
 		printk(KERN_ERR "mga_vid: no supported devices found\n");
 #ifdef CONFIG_DEVFS_FS
-		devfs_unregister(dev_handle);
+		if(dev_handle) devfs_unregister(dev_handle);
 #endif
 		unregister_chrdev(MGA_VID_MAJOR, "mga_vid");
 		return -EINVAL;
@@ -1626,7 +1626,7 @@
 	//FIXME turn off BES
 	printk(KERN_INFO "mga_vid: Cleaning up module\n");
 #ifdef CONFIG_DEVFS_FS
-	devfs_unregister(dev_handle);
+	if(dev_handle) devfs_unregister(dev_handle);
 #endif
 	unregister_chrdev(MGA_VID_MAJOR, "mga_vid");
 }




More information about the MPlayer-cvslog mailing list