From patchwork Fri Nov 10 01:08:25 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Smart X-Patchwork-Id: 10052221 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 1157F6032D for ; Fri, 10 Nov 2017 01:09:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 030142B225 for ; Fri, 10 Nov 2017 01:09:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EC1C12B227; Fri, 10 Nov 2017 01:09:01 +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 743442B228 for ; Fri, 10 Nov 2017 01:09:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755545AbdKJBJA (ORCPT ); Thu, 9 Nov 2017 20:09:00 -0500 Received: from mail-qk0-f194.google.com ([209.85.220.194]:51530 "EHLO mail-qk0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755517AbdKJBIv (ORCPT ); Thu, 9 Nov 2017 20:08:51 -0500 Received: by mail-qk0-f194.google.com with SMTP id n66so10106057qki.8 for ; Thu, 09 Nov 2017 17:08:51 -0800 (PST) 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=hpFss1twtZ+OsObNzDNnospkl6q5ei04/Kpeb9z55RY=; b=d2GmwfBnpmdhTGh8v9j9CnclmXd6KJik2BifSRQnm1xm+AqXl3MKBLSWueX0yKfMne AtFs4G+b3uXTM6G8nikKKVyzG5q5Y5lBef4kRZVUBnPUQttSeZHr9zxWPJiBC8a21tpX RyB9CaVb2CJQLhjp36Bx8jL0cGEbLDI5dMEiJv4MYkNwPx+VxYXG4A+uU6Fz6wmviaQF 5uu6TCXZ37wPQNmF2zdbrYW2XXsUEnn+01VcDR17p/0V6ttivYyMKvnMdVGQOiO9uh1R mGO2XNlG4+oZJHva6CwLRmt55gscCUcAOPHxBLIo2epe9+S0mY1CUQuM+/GDk+dDUSk3 d+mg== 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=hpFss1twtZ+OsObNzDNnospkl6q5ei04/Kpeb9z55RY=; b=rJXvbz17x/OA7Rz225uafbATxpCFIBQh1UKwNG5QdqsY+3lWovXIM2f6jZpRC+VM3q htzAqHjqAM2A1bD0m4ECTyHkQZDnZiJEeDYUjE4Zy8C1p5MYfPvzBzIfysbvd+o5z3lH Kjv3ke7JE+XVsexBABoYxKA3zjIdLhuDAaj5fLwou0Ug1DYdvIwvPOkECqRsqnldNKfx pTWoRD2q4kO0nMze+FAlrWF+VEjY6rSqXEEeeTuNFY03i7ALwrdMUAPv+qUwjOqWCG5V dsdvm+yDyMgx6z4vlQbM6E0KVeaPvBFy5ljl91husQ1IUa8quGtiJ6PUZIug0J54EBMg 0lUA== X-Gm-Message-State: AJaThX6/022/1YTZvMaPLL0u4EpuU6l7UcgDBZxKvV3cbExtFRjoSdbM WkNrxsf4Y1foarDVdAs5EuYA9mpS X-Google-Smtp-Source: AGs4zMa7fjR6MxGKWK1AvMNx5GRbhcIExC1m64EUrWtTXTAsnJJrBimchz3fsqjuQduPtirB9npCcw== X-Received: by 10.55.26.90 with SMTP id a87mr3710342qka.184.1510276130653; Thu, 09 Nov 2017 17:08:50 -0800 (PST) Received: from pallmd1.broadcom.com ([192.19.255.250]) by smtp.gmail.com with ESMTPSA id j48sm5661969qta.96.2017.11.09.17.08.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 09 Nov 2017 17:08:50 -0800 (PST) From: James Smart To: linux-scsi@vger.kernel.org Cc: James Smart , Dick Kennedy , James Smart Subject: [PATCH v2 08/17] lpfc: Fix display for debugfs queInfo Date: Thu, 9 Nov 2017 17:08:25 -0800 Message-Id: <20171110010834.4542-9-jsmart2021@gmail.com> X-Mailer: git-send-email 2.13.1 In-Reply-To: <20171110010834.4542-1-jsmart2021@gmail.com> References: <20171110010834.4542-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; }