All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hou Tao <houtao1@huawei.com>
To: Dave Chinner <david@fromorbit.com>
Cc: miaoxie@huawei.com, fangwei1@huawei.com, xfs@oss.sgi.com
Subject: Re: [PATCH] xfs: simplify the calculation of tpp at xfs_bmdr_to_bmbt
Date: Fri, 24 Jun 2016 15:01:56 +0800	[thread overview]
Message-ID: <576CDAE4.2040202@huawei.com> (raw)
In-Reply-To: <20160624063805.GD12670@dastard>



On 2016/6/24 14:38, Dave Chinner wrote:
> On Fri, Jun 24, 2016 at 01:39:20PM +0800, Hou Tao wrote:
>> remove the usage of rblocklen at xfs_bmdr_to_bmbt, and
>> use be16_to_cpu(dblock->bb_numrecs) instead. It also
>> reduces an extra calculation.
> 
> What problem does this fix, why does it need to be made and
> how did you test it?
It fixes nothing, just for simplification of code understanding.
And now I realize keeping the original code untouched is better,
because using rblocklen to calculate the offset of xfs_bmbt_ptr_t
is common among the btree code, so keeping it consistent.

> We have to be really careful about changing code that interacts with
> the on-disk format, as any bugs we introduced will result in
> filesystem corruption.  Hence you need to explain to the reviewers
> why the change needs to be made to the reviewers...
I will take care, Thanks.

> 
> Cheers,
> 
> Dave.
> 

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

      reply	other threads:[~2016-06-24  7:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-24  5:39 [PATCH] xfs: simplify the calculation of tpp at xfs_bmdr_to_bmbt Hou Tao
2016-06-24  6:38 ` Dave Chinner
2016-06-24  7:01   ` Hou Tao [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=576CDAE4.2040202@huawei.com \
    --to=houtao1@huawei.com \
    --cc=david@fromorbit.com \
    --cc=fangwei1@huawei.com \
    --cc=miaoxie@huawei.com \
    --cc=xfs@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.