if (nlkms == 0) lkminit();
lkmopen(dev_t dev, int flag, int devtype, struct proc *p){	int error;	if (minor(dev) != 0)		return (ENXIO);	/*	 * Use of the loadable kernel module device must be exclusive; we	 * may try to remove this restriction later, but it's really no	 * hardship.	 */	while (lkm_v & LKM_ALLOC) {		if (flag & FNONBLOCK)		/* don't hang */			return (EBUSY);		lkm_v |= LKM_WANT;		/*		 * Sleep pending unlock; we use tsleep() to allow		 * an alarm out of the open.		 */		error = tsleep(&lkm_v, TTIPRI|PCATCH, "lkmopn", 0);		if (error)			return (error);	/* leave LKM_WANT set -- no problem */	}	lkm_v |= LKM_ALLOC;	if (nlkms == 0)		lkminit();	/* XXX */	return (0);		/* pseudo-device open */}