summaryrefslogtreecommitdiffstats
path: root/sys/fs
Commit message (Collapse)AuthorAgeFilesLines
...
* Track nfs's getpages() changes:bp2002-04-231-12/+46
| | | | | | Properly count v_vnodepgsin. Do not reread page if is already valid. Properly handle partially filled pages.
* Get rid from extra #ifdefs.bp2002-04-232-79/+4
|
* Don't attempt to decvlare M_DEVFS whern MALLOC_DECLARE is not defined.bde2002-04-211-3/+6
| | | | | | | | This fixes warnings that should be errors in fstat. Reminded by: alpha tinderbox Fixed some style bugs (ones near BOF and EOF; there are many more).
* Include <sys/systm.h> for (at least) the definition of atomic functionsbde2002-04-211-0/+1
| | | | | which are sometimes used by the macros in <sys/mutex.h>; don't depend on not-quite-necessary namespace pollution in <sys/mutex.h>.
* Don't put a line break in string literals. GCC 3.1 complains and GCCmarcel2002-04-201-13/+10
| | | | 3.2 drops the ball.
* Spelling fix for comment.rwatson2002-04-201-1/+1
|
* Cleanup of logic, flow and comments.alfred2002-04-181-20/+18
| | | | Submitted by: bde
* Lock proctree_lock instead of pgrpsess_lock.jhb2002-04-162-4/+4
|
* Sync with UDF p4 tree: Use POSIX integer types instead of BSD types.asmodai2002-04-154-159/+159
|
* Actually add the UDF files!scottl2002-04-147-0/+2986
|
* Remove stale XXX comment.jhb2002-04-141-1/+0
|
* - Change procfs_control()'s first argument to be a thread pointer insteadjhb2002-04-131-47/+32
| | | | | | | | | | | of a process pointer. - Move the p_candebug() at the start of procfs_control() a bit to make locking feasible. We still perform the access check before doing anything, we just now perform it after acquiring locks. - Don't lock the sched_lock for TRACE_WAIT_P() and when checking to see if p_stat is SSTOP. We lock the process while setting p_stat to SSTOP so locking the process is sufficient to do a read to see if p_stat is SSTOP or not.
* Lock the target process for p_candebug().jhb2002-04-131-3/+4
|
* Lock the target process in procfs_doproc*regs() for p_candebug and whilejhb2002-04-133-9/+23
| | | | reading/writing the registers.
* - p_cansee() needs the target process locked.jhb2002-04-131-18/+17
| | | | - We need the proc lock held for more of procfs_doprocstatus().
* Check write permissions before creating anything.bp2002-04-131-0/+3
| | | | | PR: kern/27883 MFC after: 1 week
* Remove 3 instances of vm_zone.h inclusion.phk2002-04-083-3/+0
|
* Change the vm_zone calls over to uma calls. Remove the reference to thejeff2002-04-081-9/+9
| | | | vm_zone header.
* Fixed assorted bugs in setting of timestamps in devfs_setattr().bde2002-04-051-21/+24
| | | | | | | | | | | | Setting of timestamps on devices had no effect visible to userland because timestamps for devices were set in places that are never used. This broke: - update of file change time after a change of an attribute - setting of file access and modification times. The VA_UTIMES_NULL case did not work. Revs 1.31-1.32 were supposed to fix this by copying correct bits from ufs, but had little or no effect because the old checks were not removed.
* Fixed a very old bug in setting timestamps using utimes(2) on msdosfsbde2002-04-051-4/+11
| | | | | | | | | | | | | | | files. We didn't clear the update marks when we set the times, so some of the settings were sometimes clobbered with the current time a little later. This caused cp -p even by root to almost always fail to preserve any times despite not reporting any errors in attempting to preserve them. Don't forget to set the archive attribute when we set the read-only attribute. We should only set the archive attribute if we actually change something, but we mostly don't bother avoiding setting it elsewhere, so don't bother here yet. MFC after: 1 week
* Change callers of mtx_init() to pass in an appropriate lock type name. Injhb2002-04-049-9/+10
| | | | | | | most cases NULL is passed, but in some cases such as network driver locks (which use the MTX_NETWORK_LOCK macro) and UMA zone locks, a name is used. Tested on: i386, alpha, sparc64
* Moved signal handling and rescheduling from userret() to ast() so thatbde2002-04-041-0/+1
| | | | | | | | | | | they aren't in the usual path of execution for syscalls and traps. The main complication for this is that we have to set flags to control ast() everywhere that changes the signal mask. Avoid locking in userret() in most of the remaining cases. Submitted by: luoqi (first part only, long ago, reorganized by me) Reminded by: dillon
* Change the suser() API to take advantage of td_ucred as well as do ajhb2002-04-017-17/+16
| | | | | | | | | | | | general cleanup of the API. The entire API now consists of two functions similar to the pre-KSE API. The suser() function takes a thread pointer as its only argument. The td_ucred member of this thread must be valid so the only valid thread pointers are curthread and a few kernel threads such as thread0. The suser_cred() function takes a pointer to a struct ucred as its first argument and an integer flag as its second argument. The flag is currently only used for the PRISON_ROOT flag. Discussed on: smp@
* In ffs_mountffs(), set mnt_iosize_max to si_iosize_max unconditionallybde2002-03-301-0/+4
| | | | | | | | | | | | | | | | provided the latter is nonzero. At this point, the former is a fairly arbitrary default value (DFTPHYS), so changing it to any reasonable value specified by the device driver is safe. Using the maximum of these limits broke ffs clustered i/o for devices whose si_iosize_max is < DFLTPHYS. Using the minimum would break device drivers' ability to increase the active limit from DFTLPHYS up to MAXPHYS. Copied the code for this and the associated (unnecessary?) fixup of mp_iosize_max to all other filesystems that use clustering (ext2fs and msdosfs). It was completely missing. PR: 36309 MFC-after: 1 week
* Protect proc struct (p_args and p_comm) when doing procfs IO that pullsalfred2002-03-291-11/+17
| | | | | | data from it. Submitted by: Jonathan Mini <mini@haikugeek.com>
* Fixed some style bugs in the removal of __P(()). Continuation linesbde2002-03-243-8/+7
| | | | | were not outdented to preserve non-KNF lining up of code with parentheses. Switch to KNF formatting in some cases.
* Fixed some style bugs in the removal of __P(()). Continuation linesbde2002-03-232-14/+14
| | | | | were not outdented to preserve non-KNF lining up of code with parentheses. Switch to KNF formatting.
* Remove references to vm_zone.h and switch over to the new uma API.jeff2002-03-201-4/+4
|
* Remove __P.alfred2002-03-207-92/+82
|
* Remove __P.alfred2002-03-203-35/+35
|
* Remove __P.alfred2002-03-1937-423/+417
|
* Cannot release vnode underlying the nullfs vnode in null_inactivemckusick2002-03-181-19/+26
| | | | | | | | | | as it leaves the nullfs vnode allocated, but with no identity. The effect is that a null mount can slowly accumulate all the vnodes in the system, reclaiming them only when it is unmounted. Thus the null_inactive state instead accelerates the release of the null vnode by calling vrecycle which will in turn call the null_reclaim operator. The null_reclaim routine then does the freeing actions previosuly (incorrectly) done in null_inactive.
* Add a flags parameter to VFS_VGET to pass through the desiredmckusick2002-03-1717-62/+110
| | | | | | | | | | | | locking flags when acquiring a vnode. The immediate purpose is to allow polling lock requests (LK_NOWAIT) needed by soft updates to avoid deadlock when enlisting other processes to help with the background cleanup. For the future it will allow the use of shared locks for read access to vnodes. This change touches a lot of files as it affects most filesystems within the system. It has been well tested on FFS, loopback, and CD-ROM filesystems. only lightly on the others, so if you find a problem there, please let me (mckusick@mckusick.com) know.
* Introduce the new 64-bit size disk block, daddr64_t. Changemckusick2002-03-154-11/+25
| | | | | | | | | | | | the bio and buffer structures to have daddr64_t bio_pblkno, b_blkno, and b_lblkno fields which allows access to disks larger than a Terabyte in size. This change also requires that the VOP_BMAP vnode operation accept and return daddr64_t blocks. This delta should not affect system operation in any way. It merely sets up the necessary interfaces to allow the development of disk drivers that work with these larger disk block addresses. It also allows for the development of UFS2 which will use 64-bit block addresses.
* Be consistent with UFS in a way how devfs_setattr() checks credentialsmaxim2002-03-141-4/+5
| | | | | | | | for chmod(2), chown(2) and utimes(2) with respect to jail(2). Reviewed by: rwatson, ru Not objected by: phk Approved by: ru
* If in strategy we find that we have no devsw on the device anymore wephk2002-03-051-3/+6
| | | | | are probably talking about some disk-device which wente away, so return ENXIO instead of panicing.
* Simple p_ucred -> td_ucred changes to start using the per-thread ucredjhb2002-02-2717-40/+39
| | | | reference.
* Fix LINT breakage by adding a missing include.tmm2002-02-231-0/+1
|
* Lock struct pgrp, session and sigio.tanimura2002-02-234-8/+21
| | | | | | | | | | | | | | | | | | | | | | | | | New locks are: - pgrpsess_lock which locks the whole pgrps and sessions, - pg_mtx which protects the pgrp members, and - s_mtx which protects the session members. Please refer to sys/proc.h for the coverage of these locks. Changes on the pgrp/session interface: - pgfind() needs the pgrpsess_lock held. - The caller of enterpgrp() is responsible to allocate a new pgrp and session. - Call enterthispgrp() in order to enter an existing pgrp. - pgsignal() requires a pgrp lock held. Reviewed by: jhb, alfred Tested on: cvsup.jp.FreeBSD.org (which is a quad-CPU machine running -current)
* Paranoia: if the process is setugid, set all sensitive files mode 0.des2002-02-181-1/+3
|
* Don't even think about using v_id for magic tricks, v_id is givingphk2002-02-171-5/+0
| | | | us enough trouble as it is for SMPng.
* FIxed the following style bugs:bde2002-02-162-10/+16
| | | | | | | | | | - clobbering of jsp's $Id$ by FreeBSD's old $Id$. - long lines in recent KSE changes (procfs_ctl.c). - other style bugs in KSE changes (most related to an shadowed variable in procfs_status.c -- the td in the outer scope is obfuscated by PFS_FILL_ARGS). Approved by: des
* FIxed the following style bugs:bde2002-02-163-11/+21
| | | | | | | - clobbering of jsp's $Id$ by FreeBSD's old $Id$. - lost Berkeley id in procfs_dbregs.c - long lines in recent KSE changes. - various gratuitous differences between procfs_*regs.c.
* Fixed missing PHOLD()/PRELE().bde2002-02-161-0/+2
| | | | | Obtained from: procfs_dbregs.c Approved by: des
* Various nit-picking, mostly of style(9) character.phk2002-02-101-43/+41
| | | | Obtained from: ~bde/sys.dif.gz
* Part I: Update extended attribute API and ABI:rwatson2002-02-102-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | o Modify the system call syntax for extattr_{get,set}_{fd,file}() so as not to use the scatter gather API (which appeared not to be used by any consumers, and be less portable), rather, accepts 'data' and 'nbytes' in the style of other simple read/write interfaces. This changes the API and ABI. o Modify system call semantics so that extattr_get_{fd,file}() return a size_t. When performing a read, the number of bytes read will be returned, unless the data pointer is NULL, in which case the number of bytes of data are returned. This changes the API only. o Modify the VOP_GETEXTATTR() vnode operation to accept a *size_t argument so as to return the size, if desirable. If set to NULL, the size will not be returned. o Update various filesystems (pseodofs, ufs) to DTRT. These changes should make extended attributes more useful and more portable. More commits to rebuild the system call files, as well as update userland utilities to follow. Obtained from: TrustedBSD Project Sponsored by: DARPA, NAI Labs
* Pre-KSE/M3 commit.julian2002-02-076-14/+19
| | | | | | | | | | this is a low-functionality change that changes the kernel to access the main thread of a process via the linked list of threads rather than assuming that it is embedded in the process. It IS still embeded there but remove all teh code that assumes that in preparation for the next commit which will actually move it out. Reviewed by: peter@freebsd.org, gallatin@cs.duke.edu, benno rice,
* Change EPERM to EOPNOTSUPP when failing pseudofs_setattr() arbitrarily.rwatson2002-02-041-4/+2
| | | | Quoth the alfred: The latter would be better.
* Return EPERM instead of 0 in the un-implemented pseudofs_setattr().rwatson2002-02-041-2/+1
| | | | Conceivably, it should even return EOPNOTSUPP.
* Fix select on fifos.alfred2002-01-141-11/+29
| | | | | | | | | | | | | Backout revision 1.56 and 1.57 of fifo_vnops.c. Introduce a new poll op "POLLINIGNEOF" that can be used to ignore EOF on a fifo, POLLIN/POLLRDNORM is converted to POLLINIGNEOF within the FIFO implementation to effect the correct behavior. This should allow one to view a fifo pretty much as a data source rather than worry about connections coming and going. Reviewed by: bde
OpenPOWER on IntegriCloud