diff options
Diffstat (limited to 'fs')
| -rw-r--r-- | fs/fuse/dir.c | 9 | ||||
| -rw-r--r-- | fs/fuse/file.c | 2 | ||||
| -rw-r--r-- | fs/fuse/fuse_i.h | 2 |
3 files changed, 9 insertions, 4 deletions
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c index 8c233834591f..e6ba579e2937 100644 --- a/fs/fuse/dir.c +++ b/fs/fuse/dir.c | |||
| @@ -1597,7 +1597,7 @@ static void fuse_setattr_fill(struct fuse_conn *fc, struct fuse_req *req, | |||
| 1597 | /* | 1597 | /* |
| 1598 | * Flush inode->i_mtime to the server | 1598 | * Flush inode->i_mtime to the server |
| 1599 | */ | 1599 | */ |
| 1600 | int fuse_flush_mtime(struct inode *inode, struct fuse_file *ff) | 1600 | int fuse_flush_times(struct inode *inode, struct fuse_file *ff) |
| 1601 | { | 1601 | { |
| 1602 | struct fuse_conn *fc = get_fuse_conn(inode); | 1602 | struct fuse_conn *fc = get_fuse_conn(inode); |
| 1603 | struct fuse_req *req; | 1603 | struct fuse_req *req; |
| @@ -1612,9 +1612,14 @@ int fuse_flush_mtime(struct inode *inode, struct fuse_file *ff) | |||
| 1612 | memset(&inarg, 0, sizeof(inarg)); | 1612 | memset(&inarg, 0, sizeof(inarg)); |
| 1613 | memset(&outarg, 0, sizeof(outarg)); | 1613 | memset(&outarg, 0, sizeof(outarg)); |
| 1614 | 1614 | ||
| 1615 | inarg.valid |= FATTR_MTIME; | 1615 | inarg.valid = FATTR_MTIME; |
| 1616 | inarg.mtime = inode->i_mtime.tv_sec; | 1616 | inarg.mtime = inode->i_mtime.tv_sec; |
| 1617 | inarg.mtimensec = inode->i_mtime.tv_nsec; | 1617 | inarg.mtimensec = inode->i_mtime.tv_nsec; |
| 1618 | if (fc->minor >= 23) { | ||
| 1619 | inarg.valid |= FATTR_CTIME; | ||
| 1620 | inarg.ctime = inode->i_ctime.tv_sec; | ||
| 1621 | inarg.ctimensec = inode->i_ctime.tv_nsec; | ||
| 1622 | } | ||
| 1618 | if (ff) { | 1623 | if (ff) { |
| 1619 | inarg.valid |= FATTR_FH; | 1624 | inarg.valid |= FATTR_FH; |
| 1620 | inarg.fh = ff->fh; | 1625 | inarg.fh = ff->fh; |
diff --git a/fs/fuse/file.c b/fs/fuse/file.c index d228c3962ffd..96d513e01a5d 100644 --- a/fs/fuse/file.c +++ b/fs/fuse/file.c | |||
| @@ -1691,7 +1691,7 @@ int fuse_write_inode(struct inode *inode, struct writeback_control *wbc) | |||
| 1691 | int err; | 1691 | int err; |
| 1692 | 1692 | ||
| 1693 | ff = __fuse_write_file_get(fc, fi); | 1693 | ff = __fuse_write_file_get(fc, fi); |
| 1694 | err = fuse_flush_mtime(inode, ff); | 1694 | err = fuse_flush_times(inode, ff); |
| 1695 | if (ff) | 1695 | if (ff) |
| 1696 | fuse_file_put(ff, 0); | 1696 | fuse_file_put(ff, 0); |
| 1697 | 1697 | ||
diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h index d2f10054b9a1..40677e33504f 100644 --- a/fs/fuse/fuse_i.h +++ b/fs/fuse/fuse_i.h | |||
| @@ -889,7 +889,7 @@ int fuse_dev_release(struct inode *inode, struct file *file); | |||
| 889 | 889 | ||
| 890 | bool fuse_write_update_size(struct inode *inode, loff_t pos); | 890 | bool fuse_write_update_size(struct inode *inode, loff_t pos); |
| 891 | 891 | ||
| 892 | int fuse_flush_mtime(struct inode *inode, struct fuse_file *ff); | 892 | int fuse_flush_times(struct inode *inode, struct fuse_file *ff); |
| 893 | int fuse_write_inode(struct inode *inode, struct writeback_control *wbc); | 893 | int fuse_write_inode(struct inode *inode, struct writeback_control *wbc); |
| 894 | 894 | ||
| 895 | int fuse_do_setattr(struct inode *inode, struct iattr *attr, | 895 | int fuse_do_setattr(struct inode *inode, struct iattr *attr, |
