From patchwork Fri Nov 3 22:56:19 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Smart X-Patchwork-Id: 10041293 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 20B8960384 for ; Fri, 3 Nov 2017 22:56:53 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 131EA299CE for ; Fri, 3 Nov 2017 22:56:53 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 07FE0299E1; Fri, 3 Nov 2017 22:56:53 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A629E299CE for ; Fri, 3 Nov 2017 22:56:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752582AbdKCW4u (ORCPT ); Fri, 3 Nov 2017 18:56:50 -0400 Received: from mail-qk0-f193.google.com ([209.85.220.193]:44606 "EHLO mail-qk0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751568AbdKCW4p (ORCPT ); Fri, 3 Nov 2017 18:56:45 -0400 Received: by mail-qk0-f193.google.com with SMTP id r64so5067332qkc.1 for ; Fri, 03 Nov 2017 15:56:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=hEKUaJ64YZ9WvEmPoaqGZ2FFq3oPFhTDnaOoXcK6Ogs=; b=knr2OknZMqe+PNtLF35oCro1p58AN/C0YTx2/w2WBKmCOrVC8hlJywYLlTwslSS1Yy CW09pp+V3YCl+Mbp/yJlLDESZaPS/RZn9s5l44E3sYETHV+EnStWfc11m01OpiYXcnW1 NHcyv4kNRjYjxelyztoSFiKsmPLS2W42falPCjlqoPeZIpidrbuZ95aAQZFtPdbqExkt DoL302QNBZSY7ADBYFh7aTFn92P6DWnnBz92bTyS5zLcU2no+c8AZihrGCNH8BRmQMhQ 1CD4N7satgWgvitOg3KFBm5WZIq6kbYZ31df9+hNJltv06ihgvgbZE74qAhFw1DChQ6j rkig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=hEKUaJ64YZ9WvEmPoaqGZ2FFq3oPFhTDnaOoXcK6Ogs=; b=XnY6YuIdj2beThjYeJhVN7rsEL7gt1tXpq7inQaki6Fo1R1NOD0l4mFxMX+y52MDap 5HKRFKiXhDcYrnSj6ZF+9fcpwEB11NFzBmO0AZtd9k0Hsca5/hscsG3UvnYF3QJaAEdU hA7RkjxdqtuY2/VtVmjyQEe94goGV++zgUFOQzYys7JGxa64h0Y5i5Z07cyb7FDHPaMN qFJcW2d/B6o7XgPNjUp0gFi8nlKtSpocVxPh3VnK9NEQFlwTIuSiytitUgDOEZw/kgfK sx1XFDGX3d5yTJxuB5+HuIMcuyjAeYqZAkFpszxaNGRokHjD+kER7OsvB63Qi7F7ZnPl IJHQ== X-Gm-Message-State: AMCzsaVL7dt86jqtKmMiSH97143w0t5UnnGCq4d5xJfVSeePi8Qb015r F5836JopIHmseoUKSRZbSpfi96K2 X-Google-Smtp-Source: ABhQp+RBdqZQahIv4cobEbe/xzvXhse4KQ0Vr+jqaqvh6XJANm9wWgHS4uHk7VKcMvC9+sgL5qNM3w== X-Received: by 10.55.19.219 with SMTP id 88mr11493111qkt.33.1509749804903; Fri, 03 Nov 2017 15:56:44 -0700 (PDT) Received: from pallmd1.broadcom.com ([192.19.255.250]) by smtp.gmail.com with ESMTPSA id v21sm4765626qtv.21.2017.11.03.15.56.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 03 Nov 2017 15:56:44 -0700 (PDT) From: James Smart To: linux-scsi@vger.kernel.org Cc: James Smart , Dick Kennedy , James Smart Subject: [PATCH 08/17] lpfc: Fix display for debugfs queInfo Date: Fri, 3 Nov 2017 15:56:19 -0700 Message-Id: <20171103225628.24716-9-jsmart2021@gmail.com> X-Mailer: git-send-email 2.13.1 In-Reply-To: <20171103225628.24716-1-jsmart2021@gmail.com> References: <20171103225628.24716-1-jsmart2021@gmail.com> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Display for lpfc/fnX/iDiag/queInfo isn't formatted perfectly. Corrected the format strings for the queue info debug messages. Signed-off-by: Dick Kennedy Signed-off-by: James Smart Reviewed-by: Hannes Reinecke --- drivers/scsi/lpfc/lpfc_debugfs.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/scsi/lpfc/lpfc_debugfs.c b/drivers/scsi/lpfc/lpfc_debugfs.c index d50c481ec41c..e8c5a0927dd7 100644 --- a/drivers/scsi/lpfc/lpfc_debugfs.c +++ b/drivers/scsi/lpfc/lpfc_debugfs.c @@ -3248,7 +3248,7 @@ __lpfc_idiag_print_eq(struct lpfc_queue *qp, char *eqtype, len += snprintf(pbuffer + len, LPFC_QUE_INFO_GET_BUF_SIZE - len, "\n%s EQ info: EQ-STAT[max:x%x noE:x%x " - "bs:x%x proc:x%llx eqd %d]\n", + "cqe_proc:x%x eqe_proc:x%llx eqd %d]\n", eqtype, qp->q_cnt_1, qp->q_cnt_2, qp->q_cnt_3, (unsigned long long)qp->q_cnt_4, qp->q_mode); len += snprintf(pbuffer + len, LPFC_QUE_INFO_GET_BUF_SIZE - len, @@ -3368,6 +3368,12 @@ lpfc_idiag_queinfo_read(struct file *file, char __user *buf, size_t nbytes, if (len >= max_cnt) goto too_big; + qp = phba->sli4_hba.hdr_rq; + len = __lpfc_idiag_print_rqpair(qp, phba->sli4_hba.dat_rq, + "ELS RQpair", pbuffer, len); + if (len >= max_cnt) + goto too_big; + /* Slow-path NVME LS response CQ */ qp = phba->sli4_hba.nvmels_cq; len = __lpfc_idiag_print_cq(qp, "NVME LS", @@ -3385,12 +3391,6 @@ lpfc_idiag_queinfo_read(struct file *file, char __user *buf, size_t nbytes, if (len >= max_cnt) goto too_big; - qp = phba->sli4_hba.hdr_rq; - len = __lpfc_idiag_print_rqpair(qp, phba->sli4_hba.dat_rq, - "RQpair", pbuffer, len); - if (len >= max_cnt) - goto too_big; - goto out; }