Linux SCSI subsystem development
 help / color / mirror / Atom feed
From: Roland Dreier <rdreier@cisco.com>
To: Randy Dunlap <randy.dunlap@oracle.com>
Cc: James Bottomley <James.Bottomley@suse.de>,
	Ravi Anand <ravi.anand@qlogic.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	linux-scsi <linux-scsi@vger.kernel.org>,
	linux-kernel@vger.kernel.org,
	David C Somayajulu <david.somayajulu@qlogic.com>,
	Karen Higgins <karen.higgins@qlogic.com>,
	Vikas Chaudhary <vikas.chaudhary@qlogic.com>
Subject: Re: [PATCH 3rd_time] scsi: fix operator precedence warning
Date: Mon, 26 Apr 2010 09:56:12 -0700	[thread overview]
Message-ID: <adaaasqm9ub.fsf@roland-alpha.cisco.com> (raw)
In-Reply-To: <20100422110214.e7c62688.randy.dunlap@oracle.com> (Randy Dunlap's message of "Thu, 22 Apr 2010 11:02:14 -0700")

 > -		*tcp_source_port_num = (uint16_t) mbox_sts[6] >> 16;
 > +		*tcp_source_port_num = (uint16_t) (mbox_sts[6] >> 16);

I wonder why we need that cast at all?  The fact that
tcp_source_port_num is a uint16_t* should cause the value to get
truncated properly anyway.

But I agree that this patch is a minimal fix for a real bug.
-- 
Roland Dreier <rolandd@cisco.com> || For corporate legal information go to:
http://www.cisco.com/web/about/doing_business/legal/cri/index.html

      reply	other threads:[~2010-04-26 16:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-22 14:17 [GIT PULL] SCSI fixes for 2.6.34-rc5 James Bottomley
2010-04-22 18:02 ` [PATCH 3rd_time] scsi: fix operator precedence warning Randy Dunlap
2010-04-26 16:56   ` Roland Dreier [this message]

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=adaaasqm9ub.fsf@roland-alpha.cisco.com \
    --to=rdreier@cisco.com \
    --cc=James.Bottomley@suse.de \
    --cc=akpm@linux-foundation.org \
    --cc=david.somayajulu@qlogic.com \
    --cc=karen.higgins@qlogic.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=randy.dunlap@oracle.com \
    --cc=ravi.anand@qlogic.com \
    --cc=torvalds@linux-foundation.org \
    --cc=vikas.chaudhary@qlogic.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