Revert "ceph: update issue_seq on cap grant"
This reverts commit d91f2438d8
.
The intent of issue_seq is to distinguish between mds->client messages that
(re)create the cap and those that do not, which means we should _only_ be
updating that value in the create paths. By updating it in handle_cap_grant,
we reset it to zero, which then breaks release.
The larger question is what workload/problem made me think it should be
updated here...
Signed-off-by: Sage Weil <sage@newdream.net>
This commit is contained in:
@@ -2273,8 +2273,7 @@ static void handle_cap_grant(struct inode *inode, struct ceph_mds_caps *grant,
|
|||||||
{
|
{
|
||||||
struct ceph_inode_info *ci = ceph_inode(inode);
|
struct ceph_inode_info *ci = ceph_inode(inode);
|
||||||
int mds = session->s_mds;
|
int mds = session->s_mds;
|
||||||
unsigned seq = le32_to_cpu(grant->seq);
|
int seq = le32_to_cpu(grant->seq);
|
||||||
unsigned issue_seq = le32_to_cpu(grant->issue_seq);
|
|
||||||
int newcaps = le32_to_cpu(grant->caps);
|
int newcaps = le32_to_cpu(grant->caps);
|
||||||
int issued, implemented, used, wanted, dirty;
|
int issued, implemented, used, wanted, dirty;
|
||||||
u64 size = le64_to_cpu(grant->size);
|
u64 size = le64_to_cpu(grant->size);
|
||||||
@@ -2286,8 +2285,8 @@ static void handle_cap_grant(struct inode *inode, struct ceph_mds_caps *grant,
|
|||||||
int revoked_rdcache = 0;
|
int revoked_rdcache = 0;
|
||||||
int queue_invalidate = 0;
|
int queue_invalidate = 0;
|
||||||
|
|
||||||
dout("handle_cap_grant inode %p cap %p mds%d seq %u/%u %s\n",
|
dout("handle_cap_grant inode %p cap %p mds%d seq %d %s\n",
|
||||||
inode, cap, mds, seq, issue_seq, ceph_cap_string(newcaps));
|
inode, cap, mds, seq, ceph_cap_string(newcaps));
|
||||||
dout(" size %llu max_size %llu, i_size %llu\n", size, max_size,
|
dout(" size %llu max_size %llu, i_size %llu\n", size, max_size,
|
||||||
inode->i_size);
|
inode->i_size);
|
||||||
|
|
||||||
@@ -2383,7 +2382,6 @@ static void handle_cap_grant(struct inode *inode, struct ceph_mds_caps *grant,
|
|||||||
}
|
}
|
||||||
|
|
||||||
cap->seq = seq;
|
cap->seq = seq;
|
||||||
cap->issue_seq = issue_seq;
|
|
||||||
|
|
||||||
/* file layout may have changed */
|
/* file layout may have changed */
|
||||||
ci->i_layout = grant->layout;
|
ci->i_layout = grant->layout;
|
||||||
|
Reference in New Issue
Block a user