mycroft
fad85a24d8
On a RW->RO transition, explicitly clear fs_fmod after the cgupdate/sbupdate,
...
to prevent spurious writebacks and whinging about the (correct!) clean flag.
(Why this isn't done in ffs_sbupdate(), I dunno...)
2001-01-10 17:49:18 +00:00
ad
d8735dd13a
RCS ID
2001-01-10 16:45:56 +00:00
chs
bc21905f3c
attach the softdep pagecache pseudo-buffers to the inode
...
so we can find them quickly in the softdep truncate path.
2001-01-10 04:47:10 +00:00
mycroft
7f2aa054f1
ffs_reload(): Copy fs_ronly into the new superblock, too, as it may have been
...
modified on disk (e.g. by fsck(8)). This flag should really be elsewhere.
2001-01-09 10:44:19 +00:00
matt
ad346bb9eb
Convert a MALLOC with a variable size to malloc(). Saves 220 bytes of text
...
on VAX.
2001-01-01 05:17:26 +00:00
enami
95a1bfa14c
- 16 * 8 != 168
...
- offset should be endian independent.
2000-12-23 14:42:06 +00:00
enami
0e4a3d44c0
Cosmetic changes
2000-12-23 14:09:52 +00:00
mycroft
61a6479ab1
Patch from Kirk McKusick to fix an ordering problem in softdep_setup_freeblks()
...
that could cause an inode to be reused prematurely (possibly resulting in the
file containing garbage blocks).
2000-12-13 20:07:32 +00:00
chs
e6e27e9efc
fix bookkeeping for page cache dependency buffers.
2000-12-13 15:32:31 +00:00
chs
bb61d9c5e4
in flush_inodedep_deps(), drop the big softdep lock while flushing pages.
2000-12-11 03:53:54 +00:00
chs
4ab33e73c2
call pgo_flush with (start,end) rather than (start,length).
2000-12-10 19:41:35 +00:00
chs
4912461b20
in ffs_sync(), don't skip vnodes which have (potentially dirty) pages.
2000-12-04 09:37:06 +00:00
fvdl
7c2b9d8515
In addition to setting the softdep flag in the superblock when
...
mounting with softdeps, also explicitly clear it when we don't,
so that a leftover setting after a crash will be cleared.
2000-12-03 19:52:06 +00:00
nathanw
aa215181ce
Don't set the value of doreallocblks here; it's defined over in vfs_cluster.c
...
In fact, doreallocblks isn't used here at all. Delete the declaration.
2000-11-30 20:56:10 +00:00
jdolecek
861369604d
change vfs.ffs.doreallocblks to 1 by default - this does not have
...
aby bad symptoms any more, fix for bug causing problems with this
option was in BSD4.4-Lite2 and pulled in together with softdep changes
See also Keith Smith & Margo Seltzer's paper on the topic at
http://www.eecs.harvard.edu/~keith/papers/realloc.ps.gz
2000-11-30 19:46:02 +00:00
chs
e9037d16c5
allow building without SOFTDEP by adding the pageiodone hook to bio_ops.
2000-11-27 18:26:38 +00:00
chs
aeda8d3b77
Initial integration of the Unified Buffer Cache project.
2000-11-27 08:39:39 +00:00
ad
642267bcc7
Update for hashinit() change.
2000-11-08 14:28:12 +00:00
fvdl
ef6bdbccd8
Stay at splbio across the VBWAIT loop, as is done elsewhere in the
...
kernel. Avoids a possible race condition. Pointed out by
enami@netbsd.org , problem reported by deberg@netbsd.org .
2000-10-24 14:43:32 +00:00
simonb
7bf589b1ae
There is no need to explicitly include <uvm/uvm_extern.h> for
...
<sys/sysctl.h> anymore.
2000-10-13 16:40:26 +00:00
fvdl
81ba8e7ff7
Adapt for VOP_FSYNC parameter change.
...
Implement range fsync for FFS. Note: not yet implemented for the
SOFTDEP case.
2000-09-19 22:04:08 +00:00
fvdl
ce4bcf47f3
Do not call MALLOC with M_WAITOK while holding the "lock". Thanks to
...
Ethan Solomita for the reminder.
Mark the parent vnode lock as recursive while flushing pagedeps. XXX.
Should fix kern/10564.
2000-08-15 14:25:08 +00:00
mrg
419501093a
remove include of <vm/vm.h> and <uvm/uvm_extern.h>
2000-06-28 14:16:37 +00:00
mrg
91cc436b9e
<vm/vm.h> -> <uvm/uvm_extern.h>
2000-06-28 14:11:33 +00:00
fvdl
d09958adad
Due to popular demand, change vinsheadfree to ungetnewvnode to make
...
the name clearer. No functional change.
2000-06-27 23:51:22 +00:00
fvdl
bba2403203
In ffs_vget, do not hold ufs_haslock across the call to getnewvnode.
...
We may sleep in it, or even recurse, with softdeps. Instead, grab
the lock later, but check if noone else has beaten us to the VFS_VGET
operation, and if so, roll back getnewvnode using vinsheadfree, and
just return.
2000-06-27 23:39:17 +00:00
pk
88b0328aca
We shouldn't be defining DEBUG and DIAGNOSTIC on our own; these may have
...
unwanted side-effects in the header files. For now, do the internal
#defines after including the headers.
2000-06-27 16:46:54 +00:00
fvdl
45b3f2405a
Moved here from gnu/sys/ufs/ffs
2000-06-22 16:13:41 +00:00
fvdl
77b2bcbe07
Copyright changed.
2000-06-22 15:23:05 +00:00
perseant
da29133e76
make it compile (fix typo)
2000-06-16 05:45:14 +00:00
matt
1b5bc7ce61
ignore the softdep flags when mounting and there's no softdep in the kernel.
2000-06-16 00:30:15 +00:00
fvdl
4f11634756
Allow MNT_SOFTDEP to be passed in via the mount(2) system call, do not
...
require it to be set via tunefs(8). Silently ignore it when doing
an update mount of a writeable filesystem, the FFS/softdep code isn't ready
for this yet.
2000-06-15 22:35:37 +00:00
mycroft
64f5a574a7
In ffs_update():
...
* Move the clearing of IN_MODIFIED and IN_ACCESSED later, so they are not
cleared if the bread() failed.
* Explicitly set waitfor to 0 in the softdep case, if IN_MODIFIED is not
set (mirroring the bwrite()/bdwrite() decision).
2000-05-30 17:23:52 +00:00
mycroft
4db674fa50
According to Frank, buffers with dependencies *are* left on v_dirtyblks, so
...
remove the FSYNC_RECLAIM check and force them to be flushed.
2000-05-29 18:53:35 +00:00
mycroft
edfd1e6f32
Use LIST_{FIRST,NEXT,EMPTY}().
2000-05-29 18:28:48 +00:00
mycroft
d747ada9c2
Add a new inode flags called IN_ACCESSED. This used in place of IN_MODIFIED
...
to record that the atime was updated. In ffs_update(), we only do synchronous
writes if something *other* than the atime was changed.
2000-05-29 18:04:30 +00:00
mycroft
941524439a
Never call softdep_sync_metadata() in the FSYNC_RECLAIM case. Any pending
...
blocks are detached from the vnode at this point. When the dependencies are
broken to enable writing the blocks, the vnode will be regenerated. (The only
reason we sync buffers in this case is that they have to be detached from the
vnode.)
2000-05-29 17:19:20 +00:00
mycroft
c47adf55e0
In ffs_fsync(), remove the FSYNC_RECLAIM special case, so that it properly
...
waits for pending buffers, and doesn't throw away time stamp updates.
2000-05-29 17:12:06 +00:00
mycroft
ccf1cf4b69
MNT_WAIT -> FSYNC_WAIT
2000-05-29 16:28:27 +00:00
mycroft
1ea529f6df
DTRT when unwinding multiple levels.
2000-05-28 08:31:41 +00:00
mycroft
4fc7b946c2
When unwinding a failed allocation, make sure to nuke the unwound block from
...
the vnode's block list. This fixes `itrunc3' panics (at least in some cases;
further testing is needed) and prevents further lossage later on.
2000-05-28 08:15:40 +00:00
mycroft
4656dfd24f
Add a new function to remove extra buffers when truncating a file. This is
...
more generic than the vinvalbuf(V_SAVEMETA) case, avoiding synchronous
operations when truncating to a non-zero length.
2000-05-28 04:13:56 +00:00
thorpej
21fc65e1a8
sleep() -> tsleep()
2000-05-27 04:52:27 +00:00
thorpej
f636538446
NULL != 0
2000-05-19 04:34:39 +00:00
bouyer
1900598507
Sync copyrigth notice.
2000-05-15 08:51:55 +00:00
perseant
f0728fdce1
Change the sementics of the last parameter from a boolean ("waitfor") to
...
a set of flags ("flags"). Two flags are defined, UPDATE_WAIT and
UPDATE_DIROP.
Under the old semantics, VOP_UPDATE would block if waitfor were set,
under the assumption that directory operations should be done
synchronously. At least LFS and FFS+softdep do not make this
assumption; FFS+softdep got around the problem by enclosing all relevant
calls to VOP_UPDATE in a "if(!DOINGSOFTDEP(vp))", while LFS simply
ignored waitfor, one of the reasons why NFS-serving an LFS filesystem
did not work properly.
Under the new semantics, the UPDATE_DIROP flag is a hint to the
fs-specific update routine that the call comes from a dirop routine, and
should be wait for, or not, accordingly.
Closes PR#8996.
2000-05-13 23:43:06 +00:00
jdolecek
c78399fc88
Add a new sysctl variable vfs.ffs.log_changeopt - if this is true,
...
an optimalization strategy change is logged into syslog. Default
is 0 (to not log). This replaces the recent not quite "right"
change to only log the change if kernel is compiled with DEBUG.
2000-04-04 09:23:20 +00:00
augustss
169ac5b3c1
Remove register declarations.
2000-03-30 12:41:09 +00:00
simonb
c2e5560a03
Delete redundant decls of rootvp - it's in <sys/systm.h>.
...
Delete redundant decl of ffs_sbupdate() - it's in <ufs/ffs/ffs_extern.h>.
2000-03-30 02:48:22 +00:00
jdolecek
a6cb6fe4ee
Log the optimization changes only if DEBUG. Fixes kern/9697
2000-03-29 08:46:57 +00:00