From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: tom.ty89@gmail.com, linux-scsi@vger.kernel.org
Subject: Re: [PATCH 2/2] sd: disable write same for SAT as per the comment
Date: Fri, 26 Feb 2016 12:16:34 -0800 [thread overview]
Message-ID: <1456517794.2369.43.camel@HansenPartnership.com> (raw)
In-Reply-To: <56d0b08c.e99c420a.dbca1.0415@mx.google.com>
On Sat, 2016-02-27 at 04:07 +0800, tom.ty89@gmail.com wrote:
> From: Tom Yan <tom.ty89@gmail.com>
>
> Signed-off-by: Tom Yan <tom.ty89@gmail.com>
>
> diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
> index 1179ec1..9eeee51 100644
> --- a/drivers/scsi/sd.c
> +++ b/drivers/scsi/sd.c
> @@ -2786,7 +2786,7 @@ static void sd_read_write_same(struct scsi_disk
> *sdkp, unsigned char *buffer)
> * CODES is unsupported and the device has an ATA
> * Information VPD page (SAT).
> */
> - if (!scsi_get_vpd_page(sdev, 0x89, buffer,
> vpd_buf_len))
> + if (scsi_get_vpd_page(sdev, 0x89, buffer,
> vpd_buf_len))
> sdev->no_write_same = 1;
> }
If you're inverting the condition, you'd need to invert the comment as
well. scsi_get_vpd_page returns 0 on success so !scsi_get_vpd_page is
true if it got the page (which is what the comment says).
James
next prev parent reply other threads:[~2016-02-26 20:16 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1456517250-2713-1-git-send-email-me>
2016-02-26 20:07 ` [PATCH 2/2] sd: disable write same for SAT as per the comment tom.ty89
2016-02-26 20:16 ` James Bottomley [this message]
2016-02-26 20:32 ` Tom Yan
2016-02-26 20:57 ` James Bottomley
2016-02-26 21:07 ` Tom Yan
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=1456517794.2369.43.camel@HansenPartnership.com \
--to=james.bottomley@hansenpartnership.com \
--cc=linux-scsi@vger.kernel.org \
--cc=tom.ty89@gmail.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.