diff options
author | jh <jh@FreeBSD.org> | 2010-04-16 07:02:28 +0000 |
---|---|---|
committer | jh <jh@FreeBSD.org> | 2010-04-16 07:02:28 +0000 |
commit | 0cfb62fa2abac760cac45dcc887b8d8eb42d83f2 (patch) | |
tree | 41162f268e94a4704dbeb6b53aa1504ac38d1b00 /sys/fs/devfs/devfs_devs.c | |
parent | 1181490d6c335d7f89bb15d882bc234f3ea443bd (diff) | |
download | FreeBSD-src-0cfb62fa2abac760cac45dcc887b8d8eb42d83f2.zip FreeBSD-src-0cfb62fa2abac760cac45dcc887b8d8eb42d83f2.tar.gz |
Revert r206560. The change doesn't work correctly in all cases with
multiple devfs mounts.
Diffstat (limited to 'sys/fs/devfs/devfs_devs.c')
-rw-r--r-- | sys/fs/devfs/devfs_devs.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/sys/fs/devfs/devfs_devs.c b/sys/fs/devfs/devfs_devs.c index 79037ba..81b2752 100644 --- a/sys/fs/devfs/devfs_devs.c +++ b/sys/fs/devfs/devfs_devs.c @@ -408,9 +408,6 @@ devfs_populate_loop(struct devfs_mount *dm, int cleanup) continue; KASSERT((cdp->cdp_flags & CDP_ACTIVE), ("Bogons, I tell ya'!")); - if (cdp->cdp_flags & CDP_INVALID) - continue; - if (dm->dm_idx <= cdp->cdp_maxdirent && cdp->cdp_dirents[dm->dm_idx] != NULL) { de = cdp->cdp_dirents[dm->dm_idx]; @@ -428,8 +425,6 @@ devfs_populate_loop(struct devfs_mount *dm, int cleanup) dd = dm->dm_rootdir; s = cdp->cdp_c.si_name; for (;;) { - while (*s == '/') - s++; for (q = s; *q != '/' && *q != '\0'; q++) continue; if (*q != '/') @@ -439,24 +434,6 @@ devfs_populate_loop(struct devfs_mount *dm, int cleanup) de = devfs_vmkdir(dm, s, q - s, dd, 0); s = q + 1; dd = de; - if (dd->de_flags & (DE_DOT | DE_DOTDOT)) - break; - } - - /* - * XXX: Ignore duplicate and empty device names. - * XXX: Currently there is no way to report the error to - * XXX: the make_dev(9) caller. - */ - if (dd->de_dirent->d_type != DT_DIR || - dd->de_flags & (DE_DOT | DE_DOTDOT) || q - s < 1 || - devfs_find(dd, s, q - s) != NULL) { - dev_lock(); - cdp->cdp_flags |= CDP_INVALID; - dev_unlock(); - printf("%s: %s: invalid or duplicate device name\n", - __func__, cdp->cdp_c.si_name); - return (1); } de = devfs_newdirent(s, q - s); |