Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753293AbdCHNLI (ORCPT ); Wed, 8 Mar 2017 08:11:08 -0500 Received: from mout.web.de ([212.227.15.14]:51427 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752849AbdCHNKX (ORCPT ); Wed, 8 Mar 2017 08:10:23 -0500 Subject: [PATCH 11/26] IB/ocrdma: Delete unnecessary braces To: linux-rdma@vger.kernel.org, Devesh Sharma , Doug Ledford , Hal Rosenstock , Sean Hefty , Selvin Xavier References: Cc: LKML , kernel-janitors@vger.kernel.org From: SF Markus Elfring Message-ID: Date: Wed, 8 Mar 2017 14:04:56 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:09ak/TLznElQsOi880oxDLxR75If1Do7b7wXT0luGfRSZ1MKHpv GmmOW2LyzR+BgKWQWJUeVQ9a3BwzX1UiPcVMnFz0WNHyxGeHwY7fp4g1AUOtWEUeNO9hVsc 268WtGBAEX9regd9/HfgAbg61lYXm0534fZsFWYAckyrF1Jf5YXgQk+0MgoUnsWblRHxiin Wr/5+mgIbdnZKRH4adXQQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:A+Q4GIawjKE=:bsI416JX8KrRDNMrlXpuYK sxmFxWD6UAZaditT7CwlTsPIequ06ZKvM35CaQ6Y3wokH6vHnq0yOZAc/U70z30csmJM9mt2n VQgdxzvDnESJFPvjmTtHQs2wGWC4dx72J5M4HqJrklihW4xgIhkaelD3CTUKsRywhOQPQ4zNt uLXQvwFXt9VC7PF6xWBpUD85iAbIzZdNSlFxrKm78wxo3BvyqBlLp/mUFyUjE4Z4vXqb/Po9I FogretTvC9VhCgEANp9rqOYTXlEMWFOq/usJ7mPi7SeVZ5JVRFPWFmuyj7AiRBwZHAea+IKZF kr1LfNcK1JXzasJ3PliPb4CmSqu7stQfLc5rIEqEk1gHzEzoJdRaa4L70hed7YL6f1nwM/bhQ iLltBX8z0/b/QLgiGVo+AHoC98S/+1ohI2YZKoBWFdI/CyvAW4z1JitGAszNWg2IaDKArhWRu YJ4ytM9YThvzeznrt7RrSzFV4cc0bsVCy7DLQjBV4a/UpxSTZ6peatLhlTIlJKB9CEXPok+eY /qvNTZpO44L+LT+vbGd427PrVKkn8XZ7SBEFycC5fDmUp4rJ973Q+oIullKumTf1Pefrxg7ff 0pEr9mfTP57VKoIWxiKb7i7z5epqufqratLTPP4i0q7sI/PoQE4HIAuHhwz8RbxJhOV69ahxY JAuKzaPTRpDmHjH/ZTBRkjSmZNe6QM9RHIERPganc0+p2iO5Pfa8x3xKi02X2bn1JGM4N7r47 NKPLo29TmDKdh721ATeReBQIabvwxvHJxORos1134fjGCTUU0xLSoOm1IUDvCf5LL2I5KkPlO C3W2/R6 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2307 Lines: 80 From: Markus Elfring Date: Tue, 7 Mar 2017 21:12:56 +0100 Do not use curly brackets at some source code places where a single statement should be sufficient. Signed-off-by: Markus Elfring --- drivers/infiniband/hw/ocrdma/ocrdma_hw.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_hw.c b/drivers/infiniband/hw/ocrdma/ocrdma_hw.c index aa32bc9f323d..d5b988b011d1 100644 --- a/drivers/infiniband/hw/ocrdma/ocrdma_hw.c +++ b/drivers/infiniband/hw/ocrdma/ocrdma_hw.c @@ -1092,14 +1092,14 @@ static int ocrdma_mbx_cmd(struct ocrdma_dev *dev, struct ocrdma_mqe *mqe) if (cqe_status || ext_status) { pr_err("%s() cqe_status=0x%x, ext_status=0x%x,", __func__, cqe_status, ext_status); - if (rsp) { + if (rsp) /* This is for embedded cmds. */ pr_err("opcode=0x%x, subsystem=0x%x\n", (rsp->subsys_op & OCRDMA_MBX_RSP_OPCODE_MASK) >> OCRDMA_MBX_RSP_OPCODE_SHIFT, (rsp->subsys_op & OCRDMA_MBX_RSP_SUBSYS_MASK) >> OCRDMA_MBX_RSP_SUBSYS_SHIFT); - } + status = ocrdma_get_mbx_cqe_errno(cqe_status); goto mbx_err; } @@ -1600,10 +1600,9 @@ void ocrdma_alloc_pd_pool(struct ocrdma_dev *dev) return; status = ocrdma_mbx_alloc_pd_range(dev); - if (status) { + if (status) pr_err("%s(%d) Unable to initialize PD pool, using default.\n", __func__, dev->id); - } } static void ocrdma_free_pd_pool(struct ocrdma_dev *dev) @@ -2997,11 +2996,10 @@ static int ocrdma_parse_dcbxcfg_rsp(struct ocrdma_dev *dev, int ptype, goto out; } } - if (slindx == OCRDMA_MAX_SERVICE_LEVEL_INDEX) { + if (slindx == OCRDMA_MAX_SERVICE_LEVEL_INDEX) pr_info("%s ocrdma%d application priority not set for 0x%x protocol\n", dev_name(&dev->nic_info.pdev->dev), dev->id, proto); - } } } @@ -3158,16 +3156,17 @@ static int ocrdma_modify_eqd(struct ocrdma_dev *dev, struct ocrdma_eq *eq, int num) { int num_eqs, i = 0; - if (num > 8) { + + if (num > 8) while (num) { num_eqs = min(num, 8); ocrdma_mbx_modify_eqd(dev, &eq[i], num_eqs); i += num_eqs; num -= num_eqs; } - } else { + else ocrdma_mbx_modify_eqd(dev, eq, num); - } + return 0; } -- 2.12.0