From patchwork Fri Apr 1 18:04:31 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurence Oberman X-Patchwork-Id: 8726971 Return-Path: X-Original-To: patchwork-linux-scsi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 10F85C0553 for ; Fri, 1 Apr 2016 18:04:43 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 30EC3203B1 for ; Fri, 1 Apr 2016 18:04:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DE7FF203AA for ; Fri, 1 Apr 2016 18:04:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753209AbcDASEk (ORCPT ); Fri, 1 Apr 2016 14:04:40 -0400 Received: from mx5-phx2.redhat.com ([209.132.183.37]:50075 "EHLO mx5-phx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753149AbcDASEj (ORCPT ); Fri, 1 Apr 2016 14:04:39 -0400 Received: from zmail22.collab.prod.int.phx2.redhat.com (zmail22.collab.prod.int.phx2.redhat.com [10.5.83.26]) by mx5-phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u31I4Vaw056742; Fri, 1 Apr 2016 14:04:32 -0400 Date: Fri, 1 Apr 2016 14:04:31 -0400 (EDT) From: Laurence Oberman To: Joe Lawrence Cc: linux-scsi@vger.kernel.org, Sathya Prakash , Chaitra P B , Suganath Prabu Subramani , Calvin Owens Message-ID: <38412222.26431428.1459533871879.JavaMail.zimbra@redhat.com> In-Reply-To: <1459533389-19648-1-git-send-email-joe.lawrence@stratus.com> References: <1459533389-19648-1-git-send-email-joe.lawrence@stratus.com> Subject: Re: [PATCH] mpt3sas - remove unused fw_event_work delayed_work MIME-Version: 1.0 X-Originating-IP: [10.18.49.58] X-Mailer: Zimbra 8.0.6_GA_5922 (ZimbraWebClient - FF38 (Linux)/8.0.6_GA_5922) Thread-Topic: mpt3sas - remove unused fw_event_work delayed_work Thread-Index: AhcuvZZSiAtGn6VECU8Hxc0cc8Xr7A== Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Spam-Status: No, score=-7.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Looks fine to me. Reviewed-by: Laurence Oberman Laurence Oberman Principal Software Maintenance Engineer Red Hat Global Support Services ----- Original Message ----- From: "Joe Lawrence" To: linux-scsi@vger.kernel.org Cc: "Sathya Prakash" , "Chaitra P B" , "Suganath Prabu Subramani" , "Calvin Owens" , "Joe Lawrence" Sent: Friday, April 1, 2016 1:56:29 PM Subject: [PATCH] mpt3sas - remove unused fw_event_work delayed_work The driver's fw events are queued up using the the fw_event_work's struct work, not its delayed_work member. The latter appears to be unused and may provoke CONFIG_DEBUG_OBJECTS_TIMERS "assert_init not available" false warnings in _scsih_fw_event_cleanup_queue. Remove it and update _scsih_fw_event_cleanup_queue accordingly. Signed-off-by: Joe Lawrence --- I think this goes all the way back to the introduction of the mpt3sas driver. The previous generation mpt2sas driver uses delayed_work, so perhaps it was simply copied and pasted into the mpt3sas but never updated. drivers/scsi/mpt3sas/mpt3sas_scsih.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/mpt3sas/mpt3sas_scsih.c b/drivers/scsi/mpt3sas/mpt3sas_scsih.c index e0e4920d0fa6..67643602efbc 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_scsih.c +++ b/drivers/scsi/mpt3sas/mpt3sas_scsih.c @@ -189,7 +189,6 @@ struct fw_event_work { struct list_head list; struct work_struct work; u8 cancel_pending_work; - struct delayed_work delayed_work; struct MPT3SAS_ADAPTER *ioc; u16 device_handle; @@ -2804,12 +2803,12 @@ _scsih_fw_event_cleanup_queue(struct MPT3SAS_ADAPTER *ioc) /* * Wait on the fw_event to complete. If this returns 1, then * the event was never executed, and we need a put for the - * reference the delayed_work had on the fw_event. + * reference the work had on the fw_event. * * If it did execute, we wait for it to finish, and the put will * happen from _firmware_event_work() */ - if (cancel_delayed_work_sync(&fw_event->delayed_work)) + if (cancel_work_sync(&fw_event->work)) fw_event_work_put(fw_event); fw_event_work_put(fw_event);