Changeset View
Changeset View
Standalone View
Standalone View
sys/ufs/ffs/ffs_inode.c
Show First 20 Lines • Show All 143 Lines • ▼ Show 20 Lines | loop: | ||||
if (DOINGSOFTDEP(vp)) | if (DOINGSOFTDEP(vp)) | ||||
softdep_update_inodeblock(ip, bp, waitfor); | softdep_update_inodeblock(ip, bp, waitfor); | ||||
else if (ip->i_effnlink != ip->i_nlink) | else if (ip->i_effnlink != ip->i_nlink) | ||||
panic("ffs_update: bad link cnt"); | panic("ffs_update: bad link cnt"); | ||||
if (I_IS_UFS1(ip)) { | if (I_IS_UFS1(ip)) { | ||||
*((struct ufs1_dinode *)bp->b_data + | *((struct ufs1_dinode *)bp->b_data + | ||||
ino_to_fsbo(fs, ip->i_number)) = *ip->i_din1; | ino_to_fsbo(fs, ip->i_number)) = *ip->i_din1; | ||||
/* XXX: FIX? The entropy here is desirable, but the harvesting may be expensive */ | /* XXX: FIX? The entropy here is desirable, but the harvesting may be expensive */ | ||||
random_harvest_queue(&(ip->i_din1), sizeof(ip->i_din1), 1, RANDOM_FS_ATIME); | random_harvest_queue(&(ip->i_din1), sizeof(ip->i_din1), RANDOM_FS_ATIME); | ||||
} else { | } else { | ||||
*((struct ufs2_dinode *)bp->b_data + | *((struct ufs2_dinode *)bp->b_data + | ||||
ino_to_fsbo(fs, ip->i_number)) = *ip->i_din2; | ino_to_fsbo(fs, ip->i_number)) = *ip->i_din2; | ||||
/* XXX: FIX? The entropy here is desirable, but the harvesting may be expensive */ | /* XXX: FIX? The entropy here is desirable, but the harvesting may be expensive */ | ||||
random_harvest_queue(&(ip->i_din2), sizeof(ip->i_din2), 1, RANDOM_FS_ATIME); | random_harvest_queue(&(ip->i_din2), sizeof(ip->i_din2), RANDOM_FS_ATIME); | ||||
} | } | ||||
if (waitfor) | if (waitfor) | ||||
error = bwrite(bp); | error = bwrite(bp); | ||||
else if (vm_page_count_severe() || buf_dirty_count_severe()) { | else if (vm_page_count_severe() || buf_dirty_count_severe()) { | ||||
bawrite(bp); | bawrite(bp); | ||||
error = 0; | error = 0; | ||||
} else { | } else { | ||||
if (bp->b_bufsize == fs->fs_bsize) | if (bp->b_bufsize == fs->fs_bsize) | ||||
▲ Show 20 Lines • Show All 613 Lines • Show Last 20 Lines |