From: David Disseldorp <ddiss@suse.de>
To: Douglas Gilbert <dgilbert@interlog.com>
Cc: target-devel@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [PATCH v2 1/5] lib/scatterlist: use consistent sg_copy_buffer() return type
Date: Mon, 26 Oct 2020 21:05:09 +0000 [thread overview]
Message-ID: <20201026220509.7f0a2abb@suse.de> (raw)
In-Reply-To: <08c0e425-d8c5-a950-f2a1-01bb6c9a5adf@interlog.com>
On Mon, 26 Oct 2020 16:50:53 -0400, Douglas Gilbert wrote:
> On 2020-10-26 3:06 p.m., David Disseldorp wrote:
> > sg_copy_buffer() returns a size_t with the number of bytes copied.
> > Return 0 instead of false if the copy is skipped.
> >
> > Signed-off-by: David Disseldorp <ddiss@suse.de>
> > ---
> > lib/scatterlist.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/lib/scatterlist.c b/lib/scatterlist.c
> > index 0a482ef988e5..a59778946404 100644
> > --- a/lib/scatterlist.c
> > +++ b/lib/scatterlist.c
> > @@ -933,7 +933,7 @@ size_t sg_copy_buffer(struct scatterlist *sgl, unsigned int nents, void *buf,
> > sg_miter_start(&miter, sgl, nents, sg_flags);
> >
> > if (!sg_miter_skip(&miter, skip))
> > - return false;
> > + return 0;
> >
> > while ((offset < buflen) && sg_miter_next(&miter)) {
> > unsigned int len;
> >
>
> This one probably should be sent by itself as a fix to:
> linux-block@vger.kernel.org
>
> and cc-ed to:
> axboe@kernel.dk
>
> on the assumption that Jens Axboe is the maintainer of lib/scatterlist.c .
> He put a fix of mine in sgl_alloc_order() into the kernel recently.
>
> Otherwise:
> Reviewed-by: Douglas Gilbert <dgilbert@interlog.com>
Sent. Thanks Douglas!
next prev parent reply other threads:[~2020-10-26 21:05 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-26 19:06 [PATCH v2 0/5] scsi: target: COMPARE AND WRITE miscompare sense David Disseldorp
2020-10-26 19:06 ` [PATCH v2 1/5] lib/scatterlist: use consistent sg_copy_buffer() return type David Disseldorp
2020-10-26 20:50 ` Douglas Gilbert
2020-10-26 21:05 ` David Disseldorp [this message]
2020-10-26 19:06 ` [PATCH v2 2/5] scsi: target: rename struct sense_info to sense_detail David Disseldorp
2020-10-26 19:06 ` [PATCH v2 3/5] scsi: target: rename cmd.bad_sector to cmd.sense_info David Disseldorp
2020-10-26 19:06 ` [PATCH v2 4/5] scsi: target: split out COMPARE AND WRITE memcmp into helper David Disseldorp
2020-10-26 19:06 ` [PATCH v2 5/5] scsi: target: return COMPARE AND WRITE miscompare offsets David Disseldorp
2020-10-27 5:49 ` [PATCH v2 0/5] scsi: target: COMPARE AND WRITE miscompare sense Mike Christie
2020-10-27 9:57 ` David Disseldorp
2020-10-30 2:02 ` Martin K. Petersen
2020-10-30 2:06 ` Martin K. Petersen
2020-10-30 14:06 ` David Disseldorp
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=20201026220509.7f0a2abb@suse.de \
--to=ddiss@suse.de \
--cc=dgilbert@interlog.com \
--cc=linux-scsi@vger.kernel.org \
--cc=target-devel@vger.kernel.org \
/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).