Received: by 10.213.65.68 with SMTP id h4csp274456imn; Fri, 23 Mar 2018 04:29:37 -0700 (PDT) X-Google-Smtp-Source: AG47ELtZ5ids30opufc1ObMRqtkHVqbz+ZJ9JvGUfVcWavKiur2wktLFEvZSbJ2PzkbyjtyW87rH X-Received: by 2002:a17:902:7142:: with SMTP id u2-v6mr28937502plm.257.1521804577735; Fri, 23 Mar 2018 04:29:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521804577; cv=none; d=google.com; s=arc-20160816; b=ePJlxd9qoosWC/Ll0il5iqaIa8fsEVNkP2rZRMaMSTygd94GUhqocPdgPDZEfXjOGi vsrm09bewfbWszr0lhfunR4e8saSbbnifePCimoAyrd3u+FQ/GnBn16odK+EtLZIfzBe /7GfCITyZGTFm1JERVrhV9qsnzoYsc3QcqVubMMirOY+W6OVgVjAHwkqoZi7iVGcjtQs FreDp4fgL5XyTtAu2aMFmhAzkYGQEA4YaX3x9bvP6YM0g1Nf+xZxd2B7E5v2pYTKa1bq LzJriP2Yn7YBSr+UD+0J2xHPl0gFPLm76qNvKo7VP7UkkHh8KjL8UpvZcrnmMlXQbyoT cisg== 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=fxclqcxPwyMWUp3IMPxurM2eKV5nAI8NV6kQ6egfjuc=; b=FVCw+1JKkultHSZz/KyIf7HxRkCoFLveaymBNLsuDE73ubOnp3XRlje417wdrboNS8 NDSwT+fU4vRj4LoJNz5USwSRek5U/DsCwoiq9jj+pXlbSnwo4bVjmUGLqgoouzz2LS7D BJ7/XO/v+QISgphMs0yTiShRtKL2yqPMymalt0nRSJOFIRkF2pViAQRpJVkQWN1dTnvU NPpiJJBdHSnV3xvJXamrbzL5mXnnQ2rtm4IEsfCEgY7xYlDOKcMjwJIGOl5fKFcbHyJv Ui+88iZhGOeBQYLY2sZxMpPKmjBHkA3zm972xw8A2yjPaMYkcyL2znbo4uBHJmAQ2k9b GKCw== 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 f7si5840175pgq.505.2018.03.23.04.29.23; Fri, 23 Mar 2018 04:29:37 -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 S1755441AbeCWL2c (ORCPT + 99 others); Fri, 23 Mar 2018 07:28:32 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:40990 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932222AbeCWKGw (ORCPT ); Fri, 23 Mar 2018 06:06:52 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 5D7BACEC; Fri, 23 Mar 2018 10:06:51 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dick Kennedy , James Smart , Johannes Thumshirn , Sasha Levin Subject: [PATCH 4.9 056/177] Fix Express lane queue creation. Date: Fri, 23 Mar 2018 10:53:04 +0100 Message-Id: <20180323094207.820786672@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180323094205.090519271@linuxfoundation.org> References: <20180323094205.090519271@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.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: James Smart [ Upstream commit 7e04e21afa82ef024416f5413b5bdb66e0505bcd ] The older sli4 adapters only supported the 64 byte WQE entry size. The new adapter (fw) support both 64 and 128 byte WQE entry sizies. The Express lane WQ was not being created with the 128 byte WQE sizes when it was supported. Not having the right WQE size created for the express lane work queue caused the the firmware to overwrite the lun indentifier in the FCP header. This patch correctly creates the express lane work queue with the supported size. Signed-off-by: Dick Kennedy Signed-off-by: James Smart Reviewed-by: Johannes Thumshirn Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/scsi/lpfc/lpfc_init.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) --- a/drivers/scsi/lpfc/lpfc_init.c +++ b/drivers/scsi/lpfc/lpfc_init.c @@ -11312,6 +11312,7 @@ int lpfc_fof_queue_create(struct lpfc_hba *phba) { struct lpfc_queue *qdesc; + uint32_t wqesize; /* Create FOF EQ */ qdesc = lpfc_sli4_queue_alloc(phba, phba->sli4_hba.eq_esize, @@ -11332,8 +11333,11 @@ lpfc_fof_queue_create(struct lpfc_hba *p phba->sli4_hba.oas_cq = qdesc; /* Create OAS WQ */ - qdesc = lpfc_sli4_queue_alloc(phba, phba->sli4_hba.wq_esize, + wqesize = (phba->fcp_embed_io) ? + LPFC_WQE128_SIZE : phba->sli4_hba.wq_esize; + qdesc = lpfc_sli4_queue_alloc(phba, wqesize, phba->sli4_hba.wq_ecount); + if (!qdesc) goto out_error;