Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'ceph-for-4.12-rc6' of git://github.com/ceph/ceph-client

Pull ceph fixes from Ilya Dryomov:
"A fix for an old ceph ->fh_to_* bug from Luis and two timestamp fixups
from Zheng, prompted by the ongoing y2038 work"

* tag 'ceph-for-4.12-rc6' of git://github.com/ceph/ceph-client:
ceph: unify inode i_ctime update
ceph: use current_kernel_time() to get request time stamp
ceph: check i_nlink while converting a file handle to dentry

+8 -6
+1
fs/ceph/acl.c
··· 131 131 } 132 132 133 133 if (new_mode != old_mode) { 134 + newattrs.ia_ctime = current_time(inode); 134 135 newattrs.ia_mode = new_mode; 135 136 newattrs.ia_valid = ATTR_MODE; 136 137 ret = __ceph_setattr(inode, &newattrs);
+4
fs/ceph/export.c
··· 91 91 ceph_mdsc_put_request(req); 92 92 if (!inode) 93 93 return ERR_PTR(-ESTALE); 94 + if (inode->i_nlink == 0) { 95 + iput(inode); 96 + return ERR_PTR(-ESTALE); 97 + } 94 98 } 95 99 96 100 return d_obtain_alias(inode);
+2 -3
fs/ceph/inode.c
··· 2022 2022 attr->ia_size > inode->i_size) { 2023 2023 i_size_write(inode, attr->ia_size); 2024 2024 inode->i_blocks = calc_inode_blocks(attr->ia_size); 2025 - inode->i_ctime = attr->ia_ctime; 2026 2025 ci->i_reported_size = attr->ia_size; 2027 2026 dirtied |= CEPH_CAP_FILE_EXCL; 2028 2027 } else if ((issued & CEPH_CAP_FILE_SHARED) == 0 || ··· 2043 2044 inode->i_ctime.tv_sec, inode->i_ctime.tv_nsec, 2044 2045 attr->ia_ctime.tv_sec, attr->ia_ctime.tv_nsec, 2045 2046 only ? "ctime only" : "ignored"); 2046 - inode->i_ctime = attr->ia_ctime; 2047 2047 if (only) { 2048 2048 /* 2049 2049 * if kernel wants to dirty ctime but nothing else, ··· 2065 2067 if (dirtied) { 2066 2068 inode_dirty_flags = __ceph_mark_dirty_caps(ci, dirtied, 2067 2069 &prealloc_cf); 2068 - inode->i_ctime = current_time(inode); 2070 + inode->i_ctime = attr->ia_ctime; 2069 2071 } 2070 2072 2071 2073 release &= issued; ··· 2083 2085 req->r_inode_drop = release; 2084 2086 req->r_args.setattr.mask = cpu_to_le32(mask); 2085 2087 req->r_num_caps = 1; 2088 + req->r_stamp = attr->ia_ctime; 2086 2089 err = ceph_mdsc_do_request(mdsc, NULL, req); 2087 2090 } 2088 2091 dout("setattr %p result=%d (%s locally, %d remote)\n", inode, err,
+1 -3
fs/ceph/mds_client.c
··· 1687 1687 ceph_mdsc_create_request(struct ceph_mds_client *mdsc, int op, int mode) 1688 1688 { 1689 1689 struct ceph_mds_request *req = kzalloc(sizeof(*req), GFP_NOFS); 1690 - struct timespec ts; 1691 1690 1692 1691 if (!req) 1693 1692 return ERR_PTR(-ENOMEM); ··· 1705 1706 init_completion(&req->r_safe_completion); 1706 1707 INIT_LIST_HEAD(&req->r_unsafe_item); 1707 1708 1708 - ktime_get_real_ts(&ts); 1709 - req->r_stamp = timespec_trunc(ts, mdsc->fsc->sb->s_time_gran); 1709 + req->r_stamp = timespec_trunc(current_kernel_time(), mdsc->fsc->sb->s_time_gran); 1710 1710 1711 1711 req->r_op = op; 1712 1712 req->r_direct_mode = mode;