Linux SCSI subsystem development
 help / color / mirror / Atom feed
* re: [SCSI] mpt fusion: Add support for ATTO 4LD: Rebranded LSI 53C1030
@ 2014-02-19  9:53 Dan Carpenter
  0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2014-02-19  9:53 UTC (permalink / raw)
  To: eric.moore; +Cc: DL-MPTFusionLinux, linux-scsi

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-02-19  9:54 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-19  9:53 [SCSI] mpt fusion: Add support for ATTO 4LD: Rebranded LSI 53C1030 Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox