From 891822a85329045b4e558f0ecdf5c0263529bfb2 Mon Sep 17 00:00:00 2001 From: Poul-Henning Kamp Date: Fri, 24 Sep 2004 08:32:36 +0000 Subject: [PATCH] XXX mark two places where we do not hold a threadcount on the dev when frobbing the cdevsw. In both cases we examine only the cdevsw and it is a good question if we weren't better off copying those properties into the cdev in the first place. This question will be revisited. --- sys/fs/devfs/devfs_rule.c | 2 ++ sys/vm/vm_mmap.c | 1 + 2 files changed, 3 insertions(+) diff --git a/sys/fs/devfs/devfs_rule.c b/sys/fs/devfs/devfs_rule.c index b73ac7729e5b..52dc013f10a5 100644 --- a/sys/fs/devfs/devfs_rule.c +++ b/sys/fs/devfs/devfs_rule.c @@ -604,6 +604,8 @@ devfs_rule_match(struct devfs_krule *dk, struct devfs_dirent *de) * They're actually testing to see whether the condition does * *not* match, since the default is to assume the rule should * be run (such as if there are no conditions). + * + * XXX: lacks threadref on dev */ if (dr->dr_icond & DRC_DSWFLAGS) if (dev == NULL || diff --git a/sys/vm/vm_mmap.c b/sys/vm/vm_mmap.c index a4a46500553e..6801bc276260 100644 --- a/sys/vm/vm_mmap.c +++ b/sys/vm/vm_mmap.c @@ -1094,6 +1094,7 @@ vm_mmap_vnode(struct thread *td, vm_size_t objsize, type = OBJT_DEVICE; handle = vp->v_rdev; + /* XXX: lack thredref on device */ if(vp->v_rdev->si_devsw->d_flags & D_MMAP_ANON) { *maxprotp = VM_PROT_ALL; *flagsp |= MAP_ANON;