public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Jayamohan Kallickal <jayamohan.kallickal@emulex.com>
Cc: "James E.J. Bottomley" <JBottomley@parallels.com>,
	linux-scsi@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [patch] [SCSI] be2iscsi: cleanup a min_t() call
Date: Fri, 18 Nov 2011 17:00:31 +0300	[thread overview]
Message-ID: <20111118140031.GG4349@mwanda> (raw)
In-Reply-To: <20110926062337.GD11832@elgon.mountain>

[-- Attachment #1: Type: text/plain, Size: 758 bytes --]

On Mon, Sep 26, 2011 at 09:23:37AM +0300, Dan Carpenter wrote:
> "sense_len" was declared as int type but actually it only stores a
> u16 value that comes from hardware.  The cast to u16 in min_t()
> confuses static analysis because it truncates the int to u16 so I've
> fixed the declaration to reflect that "sense_len" is just a u16.
> 
> Also there was a call to cpu_to_be16() which I've changed to
> be16_to_cpu().  The functions are equivalent, but obviously the
> hardware is big endian and we're doing the min_t() comparison on CPU
> endian values.
> 
> This whole patch is just a cleanup and doesn't affect how the code
> works.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> ---

Ping.

regards,
dan carpenter


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2011-11-18 13:59 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-26  6:23 [patch] [SCSI] be2iscsi: cleanup a min_t() call Dan Carpenter
2011-11-18 14:00 ` Dan Carpenter [this message]
2011-11-18 19:28 ` Mike Christie
2011-11-29 20:55   ` Jayamohan.Kallickal

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=20111118140031.GG4349@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=JBottomley@parallels.com \
    --cc=jayamohan.kallickal@emulex.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-scsi@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