Linux SCSI subsystem development
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: eric.moore@lsi.com
Cc: DL-MPTFusionLinux@lsi.com, linux-scsi@vger.kernel.org
Subject: re: [SCSI] mpt fusion: Add support for ATTO 4LD: Rebranded LSI 53C1030
Date: Wed, 19 Feb 2014 12:53:55 +0300	[thread overview]
Message-ID: <20140219095355.GB22351@elgon.mountain> (raw)

Hello Eric Moore,

The patch 232f08fc82b1: "[SCSI] mpt fusion: Add support for ATTO 4LD:
Rebranded LSI 53C1030" from Aug 14, 2007, leads to the following
static checker warning:

	drivers/message/fusion/mptbase.c:5527 mpt_GetScsiPortSettings()
	warn: was hexadecimal intended '10'

drivers/message/fusion/mptbase.c
  5522                                    if (ATTOFlags & ATTOFLAG_TAGGED)
  5523                                      data |= (MPI_SCSIPORTPAGE2_DEVICE_TAG_QUEUE_ENABLE);
  5524                                    if (!(ATTOFlags & ATTOFLAG_WIDE_ENB))
  5525                                      data |= (MPI_SCSIPORTPAGE2_DEVICE_WIDE_DISABLE);
                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
MPI_SCSIPORTPAGE2_DEVICE_WIDE_DISABLE is 0x10.

  5526  
  5527                                    data = (data << 16) | (pdevice->Period << 8) | 10;
                                                                                         ^^

"data" is is a bit field except for the last "10" here.  Maybe it should
be 0x10 instead of 10.  But then we already set 0x10 on the line before
so this code is not clear.

  5528                                    ioc->spi_data.nvram[ii] = data;
  5529                                  }

regards,
dan carpenter

                 reply	other threads:[~2014-02-19  9:54 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20140219095355.GB22351@elgon.mountain \
    --to=dan.carpenter@oracle.com \
    --cc=DL-MPTFusionLinux@lsi.com \
    --cc=eric.moore@lsi.com \
    --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