summaryrefslogtreecommitdiffstats
path: root/include/linux/ceph/ceph_frag.h
diff options
context:
space:
mode:
authorZhang Zhuoyu <zhangzhuoyu@cmss.chinamobile.com>2016-03-25 05:18:39 -0400
committerIlya Dryomov <idryomov@gmail.com>2016-05-26 01:15:39 +0200
commit3b33f692c84c28cc8178aaeeb9264d82b48787f1 (patch)
treec2d56a816c39928e5c82b6fde4d233b800f2a8fb /include/linux/ceph/ceph_frag.h
parent224a7542b8fdde3cc7c600f8b0870c5541a9f678 (diff)
downloadop-kernel-dev-3b33f692c84c28cc8178aaeeb9264d82b48787f1.zip
op-kernel-dev-3b33f692c84c28cc8178aaeeb9264d82b48787f1.tar.gz
ceph: make logical calculation functions return bool
This patch makes serverl logical caculation functions return bool to improve readability due to these particular functions only using 0/1 as their return value. No functional change. Signed-off-by: Zhang Zhuoyu <zhangzhuoyu@cmss.chinamobile.com>
Diffstat (limited to 'include/linux/ceph/ceph_frag.h')
-rw-r--r--include/linux/ceph/ceph_frag.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/ceph/ceph_frag.h b/include/linux/ceph/ceph_frag.h
index b827e06..146507d 100644
--- a/include/linux/ceph/ceph_frag.h
+++ b/include/linux/ceph/ceph_frag.h
@@ -51,11 +51,11 @@ static inline __u32 ceph_frag_make_child(__u32 f, int by, int i)
return ceph_frag_make(newbits,
ceph_frag_value(f) | (i << (24 - newbits)));
}
-static inline int ceph_frag_is_leftmost(__u32 f)
+static inline bool ceph_frag_is_leftmost(__u32 f)
{
return ceph_frag_value(f) == 0;
}
-static inline int ceph_frag_is_rightmost(__u32 f)
+static inline bool ceph_frag_is_rightmost(__u32 f)
{
return ceph_frag_value(f) == ceph_frag_mask(f);
}
OpenPOWER on IntegriCloud