int (* fs_sync)(struct super_block *sb);
int (* fs_prep_san_write)(struct inode *inode, long *blocks,
int nblocks, loff_t newsize);
- int (* fs_write_record)(struct file *, void *, int size, loff_t *);
+ int (* fs_write_record)(struct file *, void *, int size, loff_t *,
+ int force_sync);
int (* fs_read_record)(struct file *, void *, int size, loff_t *);
};
}
static inline int fsfilt_write_record(struct obd_device *obd, struct file *file,
- void *buf, loff_t size, loff_t *offs)
+ void *buf, loff_t size, loff_t *offs,
+ int force_sync)
{
- return obd->obd_fsops->fs_write_record(file, buf, size, offs);
+ return obd->obd_fsops->fs_write_record(file, buf, size,offs,force_sync);
}
#endif /* __KERNEL__ */
return size;
}
-static int fsfilt_ext3_write_record(struct file * file, void *buf,
- int size, loff_t *offs)
+static int fsfilt_ext3_write_record(struct file *file, void *buf, int size,
+ loff_t *offs, int force_sync)
{
struct buffer_head *bh;
unsigned long block, boffs;
goto out;
}
err = size;
+
+ if (force_sync)
+ handle->h_sync = 1; /* recovery likes this */
out:
if (bh)
brelse(bh);