ceph: remove redundant use of le32_to_cpu
Using stripe unit size calculated and saved on the stack to avoid
a redundant call to le32_to_cpu.
Signed-off-by: Noah Watkins <noah@noahdesu.com>
Signed-off-by: Sage Weil <sage@newdream.net>
diff --git a/fs/ceph/osdmap.c b/fs/ceph/osdmap.c
index 72d75a2..60012e0 100644
--- a/fs/ceph/osdmap.c
+++ b/fs/ceph/osdmap.c
@@ -735,7 +735,7 @@
dout("mapping %llu~%llu osize %u fl_su %u\n", off, *plen,
osize, su);
- su_per_object = osize / le32_to_cpu(layout->fl_stripe_unit);
+ su_per_object = osize / su;
dout("osize %u / su %u = su_per_object %u\n", osize, su,
su_per_object);