ext* uses ext*_force_commit, reiser is unimplemented
- add /proc/sys/lustre/filter_sync_on_commit tunable, disabled by default.
when enabled it calls the filter sync after each filter_commitrw for write
int (* fs_set_last_rcvd)(struct obd_device *obd, __u64 last_rcvd,
void *handle, fsfilt_cb_t cb_func);
int (* fs_statfs)(struct super_block *sb, struct obd_statfs *osfs);
+ int (* fs_sync)(struct super_block *sb);
};
extern int fsfilt_register_ops(struct fsfilt_operations *fs_ops);
return obd->obd_fsops->fs_statfs(fs, osfs);
}
+static inline int fsfilt_sync(struct obd_device *obd, struct super_block *fs)
+{
+ return obd->obd_fsops->fs_sync(fs);
+}
+
#endif /* __KERNEL__ */
#endif
return rc;
}
+static int fsfilt_ext3_sync(struct super_block *sb)
+{
+ return ext3_force_commit(sb);
+}
+
static struct fsfilt_operations fsfilt_ext3_ops = {
fs_type: "ext3",
fs_owner: THIS_MODULE,
fs_journal_data: fsfilt_ext3_journal_data,
fs_set_last_rcvd: fsfilt_ext3_set_last_rcvd,
fs_statfs: fsfilt_ext3_statfs,
+ fs_sync: fsfilt_ext3_sync,
};
static int __init fsfilt_ext3_init(void)