mirror of https://gitee.com/openkylin/linux.git
ceph: include time stamp in replayed MDS requests
Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
This commit is contained in:
parent
fbba11b3be
commit
c5c9a0bf1b
|
@ -1904,6 +1904,7 @@ static int __prepare_send_request(struct ceph_mds_client *mdsc,
|
|||
req->r_tid, ceph_mds_op_name(req->r_op), req->r_attempts);
|
||||
|
||||
if (req->r_got_unsafe) {
|
||||
void *p;
|
||||
/*
|
||||
* Replay. Do not regenerate message (and rebuild
|
||||
* paths, etc.); just use the original message.
|
||||
|
@ -1924,8 +1925,13 @@ static int __prepare_send_request(struct ceph_mds_client *mdsc,
|
|||
|
||||
/* remove cap/dentry releases from message */
|
||||
rhead->num_releases = 0;
|
||||
msg->hdr.front_len = cpu_to_le32(req->r_request_release_offset);
|
||||
msg->front.iov_len = req->r_request_release_offset;
|
||||
|
||||
/* time stamp */
|
||||
p = msg->front.iov_base + req->r_request_release_offset;
|
||||
ceph_encode_copy(&p, &req->r_stamp, sizeof(req->r_stamp));
|
||||
|
||||
msg->front.iov_len = p - msg->front.iov_base;
|
||||
msg->hdr.front_len = cpu_to_le32(msg->front.iov_len);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue