Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755568AbbFRMKh (ORCPT ); Thu, 18 Jun 2015 08:10:37 -0400 Received: from p02c11o148.mxlogic.net ([208.65.144.81]:35030 "EHLO p02c11o148.mxlogic.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755500AbbFRMKV (ORCPT ); Thu, 18 Jun 2015 08:10:21 -0400 X-MXL-Hash: 5582b52d7c5eceef-af0ccdaa5ce0c26b205306d2f8c3e154205f2eaf X-MXL-Hash: 5582b52c203ae629-06c115b6675d6345713452d0a607b3e1b0976227 Message-ID: <5582B51C.8070700@stratus.com> Date: Thu, 18 Jun 2015 08:10:04 -0400 From: Joe Lawrence User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: Sreekanth Reddy , , , CC: , , , , , Tejun Heo Subject: Re: [PATCH 17/20 v1] [SCSI] mpt3sas: Use alloc_ordered_workqueue() API instead of create_singlethread_workqueue() API References: <1434433027-40682-1-git-send-email-Sreekanth.Reddy@avagotech.com> In-Reply-To: <1434433027-40682-1-git-send-email-Sreekanth.Reddy@avagotech.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Originating-IP: [134.111.23.53] X-AnalysisOut: [v=2.1 cv=baZ/UY/B c=1 sm=1 tr=0 a=o2bo05G+d1rlxuoNbFVhCw==] X-AnalysisOut: [:117 a=o2bo05G+d1rlxuoNbFVhCw==:17 a=rkJuIV0pGx0A:10 a=Aou] X-AnalysisOut: [ev_fMsXUA:10 a=BLceEmwcHowA:10 a=N659UExz7-8A:10 a=uelBKuK] X-AnalysisOut: [pAAAA:8 a=YlVTAMxIAAAA:8 a=XAFQembCKUMA:10 a=3rmPD-3EAAAA:] X-AnalysisOut: [8 a=EBgz8XrkWnhFV_gr2f0A:9 a=pILNOxqGKmIA:10] X-Spam: [F=0.5000000000; CM=0.500; MH=0.500(2015061803); S=0.200(2014051901)] X-MAIL-FROM: X-SOURCE-IP: [134.111.1.18] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2133 Lines: 51 On 06/16/2015 01:37 AM, Sreekanth Reddy wrote: > Created a thread using alloc_ordered_workqueue() API in order to process > the works from firmware Work-queue sequentially instead of > create_singlethread_workqueue() API. > > Changes in v1: > No need to check for backport compatibility in the upstream kernel. > so removing the else section where driver use > create_singlethread_workqueue() API if alloc_ordered_workqueue() API is > not defined, This else section is not required since in the latest upstream > kernel this alloc_ordered_workqueue() API is always defined. > > Signed-off-by: Sreekanth Reddy > --- > drivers/scsi/mpt3sas/mpt3sas_scsih.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/scsi/mpt3sas/mpt3sas_scsih.c b/drivers/scsi/mpt3sas/mpt3sas_scsih.c > index b848458..7e5926c 100644 > --- a/drivers/scsi/mpt3sas/mpt3sas_scsih.c > +++ b/drivers/scsi/mpt3sas/mpt3sas_scsih.c > @@ -8085,8 +8085,8 @@ _scsih_probe(struct pci_dev *pdev, const struct pci_device_id *id) > /* event thread */ > snprintf(ioc->firmware_event_name, sizeof(ioc->firmware_event_name), > "fw_event%d", ioc->id); > - ioc->firmware_event_thread = create_singlethread_workqueue( > - ioc->firmware_event_name); > + ioc->firmware_event_thread = alloc_ordered_workqueue( > + ioc->firmware_event_name, WQ_MEM_RECLAIM); > if (!ioc->firmware_event_thread) { > pr_err(MPT3SAS_FMT "failure at %s:%d/%s()!\n", > ioc->name, __FILE__, __LINE__, __func__); > Hi Sreekanth, Is this change still needed after e09c2c2954684 workqueue: apply __WQ_ORDERED to create_singlethread_workqueue() ? (3.17+) In upstream, this change looks cosmetic (unless Tejun has a preference for one over the other), but maybe converting to alloc_ordered_workqueue keeps your in house version in closer sync? Thanks, -- Joe -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/