linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: todd.e.brandt@linux.intel.com
Cc: linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org,
	tj@kernel.org, JBottomley@parallels.com
Subject: Re: [PATCH/RESEND 2/2] Hard disk S3 resume time optimization
Date: Fri, 06 Sep 2013 16:37:00 +0400	[thread overview]
Message-ID: <5229CC6C.5010705@cogentembedded.com> (raw)
In-Reply-To: <20130906004425.GA31998@linux.intel.com>

Hello.

On 06-09-2013 4:44, Todd E Brandt wrote:

> Part 2 of the hard disk resume optimization patch, this one applies
> to the scsi subsystem.

    Don't give the same name to both patches. In this case, you could prefix 
the patch name with e.g. "sd: ".

> Signed-off-by: Todd Brandt <todd.e.brandt@intel.com>
> Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>

>   drivers/scsi/sd.c | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
>   1 file changed, 81 insertions(+), 1 deletion(-)

> diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
> index 86fcf2c..d4bf784 100644
> --- a/drivers/scsi/sd.c
> +++ b/drivers/scsi/sd.c
[...]
> @@ -3137,6 +3138,85 @@ done:
>   	return ret;
>   }
>
> +static void sd_resume_async_end(struct request *rq, int error)
> +{
> +	struct scsi_sense_hdr sshdr;
> +	struct scsi_disk *sdkp = rq->end_io_data;
> +	char *sense = rq->sense;
> +
> +	if (error) {
> +		sd_printk(KERN_WARNING, sdkp, "START FAILED\n");
> +		sd_print_result(sdkp, error);
> +		if (sense && (driver_byte(error) & DRIVER_SENSE)) {
> +			scsi_normalize_sense(sense,
> +				SCSI_SENSE_BUFFERSIZE, &sshdr);
> +			sd_print_sense_hdr(sdkp, &sshdr);
> +		}
> +	} else
> +		sd_printk(KERN_NOTICE, sdkp, "START SUCCESS\n");

    According to Documentation/CodingStyle, both arms of the *if* statement 
should have {} when one arm has them.

WBR, Sergei


  reply	other threads:[~2013-09-06 12:37 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-06  0:44 [PATCH/RESEND 2/2] Hard disk S3 resume time optimization Todd E Brandt
2013-09-06 12:37 ` Sergei Shtylyov [this message]
2013-09-06 22:13   ` Todd E Brandt
2013-09-06 15:10 ` James Bottomley
2013-09-06 22:11   ` Todd E Brandt
2013-09-06 17:03 ` Bartlomiej Zolnierkiewicz
2013-09-06 22:19   ` Todd E Brandt

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=5229CC6C.5010705@cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded.com \
    --cc=JBottomley@parallels.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=tj@kernel.org \
    --cc=todd.e.brandt@linux.intel.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).