linux-sg2042/drivers/scsi/bnx2fc
Julia Lawall b0d5e15cc4 [SCSI] bnx2fc: adjust duplicate test
Delete successive tests to the same location.  The code tested the result
of a previous allocation, that itself was already tested.  It is changed to
test the result of the most recent allocation.

A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@s exists@
local idexpression y;
expression x,e;
@@

*if ( \(x == NULL\|IS_ERR(x)\|y != 0\) )
 { ... when forall
   return ...; }
... when != \(y = e\|y += e\|y -= e\|y |= e\|y &= e\|y++\|y--\|&y\)
    when != \(XT_GETPAGE(...,y)\|WMI_CMD_BUF(...)\)
*if ( \(x == NULL\|IS_ERR(x)\|y != 0\) )
 { ... when forall
   return ...; }
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-01-30 14:04:54 +11:00
..
57xx_hsi_bnx2fc.h New 7.0 FW: bnx2x, cnic, bnx2i, bnx2fc 2011-06-15 10:56:37 -04:00
Kconfig cnic: Fix select dependencies in bnx2fc/bnx2i Kconfig. 2011-08-12 03:00:47 -07:00
Makefile [SCSI] bnx2fc: Reduce object size by consolidating formats 2012-07-20 08:58:17 +01:00
bnx2fc.h [SCSI] bnx2fc: Bumped version to 1.0.13 2013-01-30 10:48:49 +11:00
bnx2fc_constants.h cnic: Fix parity error code conflict 2012-03-21 21:57:36 -04:00
bnx2fc_debug.c [SCSI] bnx2fc: Reduce object size by consolidating formats 2012-07-20 08:58:17 +01:00
bnx2fc_debug.h [SCSI] bnx2fc: Reduce object size by consolidating formats 2012-07-20 08:58:17 +01:00
bnx2fc_els.c [SCSI] bnx2fc: Allocate fcoe_ctlr with bnx2fc_interface, not as a member 2012-05-23 09:38:11 +01:00
bnx2fc_fcoe.c [SCSI] bnx2fc: Bumped version to 1.0.13 2013-01-30 10:48:49 +11:00
bnx2fc_hwi.c [SCSI] bnx2fc: Map the doorbell register between offload and enable requests 2013-01-30 10:48:48 +11:00
bnx2fc_io.c [SCSI] bnx2fc: adjust duplicate test 2013-01-30 14:04:54 +11:00
bnx2fc_tgt.c [SCSI] bnx2fc: Map the doorbell register between offload and enable requests 2013-01-30 10:48:48 +11:00