From: Sage Weil Date: Wed, 28 Oct 2009 21:57:25 +0000 (-0700) Subject: ceph: correct comment to match striping calculation X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=5600f5ebd318f7af6f4b19a29f08d18bb85264e5;p=deliverable%2Flinux.git ceph: correct comment to match striping calculation The object extent offset is the file offset _modulo_ the stripe unit. The code was correct, the comment was wrong. Reported-by: Noah Watkins Signed-off-by: Sage Weil --- diff --git a/fs/ceph/osdmap.c b/fs/ceph/osdmap.c index 60012e05bdfd..a9a4143234fa 100644 --- a/fs/ceph/osdmap.c +++ b/fs/ceph/osdmap.c @@ -752,7 +752,7 @@ void ceph_calc_file_object_mapping(struct ceph_file_layout *layout, *bno = objsetno * sc + stripepos; dout("objset %u * sc %u = bno %u\n", objsetno, sc, (unsigned)*bno); - /* *oxoff = *off / layout->fl_stripe_unit; */ + /* *oxoff = *off % layout->fl_stripe_unit; */ t = off; *oxoff = do_div(t, su); *oxlen = min_t(u64, *plen, su - *oxoff);