lkml.org 
[lkml]   [2002]   [Jul]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] Fix drivers/media/video/videodev.c on !MODULE case
Currently videodev_proc_destroy() isn't always compiled in when used.
Right now it's compiled in based on MODULE && CONFIG_PROC_FS &&
CONFIG_VIDEO_PROC_FS. The two problems here the part of the file where
videodev_proc_destroy resides is already protected by CONFIG_PROC_FS &&
CONFIG_VIDEO_PROC_FS. The second problem is that
videodev_proc_destroy() isn't module specific, and is called on
CONFIG_PROC_FS && CONFIG_VIDEO_PROC_FS.

This removes the unnecessary tests and updates a comment as well to
reflect what's being tested.

--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/

===== drivers/media/video/videodev.c 1.13 vs edited =====
--- 1.13/drivers/media/video/videodev.c Wed Apr 3 17:05:11 2002
+++ edited/drivers/media/video/videodev.c Tue Jul 9 12:38:30 2002
@@ -288,8 +288,6 @@
video_dev_proc_entry->owner = THIS_MODULE;
}

-#ifdef MODULE
-#if defined(CONFIG_PROC_FS) && defined(CONFIG_VIDEO_PROC_FS)
static void videodev_proc_destroy(void)
{
if (video_dev_proc_entry != NULL)
@@ -298,8 +296,6 @@
if (video_proc_entry != NULL)
remove_proc_entry("video", &proc_root);
}
-#endif
-#endif

static void videodev_proc_create_dev (struct video_device *vfd, char *name)
{
@@ -344,7 +340,7 @@
}
}

-#endif /* CONFIG_VIDEO_PROC_FS */
+#endif /* CONFIG_VIDEO_PROC_FS && CONFIG_VIDEO_PROC_FS */

extern struct file_operations video_fops;

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:27    [W:0.068 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site