[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <03ee5f77-5866-1186-b160-bb5141848865@users.sourceforge.net>
Date: Sun, 21 Aug 2016 09:29:24 +0200
From: SF Markus Elfring <elfring@...rs.sourceforge.net>
To: linux-scsi@...r.kernel.org, aacraid@...rosemi.com,
"James E. J. Bottomley" <jejb@...ux.vnet.ibm.com>,
"Martin K. Petersen" <martin.petersen@...cle.com>
Cc: LKML <linux-kernel@...r.kernel.org>,
kernel-janitors@...r.kernel.org,
Julia Lawall <julia.lawall@...6.fr>
Subject: [PATCH 7/7] aacraid: Apply another recommendation from
"checkpatch.pl"
From: Markus Elfring <elfring@...rs.sourceforge.net>
Date: Sun, 21 Aug 2016 08:23:25 +0200
The script "checkpatch.pl" can point out that assignments should usually
not be performed within condition checks.
Thus move the assignment for the variable "srbfib" to a separate statement.
Signed-off-by: Markus Elfring <elfring@...rs.sourceforge.net>
---
drivers/scsi/aacraid/commctrl.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/aacraid/commctrl.c b/drivers/scsi/aacraid/commctrl.c
index d2029db..7e6c76d 100644
--- a/drivers/scsi/aacraid/commctrl.c
+++ b/drivers/scsi/aacraid/commctrl.c
@@ -499,9 +499,9 @@ static int aac_send_raw_srb(struct aac_dev* dev, void __user * arg)
/*
* Allocate and initialize a Fib then setup a SRB command
*/
- if (!(srbfib = aac_fib_alloc(dev))) {
+ srbfib = aac_fib_alloc(dev);
+ if (!srbfib)
return -ENOMEM;
- }
aac_fib_init(srbfib);
/* raw_srb FIB is not FastResponseCapable */
srbfib->hw_fib_va->header.XferState &= ~cpu_to_le32(FastResponseCapable);
--
2.9.3
Powered by blists - more mailing lists