From: zhangqilong <zhangqilong3@huawei.com>
To: ocfs2-devel@oss.oracle.com
Subject: [Ocfs2-devel] 答复: [patch -next] ocfs2: Add the trace_ocfs2_read_blocks_end
Date: Mon, 19 Oct 2020 08:07:48 +0000 [thread overview]
Message-ID: <5960811c6a3b477da371662494fecfa8@huawei.com> (raw)
In-Reply-To: <6a644e29-a2a1-8f18-116f-a67c9a1c5653@linux.alibaba.com>
Hi, Joseph
I think it makes sense, the 'begin' trace entry will always be paired
with 'end'. For the post processing the trace, it would be easier to
reconstruct such reading block operation and mark immediately as 'not sent' (avoiding
to bother about entries which only have 'begin'). Logging an error message could help
locate problems quickly in case error.
It looks good to me, so feel free to add it.
Best wish, thanks,
Zhang Qilong
> -----????-----
> ???: Joseph Qi [mailto:joseph.qi at linux.alibaba.com]
> ????: 2020?10?19? 15:46
> ???: zhangqilong <zhangqilong3@huawei.com>; mark at fasheh.com;
> jlbec at evilplan.org
> ??: ocfs2-devel at oss.oracle.com
> ??: Re: [patch -next] ocfs2: Add the trace_ocfs2_read_blocks_end
>
>
>
> On 2020/10/16 17:11, Zhang Qilong wrote:
> > Missing the trace_ocfs2_read_blocks_end when reading blocks fails.>
> Why do you need the trace in case error?
> In general, it will log an error message if fail.
>
> Thanks,
> Joseph
>
> > Signed-off-by: Zhang Qilong <zhangqilong3@huawei.com>
> > ---
> > fs/ocfs2/buffer_head_io.c | 3 +--
> > 1 file changed, 1 insertion(+), 2 deletions(-)
> >
> > diff --git a/fs/ocfs2/buffer_head_io.c b/fs/ocfs2/buffer_head_io.c
> > index f0b104e483d8..0e6ee6e9b201 100644
> > --- a/fs/ocfs2/buffer_head_io.c
> > +++ b/fs/ocfs2/buffer_head_io.c
> > @@ -395,11 +395,10 @@ int ocfs2_read_blocks(struct ocfs2_caching_info
> *ci, u64 block, int nr,
> > }
> > ocfs2_metadata_cache_io_unlock(ci);
> >
> > +bail:
> > trace_ocfs2_read_blocks_end((unsigned long long)block, nr,
> > flags, ignore_cache);
> >
> > -bail:
> > -
> > return status;
> > }
> >
> >
prev parent reply other threads:[~2020-10-19 8:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-16 9:11 [Ocfs2-devel] [patch -next] ocfs2: Add the trace_ocfs2_read_blocks_end Zhang Qilong
2020-10-19 7:46 ` Joseph Qi
2020-10-19 8:07 ` zhangqilong [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=5960811c6a3b477da371662494fecfa8@huawei.com \
--to=zhangqilong3@huawei.com \
--cc=ocfs2-devel@oss.oracle.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).