aboutsummaryrefslogtreecommitdiff
path: root/sys/miscfs/devfs/devfs_vfsops.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove all traces of Julians DEVFS (incl from kern/subr_diskslice.c)Poul-Henning Kamp2000-08-201-313/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove old DEVFS support fields from dev_t. Make uid, gid & mode members of dev_t and set them in make_dev(). Use correct uid, gid & mode in make_dev in disk minilayer. Add support for registering alias names for a dev_t using the new function make_dev_alias(). These will show up as symlinks in DEVFS. Use makedev() rather than make_dev() for MFSs magic devices to prevent DEVFS from noticing this abuse. Add a field for DEVFS inode number in dev_t. Add new DEVFS in fs/devfs. Add devfs cloning to: disk minilayer (ie: ad(4), sd(4), cd(4) etc etc) md(4), tun(4), bpf(4), fd(4) If DEVFS add -d flag to /sbin/inits args to make it mount devfs. Add commented out DEVFS to GENERIC Notes: svn path=/head/; revision=64880
* Second pass commit to introduce new ACL and Extended Attribute systemRobert Watson1999-12-191-1/+3
| | | | | | | | | | calls, vnops, vfsops, both in /kern, and to individual file systems that require a vfsop_ array entry. Reviewed by: eivind Notes: svn path=/head/; revision=54803
* Lock reporting and assertion changes.Eivind Eklund1999-12-111-1/+1
| | | | | | | | | | | | | | | | | | * lockstatus() and VOP_ISLOCKED() gets a new process argument and a new return value: LK_EXCLOTHER, when the lock is held exclusively by another process. * The ASSERT_VOP_(UN)LOCKED family is extended to use what this gives them * Extend the vnode_if.src format to allow more exact specification than locked/unlocked. This commit should not do any semantic changes unless you are using DEBUG_VFS_LOCKS. Discussed with: grog, mch, peter, phk Reviewed by: peter Notes: svn path=/head/; revision=54444
* struct mountlist and struct mount.mnt_list have no business beingPoul-Henning Kamp1999-11-201-1/+1
| | | | | | | | | | | | | a CIRCLEQ. Change them to TAILQ_HEAD and TAILQ_ENTRY respectively. This removes ugly mp != (void*)&mountlist comparisons. Requested by: phk Submitted by: Jake Burkholder jake@checker.org PR: 14967 Notes: svn path=/head/; revision=53452
* Seperate the export check in VFS_FHTOVP, exports are now checked viaAlfred Perlstein1999-09-111-0/+1
| | | | | | | | | | | | VFS_CHECKEXP. Add fh(open|stat|stafs) syscalls to allow userland to query filesystems based on (network) filehandle. Obtained from: NetBSD Notes: svn path=/head/; revision=51138
* All unimplemented VFS ops now have entries in kern/vfs_default.c that returnAlfred Perlstein1999-09-071-48/+5
| | | | | | | | | | | | | | | | reasonable defaults. This avoids confusing and ugly casting to eopnotsupp or making dummy functions. Bogus casting of filesystem sysctls to eopnotsupp() have been removed. This should make *_vfsops.c more readable and reduce bloat. Reviewed by: msmith, eivind Approved by: phk Tested by: Jeroen Ruigrok/Asmodai <asmodai@wxs.nl> Notes: svn path=/head/; revision=51068
* $Id$ -> $FreeBSD$Peter Wemm1999-08-281-1/+1
| | | | Notes: svn path=/head/; revision=50477
* Fix warnings in preparation for adding -Wall -Wcast-qual to theMatthew Dillon1999-01-271-2/+2
| | | | | | | kernel compile Notes: svn path=/head/; revision=43305
* The "easy" fixes for compiling the kernel -Wunused: remove unreferenced staticArchie Cobbs1998-12-071-2/+3
| | | | | | | and local variables, goto labels, and functions declared but not defined. Notes: svn path=/head/; revision=41591
* Use TAILQ macros for clean/dirty block list processing. Set b_xflagsPeter Wemm1998-10-311-2/+2
| | | | | | | rather than abusing the list next pointer with a magic number. Notes: svn path=/head/; revision=40790
* Oops, don't assume that the environment is normal in devfs_mount().Bruce Evans1998-09-081-4/+6
| | | | | | | | It isn't for the hidden mountpoint. The static vfs's haven't been attached then, so mp->mnt_vfc can't be valid. Notes: svn path=/head/; revision=38951
* Removed statically configured mount type numbers (MOUNT_*) and allBruce Evans1998-09-071-6/+6
| | | | | | | | | | | | references to them. The change a couple of days ago to ignore these numbers in statically configured vfsconf structs was slightly premature because the cd9660, cfs, devfs, ext2fs, nfs vfs's still used MOUNT_* instead of the number in their vfsconf struct. Notes: svn path=/head/; revision=38909
* Use [u]intptr_t instead of [u_]long for casts between pointers andBruce Evans1998-08-161-3/+3
| | | | | | | integers. Don't forget to cast to (void *) as well. Notes: svn path=/head/; revision=38354
* As described by the submitter:Mike Smith1998-05-061-2/+1
| | | | | | | | | | | | | | | | Reverse the VFS_VRELE patch. Reference counting of vnodes does not need to be done per-fs. I noticed this while fixing vfs layering violations. Doing reference counting in generic code is also the preference cited by John Heidemann in recent discussions with him. The implementation of alternative vnode management per-fs is still a valid requirement for some filesystems but will be revisited sometime later, most likely using a different framework. Submitted by: Michael Hancock <michaelh@cet.co.jp> Notes: svn path=/head/; revision=35769
* Add changes and code to implement a functional DEVFS.Julian Elischer1998-04-191-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | This code will be turned on with the TWO options DEVFS and SLICE. (see LINT) Two labels PRE_DEVFS_SLICE and POST_DEVFS_SLICE will deliniate these changes. /dev will be automatically mounted by init (thanks phk) on bootup. See /sys/dev/slice/slice.4 for more info. All code should act the same without these options enabled. Mike Smith, Poul Henning Kamp, Soeren, and a few dozen others This code does not support the following: bad144 handling. Persistance. (My head is still hurting from the last time we discussed this) ATAPI flopies are not handled by the SLICE code yet. When this code is running, all major numbers are arbitrary and COULD be dynamically assigned. (this is not done, for POLA only) Minor numbers for disk slices ARE arbitray and dynamically assigned. Notes: svn path=/head/; revision=35319
* Seventy-odd "its" / "it's" typos in comments fixed as per kern/6108.Dag-Erling Smørgrav1998-04-171-2/+2
| | | | Notes: svn path=/head/; revision=35256
* The intent is to get rid of WILLRELE in vnode_if.src by makingMike Smith1998-03-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a complement to all ops that return a vpp, VFS_VRELE. This is initially only for file systems that implement the following ops that do a WILLRELE: vop_create, vop_whiteout, vop_mknod, vop_remove, vop_link, vop_rename, vop_mkdir, vop_rmdir, vop_symlink This is initial DNA that doesn't do anything yet. VFS_VRELE is implemented but not called. A default vfs_vrele was created for fs implementations that use the standard vnode management routines. VFS_VRELE implementations were made for the following file systems: Standard (vfs_vrele) ffs mfs nfs msdosfs devfs ext2fs Custom union umapfs Just EOPNOTSUPP fdesc procfs kernfs portal cd9660 These implementations may change as VOP changes are implemented. In the next phase, in the vop implementations calls to vrele and the vrele part of vput will be moved to the top layer vfs_vnops and made visible to all layers. vput will be replaced by unlock in these cases. Unlocking will still be done in the per fs layer but the refcount decrement will be triggered at the top because it doesn't hurt to hold a vnode reference a little longer. This will have minimal impact on the structure of the existing code. This will only be done for vnode arguments that are released by the various fs vop implementations. Wider use of VFS_VRELE will likely require restructuring of the code. Reviewed by: phk, dyson, terry et. al. Submitted by: Michael Hancock <michaelh@cet.co.jp> Notes: svn path=/head/; revision=33964
* add copyrightsJulian Elischer1998-01-021-4/+25
| | | | Notes: svn path=/head/; revision=32176
* remove forgotten debug printf()Julian Elischer1997-10-161-2/+1
| | | | Notes: svn path=/head/; revision=30470
* 1/ by default make all versions of the same device get the same vnode.Julian Elischer1997-10-161-4/+3
| | | | | | | | 2/ Show the dummy mount in the mount list. it cannot be reached (that I know of) but puting it there, means that disks mounted from devfs will have their things such as the superblock and the bitmaps, synced to disk :) Notes: svn path=/head/; revision=30464
* some cleanups of init code, and changes needed to support disk layering.Julian Elischer1997-10-161-61/+73
| | | | Notes: svn path=/head/; revision=30463
* Last major round (Unless Bruce thinks of somthing :-) of malloc changes.Poul-Henning Kamp1997-10-121-2/+2
| | | | | | | | | | | Distribute all but the most fundamental malloc types. This time I also remembered the trick to making things static: Put "static" in front of them. A couple of finer points by: bde Notes: svn path=/head/; revision=30354
* Distribute and statizice a lot of the malloc M_* types.Poul-Henning Kamp1997-10-111-1/+3
| | | | | | | Substantial input from: bde Notes: svn path=/head/; revision=30309
* Fix all areas of the system (or at least all those in LINT) to avoid storingGarrett Wollman1997-08-161-2/+2
| | | | | | | | | | | socket addresses in mbufs. (Socket buffers are the one exception.) A number of kernel APIs needed to get fixed in order to make this happen. Also, fix three protocol families which kept PCBs in mbufs to not malloc them instead. Delete some old compatibility cruft while we're at it, and add some new routines in the in_cksum family. Notes: svn path=/head/; revision=28270
* Removed unused #includes.Bruce Evans1997-08-021-7/+1
| | | | Notes: svn path=/head/; revision=27845
* remove annoying debug messageJulian Elischer1997-07-141-2/+1
| | | | Notes: svn path=/head/; revision=27387
* Fix the umount problems for DEVFS.Joerg Wunsch1997-05-031-3/+10
| | | | | | | | PR: 3276 & 3469 (the fixes), 2738, 2033 (reports) Submitted by: Dmitrij Tejblum <dima@tejblum.dnttm.rssi.ru> Notes: svn path=/head/; revision=25436
* Make this compile again after the Lite2 merge.Mike Pritchard1997-02-121-5/+5
| | | | | | | | | | | Call vget/VOP_UNLOCK with the correct number of arguments. Call vn_lock where appropriate. vfs_goneall is now replaced by VOP_REVOKE. Submitted by: bde Notes: svn path=/head/; revision=22599
* changes to make devfs more 'normal'Julian Elischer1996-11-211-2/+56
| | | | | | | | | | | | | | | | | also fixes a bug I've been chasing for a LONG TIME, due to the fact that spec_bwrite is a NOP and I didn't realise it.. old symptom: mount -t devfs devfs /mnt mount /mnt/wd0e /mnt/mnt2 umount /mnt2 <process hangs> there are some pretty large structural differences internal to devfs but outwards it should look the same. I have not yet tested extensively but will do so and fix 3 warnings tomorrow. Notes: svn path=/head/; revision=19909
* Updated #includes to 4.4Lite style.Bruce Evans1996-09-101-13/+15
| | | | Notes: svn path=/head/; revision=18207
* Cosmetic change: make the ``ready to run'' line match theGary Palmer1996-06-151-2/+2
| | | | | | | | ``ready for devices'' printed out earlier by changing `devs ' to be `DEVFS: ' Notes: svn path=/head/; revision=16397
* Clean up -Wunused warnings. Julian asked me to just ifdefGary Palmer1996-06-121-5/+3
| | | | | | | | | out unused code as this is still work in progress. Reviewed by: bde Notes: svn path=/head/; revision=16321
* Fix the reproto.sh script that was broken after my KNFification.Joerg Wunsch1996-04-071-2/+3
| | | | | | | Pointed out by: bde Notes: svn path=/head/; revision=15083
* KNFify the function definitions. It's harder to grep around when theJoerg Wunsch1996-04-061-4/+8
| | | | | | | function names don't start in column 1. Notes: svn path=/head/; revision=15080
* Remove unnecessary debug printf's ("no references", "bad-id") - thesePeter Wemm1996-01-021-1/+10
| | | | | | | | | | | | were development aids :-) and normal events. Initialise the "hidden" blueprint mount "mnt_op" and "mnt_vfc" fields so that a statfs() on a devfs file would not panic anymore. Fixes PR#911. Head-scratching by: Julian and Peter Notes: svn path=/head/; revision=13164
* Restored lost prototypes.Bruce Evans1995-12-141-1/+2
| | | | Notes: svn path=/head/; revision=12832
* Another mega commit to staticize things.Poul-Henning Kamp1995-12-141-13/+25
| | | | Notes: svn path=/head/; revision=12820
* more cleanups.. lots of code shuffled around tooJulian Elischer1995-09-071-2/+2
| | | | | | | | routines renamed.. more simplifications, some warnings squashed. Notes: svn path=/head/; revision=10598
* more devfs cleanups..Julian Elischer1995-09-061-6/+9
| | | | | | | if this keeps simplifying there won't be any left :) Notes: svn path=/head/; revision=10582
* devfs changes..Julian Elischer1995-09-031-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | changes to allow devices that don't probe (e.g. /dev/mem) to create devfs entries this required giving 'configure' its own SYSINIT entry so we could duck in just before it with a DEVFS init and some device inits.. my devfs now looks like: ./misc ./misc/speaker ./misc/mem ./misc/kmem ./misc/null ./misc/zero ./misc/io ./misc/console ./misc/pcaudio ./misc/pcaudioctl ./disks ./disks/rfloppy ./disks/rfloppy/fd0.1440 ./disks/rfloppy/fd1.1200 ./disks/floppy ./disks/floppy/fd0.1440 ./disks/floppy/fd1.1200 also some sligt cleanups.. DEVFS needs a lot of work but I'm getting back to it.. Notes: svn path=/head/; revision=10537
* Remove trailing whitespace.Rodney W. Grimes1995-05-301-2/+2
| | | | Notes: svn path=/head/; revision=8876
* Reviewed by: no-one yet, but nonintrusive until configed in.. :)Julian Elischer1995-04-201-0/+234
Submitted by: julian@freebsd.org Obtained from: written from scratch Notes: svn path=/head/; revision=7946