summaryrefslogtreecommitdiffstats
path: root/sys/ufs
Commit message (Collapse)AuthorAgeFilesLines
* Fixed lblktosize(). It overflowed at 2G. This bug only affectedbde1996-10-121-4/+7
| | | | | | | | | | | | | | | | | | ufs_read() and ufs_write(). Found by: looking at warnings for comparing the result of lblktosize() (which is usually daddr_t = long) with file sizes (which are u_quad_t for ufs). File sizes should probably be off_t's to avoid warnings when the are compared with file offsets, so the fixed lblktosize() casts to off_t instead of u_quad_t. Added definition of smalllblksize(). It is the same as the old lblksize() and is more efficient for small block numbers on 32-bit machines. Use smalllblktosize() instead of its expansion in blksize() and dblksize(). This keeps the line length short and makes it more obvious that the shift can't overflow.
* Don't include <sys/conf.h> for the kernel in disk-related headers.bde1996-09-201-1/+2
| | | | | | | | | | It is needed for implementation details but very little of it is needed for the interface. Include it in the few places that didn't already include it. Include <sys/ioccom.h> in <sys/disklabel.h> (as already in <sys/diskslice.h>) so that all the disk-related headers are almost self-sufficient.
* Whoops, I should've used the LINT config file. More ts -> tv changesnate1996-09-201-4/+4
| | | | for timespec structure.
* In sys/time.h, struct timespec is defined as:nate1996-09-193-16/+16
| | | | | | | | | | | | | | /* * Structure defined by POSIX.4 to be like a timeval. */ struct timespec { time_t ts_sec; /* seconds */ long ts_nsec; /* and nanoseconds */ }; The correct names of the fields are tv_sec and tv_nsec. Reminded by: James Drobina <jdrobina@infinet.com>
* Argh, I have had one "uid 0 on /: file system full" too many. The problempeter1996-09-171-2/+4
| | | | | | is that it doesn't say _what_ did it! (the core dumped console message is very useful for listing the process name and pid). This adds similar information.
* Fix a VOP_UNLOCK panic when using options DIAGNOSTIC during dismount.dyson1996-09-071-1/+3
|
* Use bowrite instead of VOP_BWRITE in a few cases. This can probably be takengibbs1996-09-061-5/+5
| | | | further.
* Eliminated nested include of <sys/unistd.h> in <sys/file.h> in the kernel.bde1996-09-031-2/+3
| | | | | | | Include it directly in the few places where it is used. Reduced some #includes of <sys/file.h> to #includes of <sys/fcntl.h> or nothing.
* Implemented kernel side of MNT_NOATIME mount option. This option disablesdg1996-09-031-2/+3
| | | | | | the file access time update on reads and can be useful in reducing filesystem overhead in cases where the access time is not important (like Usenet news spools).
* Don't depend in the kernel on the gcc feature of doing arithmetic onbde1996-08-311-2/+2
| | | | pointers of type `void *'. Warn about this in future.
* Even though this looks like it, this is not a complex code change.dyson1996-08-211-4/+16
| | | | | | | | | | | | | | | | | The interface into the "VMIO" system has changed to be more consistant and robust. Essentially, it is now no longer necessary to call vn_open to get merged VM/Buffer cache operation, and exceptional conditions such as merged operation of VBLK devices is simpler and more correct. This code corrects a potentially large set of problems including the problems with ktrace output and loaded systems, file create/deletes, etc. Most of the changes to NFS are cosmetic and name changes, eliminating a layer of subroutine calls. The direct calls to vput/vrele have been re-instituted for better cross platform compatibility. Reviewed by: davidg
* Don't use NULL in non-pointer contexts.bde1996-07-122-18/+18
|
* Quiet a couple of -Wunused warnings.wollman1996-07-092-4/+9
|
* Fixed end condition for clustered reads.dg1996-06-251-2/+2
| | | | Submitted by: Kirk McKusick via Lite-2 and email
* Clean up -Wunused warnings.gpalmer1996-06-121-1/+5
| | | | Reviewed by: bde
* Moved the fsnode MALLOC to before the call to getnewvnode() so that thedg1996-06-123-10/+34
| | | | | | | | process won't possibly block before filling in the fsnode pointer (v_data) which might be dereferenced during a sync since the vnode is put on the mnt_vnodelist by getnewvnode. Pointed out by Matt Day <mday@artisoft.com>
* Clean up various compiler warnings. Most (if not all) were benigngpalmer1996-05-082-4/+4
| | | | Reviewed by: bde
* disksort() is gone, all drivers now use tqdisksort().phk1996-05-031-72/+1
|
* removed:phk1996-05-021-2/+2
| | | | | | | | | CLBYTES PD_SHIFT PGSHIFT NBPG PGOFSET CLSIZELOG2 CLSIZE pdei() ptei() kvtopte() ptetov() ispt() ptetoav() &c &c new: NPDEPG Major macro cleanup.
* Removed bogus _BEGIN_DECLS/_END_DECLS.bde1996-05-014-43/+26
| | | | | | Removed unused struct tag declarations in cloned code. Added or cleaned up idempotency ifdefs.
* Yet more b_flags fixes. The previous ones broke the clearing of B_DONEbde1996-04-191-1/+5
| | | | | | | and B_READ before writing. This was was fatal. They also broke the clearing of B_INVAL before doing i/o. This didn't actually matter. Submitted by: mostly by joerg
* Replace usage of buf->b_actf by queue.3 and buf->b_actphk1996-04-083-19/+21
|
* Fixed reference counting related to relookup(). relookup() mustbde1996-03-291-3/+11
| | | | | | | | be called with the directory referenced, and this reference will be dropped iff relookup() fails, so the value returned must not be ignored. Reviewed by: davidg
* Make type compatible with Lite2.hsu1996-03-271-2/+2
| | | | Submitted by: bde
* Handle the bogus device that MFS uses as its VBLK device. We now don'tdyson1996-03-021-2/+8
| | | | | try to VMIO open it on MFS mounts. This will fix the mfs_badops panic.
* Enable VMIO for non-VDIR metadata and block device.dyson1996-03-021-4/+2
|
* More b_flags fixes.dyson1996-03-021-4/+4
|
* Fix a bug that b_flags was getting unnecessarily modified bydyson1996-03-011-3/+3
| | | | | the slice code. The effect up to now has been insignficant, but improved buffer allocation code will break with this problem.
* Add a prototype for the quotactl system call.mpp1996-02-271-1/+7
|
* Removed vestigial support for the obsolete FIFO option. In ext2fsbde1996-02-252-4/+3
| | | | | it caused null pointer panics for all fifo operations unless FIFO was defined.
* Fix a bunch of spelling errors in the comment fields ofmpp1996-01-302-5/+5
| | | | a bunch of system include files.
* Eliminated many redundant vm_map_lookup operations for vm_mmap.dyson1996-01-196-18/+22
| | | | | | | | | | | | | | | | | | | | | | | | | Speed up for vfs_bio -- addition of a routine bqrelse to greatly diminish overhead for merged cache. Efficiency improvement for vfs_cluster. It used to do alot of redundant calls to cluster_rbuild. Correct the ordering for vrele of .text and release of credentials. Use the selective tlb update for 486/586/P6. Numerous fixes to the size of objects allocated for files. Additionally, fixes in the various pagers. Fixes for proper positioning of vnode_pager_setsize in msdosfs and ext2fs. Fixes in the swap pager for exhausted resources. The pageout code will not as readily thrash. Change the page queue flags (PG_ACTIVE, PG_INACTIVE, PG_FREE, PG_CACHE) into page queue indices (PQ_ACTIVE, PQ_INACTIVE, PQ_FREE, PQ_CACHE), thereby improving efficiency of several routines. Eliminate even more unnecessary vm_page_protect operations. Significantly speed up process forks. Make vm_object_page_clean more efficient, thereby eliminating the pause that happens every 30seconds. Make sequential clustered writes B_ASYNC instead of B_DELWRI even in the case of filesystems mounted async. Fix a panic with busy pages when write clustering is done for non-VMIO buffers.
* Partially fixed negative and truncated "Avail" counts in df output.bde1996-01-141-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes PR943. ffs/ffs_vfsops.c: ffs_statfs() multiplied by (100 - minfree) as part of calculating the minfree percentage (complemented in 100%), so with the standard minfree of 8, it was broken for file systems of size >= 1TB/92 = 11GB. Use the standard freespace() macro instead. This also fixes a rounding bug (the "Avail" count was sometimes 1 too small). ffs/* (not fixed): The freespace() macro multiplies by minfree, so with the standard minfree of 8, it is broken for file systems of size >= 1TB/8 = 128GB. This bug is more serious since it affects block allocation. ffs/ffs_alloc.c (not fixed): Ordinary users are sometimes allowed to allocate 1 (partial) block too many so that the "Avail" count goes negative. E.g., if there is 1 fragment available and the file is fairly large, one more full block is allocated. df/df.c: ufs_df() used/uses essentially the same code as ffs_statfs(), so it had/has the same bugs. ufs_df() gratuitously replaced "Avail" counts of < 0 by 0, so it gave different results for non-mounted file systems in this case.
* The second cast wasn't needed.phk1996-01-071-2/+2
| | | | Submitted by: bde
* Fix the asami&phk bug. This was a sign-extension bug, where a longphk1996-01-061-2/+2
| | | | | | got multiplied by a constant before being upgraded to long long. This should fix kern/104 and possibly kern/105. Thanks to: dyson & asami.
* Convert QUOTA to new-style option.wollman1996-01-0510-10/+31
|
* Convert DDB to new-style option.wollman1996-01-041-1/+3
|
* recording cvs-1.6 file deathpeter1995-12-302-788/+0
|
* Fixed prototyping and staticizing for -DDEBUG case.bde1995-12-222-8/+8
|
* Staticize.phk1995-12-222-25/+25
|
* Staticize.phk1995-12-1715-317/+173
|
* Silence a harmless warning...peter1995-12-151-2/+3
|
* Included <sys/conf.h> and updated to indirect devswitches so thatbde1995-12-141-4/+6
| | | | this compiles again, and added a prototype.
* *hack alert*! :-) This adds an option to the MFS_ROOT code so that itpeter1995-12-141-1/+94
| | | | | | is possible to boot a kernel with an empty in-core MFS image, and have it load the image from floppy directly. This is admittedly a hack and would be better replaced by a self-loading ram-disk.
* Changes to support 1Tb filesizes. Pages are now named by andyson1995-12-114-41/+30
| | | | (object,index) pair instead of (object,offset) pair.
* Untangled the vm.h include file spaghetti.dg1995-12-076-6/+20
|
* Fixed compilation of lfs utilities which I broke the other day bybde1995-12-062-7/+15
| | | | #including lfs_extern.h and goop to support it in lfs_conv.c.
* Completed function declarations and/or added prototypes and/or #includesbde1995-12-035-17/+29
| | | | to get the prototypes.
* Removed bogus __BEGIN_DECS/__END_DECLS.bde1995-11-281-3/+1
|
* After having put on my Asbestos suit, complete the MFS_ROOT part of Terry'speter1995-11-281-26/+27
| | | | | mountroot changes. This means that the mfs_initminiroot functionality into the root mfs_mount....
OpenPOWER on IntegriCloud