re: [SCSI] lpfc 8.3.29: T10 Diff fixes and enhancements

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello James Smart,

This is a semi-automatic email about new static checker warnings.

The patch acd6859b084d: "[SCSI] lpfc 8.3.29: T10 Diff fixes and 
enhancements" from Jan 18, 2012, leads to the following Smatch 
complaint:

drivers/scsi/lpfc/lpfc_scsi.c:1592 lpfc_bg_err_inject()
	 error: we previously assumed 'apptag' could be null (see line 1430)

drivers/scsi/lpfc/lpfc_scsi.c
  1429		/* Should we change the Application Tag */
  1430		if (apptag) {
                    ^^^^^^
Old check.

  1431			if (phba->lpfc_injerr_wapp_cnt) {
  1432				switch (op) {
  1433				case SCSI_PROT_WRITE_PASS:
  1434					if (blockoff && src) {

[snip]

  1585				case SCSI_PROT_READ_STRIP:
  1586				case SCSI_PROT_READ_PASS:
  1587					/*
  1588					 * For READ_STRIP and READ_PASS, force the
  1589					 * error on data being read off the wire. It
  1590					 * should force an IO error to the driver.
  1591					 */
  1592					*apptag = 0xDEAD;
                                        ^^^^^^^
New dereference not checked.  Btw, apptag is always zero in the current
code.

  1593					phba->lpfc_injerr_rgrd_cnt--;
  1594					phba->lpfc_injerr_lba = LPFC_INJERR_LBA_OFF;

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux