From patchwork Thu Sep 28 02:32:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: KaiLong Wang X-Patchwork-Id: 145697 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:cae8:0:b0:403:3b70:6f57 with SMTP id r8csp3029380vqu; Wed, 27 Sep 2023 19:34:15 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEXo2K6zzgLZXFUiesCA+t5tlzABq+TXOmabcsAmvMpDblqtcvcCVB5pa+ABg1Ac9WjBFU1 X-Received: by 2002:a05:6830:16c9:b0:6b9:58dc:a2d9 with SMTP id l9-20020a05683016c900b006b958dca2d9mr3841940otr.28.1695868455040; Wed, 27 Sep 2023 19:34:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695868455; cv=none; d=google.com; s=arc-20160816; b=blZCemNSkfmTSDqbG3Br5p6yH0T9nHLlvwK6apugcmLiSRLKqYziEcGj9ygHlviBUR g7jI/YRSEnZNydTVfq5ZcZY+SOKzbEAjo2J8DOSlBbb1gMpmgQjhNpR+OLjqVKpTTMv6 jGFPH34b4UnOUgem7AcP+xRTbUf9xu8DHg0vms7F9eTYiG6qVe61sj5/cwSu1Eg9WKOZ asYq4u5GzBa2DSmHxMevDhsRxHwydR3pAexhzPDrVNL4wHCg3FbOxTCoZf1uLhNjUPGt siKoUHqYbIuBcquw1ib+qYkX34KPAlxHrkHzqHwLifhKTFGqUvJZ4HPKZoxX97Beg+BX FV2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:mime-version :content-transfer-encoding:subject:cc:to:from:date; bh=ST5CoLz805jgO1yz0yLjolX6bzIR3bvzR73iHSMja5g=; fh=7XxrSkeWz746vvy4RO2T3/Acu1znasH/bthfsQTCQZk=; b=XTY27K8ZeRIb5VkDUPZvD/NAP0bRNZfeWAih+bISkaLmrwwCxg1GMMxSDm/01+lMLy ThFiqeBeh/m4iPAOQJIRlcr9GVdyyPWS/p5PRlzpfyX+/4LrkzQ3v/i5SxEvdtWHKsZx dwZNO1w0N/YZIVxPXFal2n6Y/ZqBWXLQWtIT3EsgIBUFxPcu+8lNgY2/QJwLxfpBEF2w 3LMKQDtxZnsFH5oxvFUrjVHog66Bqiua2OkxMH4p+7nTQjF1qQb31AvLAd3phV2184Fd Uw5QTU0UCjveleOSX3xHgJNwq3pdQmRAy96GOyxLdN1dbjT5hdyrqKw60POD+Y+nIjfv 3TqA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id x19-20020aa793b3000000b0068fcff1dc3asi15848047pff.339.2023.09.27.19.34.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 19:34:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 53FB081ADCC4; Wed, 27 Sep 2023 19:33:55 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230061AbjI1Cd0 (ORCPT + 20 others); Wed, 27 Sep 2023 22:33:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58658 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229469AbjI1CdZ (ORCPT ); Wed, 27 Sep 2023 22:33:25 -0400 Received: from jari.cn (unknown [218.92.28.115]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 95C4894; Wed, 27 Sep 2023 19:33:21 -0700 (PDT) Received: from wangkailong$jari.cn ( [182.148.12.64] ) by ajax-webmail-localhost.localdomain (Coremail) ; Thu, 28 Sep 2023 10:32:02 +0800 (GMT+08:00) X-Originating-IP: [182.148.12.64] Date: Thu, 28 Sep 2023 10:32:02 +0800 (GMT+08:00) X-CM-HeaderCharset: UTF-8 From: "KaiLong Wang" To: jejb@linux.ibm.com, martin.petersen@oracle.com Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] scsi: lpfc: Clean up errors in lpfc_debugfs.c X-Priority: 3 X-Mailer: Coremail Webmail Server Version 2023.1-cmXT6 build 20230419(ff23bf83) Copyright (c) 2002-2023 www.mailtech.cn mispb-4e503810-ca60-4ec8-a188-7102c18937cf-zhkzyfz.cn MIME-Version: 1.0 Message-ID: <7f56629a.8a3.18ad9a1036f.Coremail.wangkailong@jari.cn> X-Coremail-Locale: zh_CN X-CM-TRANSID: AQAAfwDXaD6i5RRli3y+AA--.585W X-CM-SenderInfo: 5zdqwypdlo00nj6mt2flof0/1tbiAQAJB2T8PZMAAQAgsY X-Coremail-Antispam: 1Ur529EdanIXcx71UUUUU7IcSsGvfJ3iIAIbVAYjsxI4VWxJw CS07vEb4IE77IF4wCS07vE1I0E4x80FVAKz4kxMIAIbVAFxVCaYxvI4VCIwcAKzIAtYxBI daVFxhVjvjDU= X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Wed, 27 Sep 2023 19:33:55 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1778246961188294198 X-GMAIL-MSGID: 1778246961188294198 Fix the following errors reported by checkpatch: ERROR: else should follow close brace '}' ERROR: spaces required around that '=' (ctx:VxV) ERROR: spaces required around that '<' (ctx:VxV) Signed-off-by: KaiLong Wang --- drivers/scsi/lpfc/lpfc_debugfs.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/scsi/lpfc/lpfc_debugfs.c b/drivers/scsi/lpfc/lpfc_debugfs.c index ea9b42225e62..fa037c70aa96 100644 --- a/drivers/scsi/lpfc/lpfc_debugfs.c +++ b/drivers/scsi/lpfc/lpfc_debugfs.c @@ -299,8 +299,7 @@ lpfc_debugfs_hbqinfo_data(struct lpfc_hba *phba, char *buf, int size) lpfc_debugfs_last_hbq++; if (lpfc_debugfs_last_hbq >= i) lpfc_debugfs_last_hbq = 0; - } - else + } else lpfc_debugfs_last_hbq = 0; i = lpfc_debugfs_last_hbq; @@ -326,7 +325,7 @@ lpfc_debugfs_hbqinfo_data(struct lpfc_hba *phba, char *buf, int size) hbqs->next_hbqPutIdx, hbqs->local_hbqGetIdx, getidx); hbqe = (struct lpfc_hbq_entry *) phba->hbqs[i].hbq_virt; - for (j=0; jentry_count; j++) { + for (j = 0; j < hbqs->entry_count; j++) { len += scnprintf(buf+len, size-len, "%03d: %08x %04x %05x ", j, le32_to_cpu(hbqe->bde.addrLow), @@ -343,8 +342,7 @@ lpfc_debugfs_hbqinfo_data(struct lpfc_hba *phba, char *buf, int size) "Unused\n"); goto skipit; } - } - else { + } else { if ((j >= hbqs->hbqPutIdx) && (j < (hbqs->entry_count+low))) { len += scnprintf(buf + len, size - len,