From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: yu kuai <yukuai3@huawei.com>
Cc: <axboe@kernel.dk>, <ming.lei@redhat.com>,
<martin.petersen@oracle.com>, <wenwen@cs.uga.edu>,
<linux-block@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<yi.zhang@huawei.com>
Subject: Re: [PATCH] block/bio-integrity: don't free 'buf' if bio_integrity_add_page() failed
Date: Tue, 02 Jun 2020 18:35:10 -0400 [thread overview]
Message-ID: <yq1tuzt9k6w.fsf@ca-mkp.ca.oracle.com> (raw)
In-Reply-To: <20200601123856.3895734-1-yukuai3@huawei.com> (yu kuai's message of "Mon, 1 Jun 2020 20:38:56 +0800")
Hi Yu!
I suggest a few minor wording tweaks to the commit message:
> commit e7bf90e5afe3 ("block/bio-integrity: fix a memory leak bug") add
s/add/added/
> a kree() for 'buf' if bio_integrity_add_page() return '0'. However,
> the
s/kree/kfree/
s/return/returns/
> object will be freed in bio_integrity_free() since 'bio->bi_opf' and
> 'bio->bi_integrity' was set previousy in bio_integrity_alloc().
s/was/were/
Otherwise OK.
And like Ming pointed out, you may want to add a comment about the
assertion that the first vec is valid.
Acked-by: Martin K. Petersen <martin.petersen@oracle.com>
--
Martin K. Petersen Oracle Linux Engineering
next prev parent reply other threads:[~2020-06-02 22:35 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-01 12:38 [PATCH] block/bio-integrity: don't free 'buf' if bio_integrity_add_page() failed yu kuai
2020-06-02 7:37 ` Ming Lei
2020-06-02 8:01 ` Bob Liu
2020-06-02 22:35 ` Martin K. Petersen [this message]
2020-06-02 22:44 ` Jens Axboe
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=yq1tuzt9k6w.fsf@ca-mkp.ca.oracle.com \
--to=martin.petersen@oracle.com \
--cc=axboe@kernel.dk \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ming.lei@redhat.com \
--cc=wenwen@cs.uga.edu \
--cc=yi.zhang@huawei.com \
--cc=yukuai3@huawei.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.