From patchwork Fri Aug 5 06:48:43 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chaitra P B X-Patchwork-Id: 9264831 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 451F56048B for ; Fri, 5 Aug 2016 06:49:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3707128236 for ; Fri, 5 Aug 2016 06:49:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2BE0628424; Fri, 5 Aug 2016 06:49:21 +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.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID 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 A8C1E28236 for ; Fri, 5 Aug 2016 06:49:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030403AbcHEGtT (ORCPT ); Fri, 5 Aug 2016 02:49:19 -0400 Received: from mail-qk0-f178.google.com ([209.85.220.178]:34572 "EHLO mail-qk0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030399AbcHEGtS (ORCPT ); Fri, 5 Aug 2016 02:49:18 -0400 Received: by mail-qk0-f178.google.com with SMTP id p186so129255688qkd.1 for ; Thu, 04 Aug 2016 23:48:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:references:in-reply-to:mime-version:thread-index:date :message-id:subject:to:cc; bh=zYxbozNyXUfnlhYh7LB4NB6PTef8exvc3iAXX7xBMlM=; b=iMcPH90AOcC2lgeisxYEMkUbj8Okq3g+YuVfbIJa0iyUIiwPODvg2q2l9/BoGeZKj5 0v/S8rOR6I8uuszPlqHHmspybqn7+eVZCXoFwG5IT1HJMaqfwntnicFVIFnQ1/oUt9ja JgW8rOvJ9nHQCxEtc/BLH9A31OBMJ98Ep1qhQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:references:in-reply-to:mime-version :thread-index:date:message-id:subject:to:cc; bh=zYxbozNyXUfnlhYh7LB4NB6PTef8exvc3iAXX7xBMlM=; b=DM990SSBouVEBPICoS6EkisZ5kB/7TrnM0hQjMTjrH3PGwRlQPWEDnH/l1/iUrghjr nacqBy5vYlyT7Lk0b9JCQ2l8DUjwOAt771KLjgE5hbMmHVB27ib8GBYZoE9rlJFq6EG0 kkDaAKVOWLkaUKjTwIRLXyYW9QsxSG2g9VuOaUIfDrc3qMYBZFQsYdEFgvMFy3AwIQyf xxO1n1bl1hnYknXSexudTkw0IMX6NfOrba482xVNv1M8n7alAve6SKJIBM+ZQASyNgiM XklMy5uUp7KMEbl9XhsTvNo5O6GraCpro+efTX6Ns6Fbw35jYIkefUGXjwTHOhIURflq 8LCQ== X-Gm-Message-State: AEkoouuGG0F1u4h1hKlly0ujlJOCmXl+vGL/C8ScTy6fFEPwxgz2jW/zblnJGScdNUMAUaUNincB1c/uO5i1tDKs X-Received: by 10.55.156.135 with SMTP id f129mr10956393qke.155.1470379723780; Thu, 04 Aug 2016 23:48:43 -0700 (PDT) From: Chaitra Basappa References: <1470229218-22040-1-git-send-email-jthumshirn@suse.de> In-Reply-To: <1470229218-22040-1-git-send-email-jthumshirn@suse.de> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQDz3ILwn/+ZNONrCHGh2y1EsCo9B6H2EbFQ Date: Fri, 5 Aug 2016 12:18:43 +0530 Message-ID: Subject: RE: [PATCH] mpt3sas: Don't spam logs if logging level is 0 To: Johannes Thumshirn , "Martin K . Petersen" , James Bottomley Cc: Linux SCSI Mailinglist , Linux Kernel Mailinglist , Sreekanth Reddy 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 Hi, Please consider this patch as Acked-by: Chaitra P B Thanks, Chaitra -----Original Message----- From: linux-scsi-owner@vger.kernel.org [mailto:linux-scsi-owner@vger.kernel.org] On Behalf Of Johannes Thumshirn Sent: Wednesday, August 03, 2016 6:30 PM To: Martin K . Petersen; James Bottomley Cc: Linux SCSI Mailinglist; Linux Kernel Mailinglist; Sreekanth Reddy; Johannes Thumshirn Subject: [PATCH] mpt3sas: Don't spam logs if logging level is 0 In _scsih_io_done() we test if the ioc->logging_level does _not_ have the MPT_DEBUG_REPLY bit set and if it hasn't we print the debug messages. This unfortunately is the wrong way around. Note, the actual bug is older than af0094115 but this commit removed the CONFIG_SCSI_MPT3SAS_LOGGING Kconfig option which hid the bug. Fixes: af0094115 'mpt2sas, mpt3sas: Remove SCSI_MPTXSAS_LOGGING entry from Kconfig' Signed-off-by: Johannes Thumshirn --- drivers/scsi/mpt3sas/mpt3sas_scsih.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (scmd->sense_buffer[2] == HARDWARE_ERROR))) -- 1.8.5.6 -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/scsi/mpt3sas/mpt3sas_scsih.c b/drivers/scsi/mpt3sas/mpt3sas_scsih.c index 4a1cc85..a138690 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_scsih.c +++ b/drivers/scsi/mpt3sas/mpt3sas_scsih.c @@ -4693,7 +4693,7 @@ _scsih_io_done(struct MPT3SAS_ADAPTER *ioc, u16 smid, u8 msix_index, u32 reply) le16_to_cpu(mpi_reply->DevHandle)); mpt3sas_trigger_scsi(ioc, data.skey, data.asc, data.ascq); - if (!(ioc->logging_level & MPT_DEBUG_REPLY) && + if ((ioc->logging_level & MPT_DEBUG_REPLY) && ((scmd->sense_buffer[2] == UNIT_ATTENTION) || (scmd->sense_buffer[2] == MEDIUM_ERROR) ||