devfs_devs.c (89118) | devfs_devs.c (100206) |
---|---|
1#define DEBUG 1 2/* 3 * Copyright (c) 2000 4 * Poul-Henning Kamp. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 12 unchanged lines hidden (view full) --- 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 * 27 * From: FreeBSD: src/sys/miscfs/kernfs/kernfs_vfsops.c 1.36 28 * | 1#define DEBUG 1 2/* 3 * Copyright (c) 2000 4 * Poul-Henning Kamp. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 12 unchanged lines hidden (view full) --- 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 * 27 * From: FreeBSD: src/sys/miscfs/kernfs/kernfs_vfsops.c 1.36 28 * |
29 * $FreeBSD: head/sys/fs/devfs/devfs_devs.c 89118 2002-01-09 04:58:49Z msmith $ | 29 * $FreeBSD: head/sys/fs/devfs/devfs_devs.c 100206 2002-07-17 01:46:48Z dd $ |
30 */ 31 32#include "opt_devfs.h" 33#ifndef NODEVFS 34 35#include <sys/param.h> 36#include <sys/systm.h> 37#include <sys/conf.h> --- 309 unchanged lines hidden (view full) --- 347 de->de_inode = i; 348 de->de_uid = dev->si_uid; 349 de->de_gid = dev->si_gid; 350 de->de_mode = dev->si_mode; 351 de->de_dirent->d_type = DT_CHR; 352 } 353 *dep = de; 354 de->de_dir = dd; | 30 */ 31 32#include "opt_devfs.h" 33#ifndef NODEVFS 34 35#include <sys/param.h> 36#include <sys/systm.h> 37#include <sys/conf.h> --- 309 unchanged lines hidden (view full) --- 347 de->de_inode = i; 348 de->de_uid = dev->si_uid; 349 de->de_gid = dev->si_gid; 350 de->de_mode = dev->si_mode; 351 de->de_dirent->d_type = DT_CHR; 352 } 353 *dep = de; 354 de->de_dir = dd; |
355 devfs_rules_apply(dm, de); |
|
355 TAILQ_INSERT_TAIL(&dd->de_dlist, de, de_list); 356#if 0 357 printf("Add ino%d %s\n", i, dev->si_name); 358#endif 359 } 360 } 361 lockmgr(&dm->dm_lock, LK_DOWNGRADE, 0, curthread); 362 return (0); --- 67 unchanged lines hidden (view full) --- 430} 431 432static void 433devfs_init(void *junk) 434{ 435 devfs_create_hook = devfs_create; 436 devfs_destroy_hook = devfs_destroy; 437 devfs_present = 1; | 356 TAILQ_INSERT_TAIL(&dd->de_dlist, de, de_list); 357#if 0 358 printf("Add ino%d %s\n", i, dev->si_name); 359#endif 360 } 361 } 362 lockmgr(&dm->dm_lock, LK_DOWNGRADE, 0, curthread); 363 return (0); --- 67 unchanged lines hidden (view full) --- 431} 432 433static void 434devfs_init(void *junk) 435{ 436 devfs_create_hook = devfs_create; 437 devfs_destroy_hook = devfs_destroy; 438 devfs_present = 1; |
439 devfs_rules_init(); |
|
438} 439 440SYSINIT(devfs, SI_SUB_DEVFS, SI_ORDER_FIRST, devfs_init, NULL); 441 442#endif | 440} 441 442SYSINIT(devfs, SI_SUB_DEVFS, SI_ORDER_FIRST, devfs_init, NULL); 443 444#endif |