Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/ufs/ufs

Module Name:    src
Committed By:   riastradh
Date:           Mon Jun  4 19:37:37 UTC 2012

Modified Files:
        src/sys/ufs/ufs: ufs_rename.c

Log Message:
Kill scary message about cross-block directories and fix its cause.

Add a bunch of kasserts to check more stringently that ufs_direnter
did not compact across directory blocks.  Don't bother fetching
subsequent I/O blocks from the directory: ufs_lookup guarantees that
it's not necessary, and the kasserts check this to be sure.

The message fired when we were looking at the start of an I/O block,
not when we crossed from the end of one to the start of another.  I
believe it fired only when tulr->ulr_offset was a multiple of the I/O
block size (fs_bsize), which can happen if ufs_lookup either finds an
entry or finds free space at the start of an I/O block.

If ufs_lookup found an entry, none of this ulr recalculation logic
should kick in -- if tvp != NULL, then tulr->ulr_count is garbage, so
it's not merely unnecessary but wrong (although I suspect harmless in
the end) to read it in ufs_rename_overlap_p in consideration of
whether to recalculate fulr.

Discussed with chuq and dholland.

ok dholland

To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/ufs/ufs/ufs_rename.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Home | Main Index | Thread Index | Old Index