* [PATCH] remove devfs hack from misc_register
@ 2003-04-30 16:27 Christoph Hellwig
0 siblings, 0 replies; only message in thread
From: Christoph Hellwig @ 2003-04-30 16:27 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel
There's an (fortunately unused) devfs in misc_register currently,
when the name of the miscdevice contains a slash the name is used
as devfs name instead of misc/<name>. Kill if as we have .devfs_name
for this kind of stuff now.
--- 1.17/drivers/char/misc.c Sat Apr 19 11:56:45 2003
+++ edited/drivers/char/misc.c Wed Apr 30 18:01:16 2003
@@ -192,21 +192,12 @@
}
misc->minor = i;
}
+
if (misc->minor < DYNAMIC_MINORS)
misc_minors[misc->minor >> 3] |= 1 << (misc->minor & 7);
-
-
- /*
- * please use it if you want to do fancy things with your
- * name...
- */
if (misc->devfs_name[0] == '\0') {
- /* yuck, yet another stupid special-casing.
- whos actually using this? Please switch over
- to ->devfs_name ASAP */
snprintf(misc->devfs_name, sizeof(misc->devfs_name),
- strchr(misc->name, '/') ?
- "%s" : "misc/%s", misc->name);
+ "misc/%s", misc->name);
}
devfs_register(NULL, misc->devfs_name, 0, MISC_MAJOR, misc->minor,
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2003-04-30 16:15 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-30 16:27 [PATCH] remove devfs hack from misc_register Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®