Received: by 10.213.65.68 with SMTP id h4csp442697imn; Tue, 13 Mar 2018 09:11:13 -0700 (PDT) X-Google-Smtp-Source: AG47ELt/xIFQ/1/RcDiqjk7TzEB2x9PligAhwGXt+Air9/UE18BDKMT8PKMLxX3Gn26e+E11pYAz X-Received: by 10.101.81.76 with SMTP id g12mr948658pgq.88.1520957472952; Tue, 13 Mar 2018 09:11:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1520957472; cv=none; d=google.com; s=arc-20160816; b=sR60uhJN+0JKMM0WC+AElt4Xwt9c/q4pT4mpSgPhc3ZQu7tS7qsOMzYTrLoPZwX//I C1y9JoSI1bJn2LZJc6G3LTCgeXWdXgZTlqDWskBDlyVprRFl9eDo+P7eHINnMKEiEg2Q eXh5eYF41wXaTR0BZ3oH/AgsbzqG2wTjB6pdU7g82sWAwC/ZBsSpTemO75YLclVXvhCI ZlDZD2+6hOZk9vZf4rhUPNn+eNGhlebk1IphDiEtLpjjiwWrS1mE/ZnHrvvqOneZS5ym tCWV9LW2pjIDnNP9wkskyHqyM0DBgPDwcnapZS4XR/WPPgv8OrIEN4GjWa+dChW3abtU cyCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=Fv0jtHECIzveoyDenDDor5yvvPZ3KrrJSzkIsjIw0Jg=; b=fQKc2xYp8y1v1L9jXfMToztRAJAtjSq6sZTEJ87HletHRLwvRXWouXRCI/VInZq7ac GY9qGiGhpC52TV7cBDEm815WSDTaa97IMhYi1vy2wgjgxfjlMndtv2GQfr8zgY96UvXx Qp++6seWkdSKihlOg6pDMFqAOE7H4Dk3ieTm0yPf2GZPejnFE4qJ6fFjzN9iEAjsGA6y UOo60f5/FcNujIzt2ilMMHK284dfikjNs90p4UG7Lxz6jzh79tefvjJgJU3oHSooyRMX tHp1eqjQCK0hLXxQX1PzTz5KEXvSYCvnzzFid3PpYybf3I/rGUZfdpcHVafRc1kIqrM6 w9nw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 197si297742pge.78.2018.03.13.09.10.58; Tue, 13 Mar 2018 09:11:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934194AbeCMPgX (ORCPT + 99 others); Tue, 13 Mar 2018 11:36:23 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:33530 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934168AbeCMPgT (ORCPT ); Tue, 13 Mar 2018 11:36:19 -0400 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id A0A5011CC; Tue, 13 Mar 2018 15:36:18 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Quinn Tran , Himanshu Madhani , Hannes Reinecke , "Martin K. Petersen" Subject: [PATCH 4.14 026/140] scsi: qla2xxx: Move session delete to driver work queue Date: Tue, 13 Mar 2018 16:23:49 +0100 Message-Id: <20180313152459.771533935@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180313152458.201155692@linuxfoundation.org> References: <20180313152458.201155692@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: Quinn Tran commit a01c77d2cbc45ba527e884e5c30363a1200a4130 upstream. Move session delete from system work queue to driver's work queue for in time processing. Fixes: 726b85487067d ("qla2xxx: Add framework for async fabric discovery") Cc: # 4.10+ Signed-off-by: Quinn Tran Signed-off-by: Himanshu Madhani Reviewed-by: Hannes Reinecke Signed-off-by: Martin K. Petersen Signed-off-by: Greg Kroah-Hartman --- drivers/scsi/qla2xxx/qla_os.c | 3 ++- drivers/scsi/qla2xxx/qla_target.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c @@ -3177,10 +3177,11 @@ qla2x00_probe_one(struct pci_dev *pdev, host->can_queue, base_vha->req, base_vha->mgmt_svr_loop_id, host->sg_tablesize); + ha->wq = alloc_workqueue("qla2xxx_wq", WQ_MEM_RECLAIM, 0); + if (ha->mqenable) { bool mq = false; bool startit = false; - ha->wq = alloc_workqueue("qla2xxx_wq", WQ_MEM_RECLAIM, 0); if (QLA_TGT_MODE_ENABLED()) { mq = true; --- a/drivers/scsi/qla2xxx/qla_target.c +++ b/drivers/scsi/qla2xxx/qla_target.c @@ -1205,7 +1205,8 @@ void qlt_schedule_sess_for_deletion(stru ql_dbg(ql_dbg_tgt, sess->vha, 0xe001, "Scheduling sess %p for deletion\n", sess); - schedule_work(&sess->del_work); + INIT_WORK(&sess->del_work, qla24xx_delete_sess_fn); + queue_work(sess->vha->hw->wq, &sess->del_work); } void qlt_schedule_sess_for_deletion_lock(struct fc_port *sess)