aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ceph
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2012-09-28 00:59:16 -0400
committerAlex Elder <elder@inktank.com>2012-10-01 15:30:54 -0400
commitb905a7f8b7a61c192927d0324f2ea6c998f451ba (patch)
tree6a3345523a8c96dc150987fa5c3826339d37c9e2 /fs/ceph
parent3e8f43a089f06279c5f76a9ccd42578eebf7bfa5 (diff)
ceph: convert to use le32_add_cpu()
Convert cpu_to_le32(le32_to_cpu(E1) + E2) to use le32_add_cpu(). dpatch engine is used to auto generate this patch. (https://github.com/weiyj/dpatch) Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Sage Weil <sage@inktank.com>
Diffstat (limited to 'fs/ceph')
-rw-r--r--fs/ceph/caps.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ceph/caps.c b/fs/ceph/caps.c
index 620daad201db..3251e9cc6401 100644
--- a/fs/ceph/caps.c
+++ b/fs/ceph/caps.c
@@ -1005,7 +1005,7 @@ static void __queue_cap_release(struct ceph_mds_session *session,
1005 1005
1006 BUG_ON(msg->front.iov_len + sizeof(*item) > PAGE_CACHE_SIZE); 1006 BUG_ON(msg->front.iov_len + sizeof(*item) > PAGE_CACHE_SIZE);
1007 head = msg->front.iov_base; 1007 head = msg->front.iov_base;
1008 head->num = cpu_to_le32(le32_to_cpu(head->num) + 1); 1008 le32_add_cpu(&head->num, 1);
1009 item = msg->front.iov_base + msg->front.iov_len; 1009 item = msg->front.iov_base + msg->front.iov_len;
1010 item->ino = cpu_to_le64(ino); 1010 item->ino = cpu_to_le64(ino);
1011 item->cap_id = cpu_to_le64(cap_id); 1011 item->cap_id = cpu_to_le64(cap_id);