14/ Review writepage and flush and make sure we flush often enough but
not too often.
+ Probably just remove the cluster_flush from write-page as lafs_flush
+ will do that.
+ But leave for now as it encourages heavy indexing.
DONE 15/ The inode map file lost some credits. I think it losts a PinPending because
it isn't locked properly. Don't clear PinPending if someone else might
15a/ Find all FIXMEs and add them here.
-15b/ Report directory size less confusingly
+DONE 15b/ Report directory size less confusingly
15c/ roll-forward should not update index if physaddr hasn't changed (roll_block)
15g/ test directories with non-random sequential hash.
+15h/ orphan deadlock
+ lafs_run_orphans- lafs_orphan_release can block waiting for written
+ in erase_dblock, but that won't complete until cleaner gets to run,
+ but this is the cleaner blocked on orphans.
+
+
16/ Update locking.doc
17/ cluster_flush calls lafs_cluster_allocate calls lafs_add_block_address
return d_splice_alias(ino, dentry);
}
+static int lafs_getattr_dir(struct vfsmount *mnt, struct dentry *dentry,
+ struct kstat *stat)
+{
+ generic_fillattr(dentry->d_inode, stat);
+ /* hide 'holes' in directories by making the size match
+ * the number of allocated blocks.
+ */
+ if (stat->size > dentry->d_inode->i_sb->s_blocksize)
+ stat->size = (dentry->d_inode->i_sb->s_blocksize *
+ (LAFSI(dentry->d_inode)->cblocks +
+ LAFSI(dentry->d_inode)->pblocks +
+ LAFSI(dentry->d_inode)->ablocks));
+ return 0;
+}
+
const struct file_operations lafs_dir_file_operations = {
.llseek = generic_file_llseek, /* Just set 'pos' */
.read = generic_read_dir, /* return error */
.rename = lafs_rename,
.mknod = lafs_mknod,
.setattr = lafs_setattr,
+ .getattr = lafs_getattr_dir,
};