Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp1304350rwi; Thu, 13 Oct 2022 11:45:32 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7ykcw0yfQKjt4wZy0lq3Ywx2vbrh8z2aXPeE7XExh64XcHHllxB5JJnQzpgUPnqxNxWeLO X-Received: by 2002:a65:558b:0:b0:460:d98a:542e with SMTP id j11-20020a65558b000000b00460d98a542emr1086127pgs.249.1665686732023; Thu, 13 Oct 2022 11:45:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665686732; cv=none; d=google.com; s=arc-20160816; b=JrtHXJiB8ePW+Of8WsxUU988BaDMsm5xyYji3MVa184bTD2LqUEI1zifK2/0VlBboN A5bgQZYz/y3DN7hnCFRw4XPa7LegpIZKen75lG7AL2t6g2MFc6LY+EHJrWY12XIGzx38 3znqHIjfjbWNZpI+kyj9e2Zl30MW8cE41AO/KGzS4eScuJ9OJTO/HnAvPBjQOEdKi5aO EMm+BaIzrUx5w4glyb+3BtJ6xSYbHT3F1XtFhsRAhI1LL8rOax0NIAi7+slmfF/T48Tl N/1vEfWdHYWgAlbrC2xFS0prtGrf6p7yHkzzTcm+FDur9GnxtipKukmMsDQRKG9Siddw PlgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=9BRdOo3tflaEUqfzOc+KZ4fGO1eeqF/53JBmlA1Yy6k=; b=Fkl/Cpmx1pE/AhfZAhpJ4/myuo92gHJ03OyUE2pAw9wfBzR8FouiLn/HqMl+BckVV/ 8S3zXNiGgqFum4vHGbyrB8ZwGgkc1fvUyp3WYpHWv7nCETGYpzq0gVorXqnJYbI/aHKV GjtEOf5hKTgTzlUmhFeGvhpZROxibhekVFX+hbz3e8tVNnctuQ3tIazD8PYUZIIOVqgT BERkWH9t5HX1tGtYiVCF2Yes1fK2yt6hhDVwI0R923SR/R2uCet2x+VUSPp52ZcU+eY6 CLF9V5htEofpAbVDbddywM3dslYLUuXvovaJOdV2ipX1cyp81LgmwIOO56oqptD/dl9N NA8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Euxm4PuA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nk5-20020a17090b194500b00202b984842csi320500pjb.35.2022.10.13.11.45.20; Thu, 13 Oct 2022 11:45:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Euxm4PuA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231596AbiJMSHh (ORCPT + 99 others); Thu, 13 Oct 2022 14:07:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41768 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231345AbiJMSFx (ORCPT ); Thu, 13 Oct 2022 14:05:53 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3701B3C17C; Thu, 13 Oct 2022 11:04:56 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id D400361995; Thu, 13 Oct 2022 18:00:55 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4ACDDC433B5; Thu, 13 Oct 2022 18:00:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1665684055; bh=9vKia5o5B4xGTx3eWxIf6VhmDOv6agctG3itO2HEjxM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Euxm4PuAH2v5SDgDBgVvMJmPGvUaVxG5z3WLW0v2+fNG/g8S55XvxT0cjrfWytXmu fc46i4oGNkMQPjyUzDi/jAODovZ9LveSLXLPrQtpE2pYftnEateGkT69oaLTl7m3h3 1kQ6B4QikVDVRU5kzLQkN/LlyqfE9xh7p5OdRAIA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Himanshu Madhani , Arun Easi , Nilesh Javali , "Martin K. Petersen" Subject: [PATCH 6.0 11/34] scsi: qla2xxx: Revert "scsi: qla2xxx: Fix response queue handler reading stale packets" Date: Thu, 13 Oct 2022 19:52:49 +0200 Message-Id: <20221013175146.815599374@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221013175146.507746257@linuxfoundation.org> References: <20221013175146.507746257@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arun Easi commit 6dc45a7322cb9db48a5b6696597a00ef7c778ef9 upstream. Reverting this commit so that a fixed up patch, without adding new module parameters, can be submitted. Link: https://lore.kernel.org/stable/166039743723771@kroah.com/ This reverts commit b1f707146923335849fb70237eec27d4d1ae7d62. Link: https://lore.kernel.org/r/20220826102559.17474-2-njavali@marvell.com Cc: stable@vger.kernel.org Reviewed-by: Himanshu Madhani Signed-off-by: Arun Easi Signed-off-by: Nilesh Javali Signed-off-by: Martin K. Petersen Signed-off-by: Greg Kroah-Hartman --- drivers/scsi/qla2xxx/qla_gbl.h | 2 -- drivers/scsi/qla2xxx/qla_isr.c | 25 ++----------------------- drivers/scsi/qla2xxx/qla_os.c | 10 ---------- 3 files changed, 2 insertions(+), 35 deletions(-) --- a/drivers/scsi/qla2xxx/qla_gbl.h +++ b/drivers/scsi/qla2xxx/qla_gbl.h @@ -193,8 +193,6 @@ extern int ql2xsecenable; extern int ql2xenforce_iocb_limit; extern int ql2xabts_wait_nvme; extern u32 ql2xnvme_queues; -extern int ql2xrspq_follow_inptr; -extern int ql2xrspq_follow_inptr_legacy; extern int qla2x00_loop_reset(scsi_qla_host_t *); extern void qla2x00_abort_all_cmds(scsi_qla_host_t *, int); --- a/drivers/scsi/qla2xxx/qla_isr.c +++ b/drivers/scsi/qla2xxx/qla_isr.c @@ -3763,8 +3763,7 @@ void qla24xx_process_response_queue(stru struct qla_hw_data *ha = vha->hw; struct purex_entry_24xx *purex_entry; struct purex_item *pure_item; - u16 rsp_in = 0, cur_ring_index; - int follow_inptr, is_shadow_hba; + u16 cur_ring_index; if (!ha->flags.fw_started) return; @@ -3774,25 +3773,7 @@ void qla24xx_process_response_queue(stru qla_cpu_update(rsp->qpair, smp_processor_id()); } -#define __update_rsp_in(_update, _is_shadow_hba, _rsp, _rsp_in) \ - do { \ - if (_update) { \ - _rsp_in = _is_shadow_hba ? *(_rsp)->in_ptr : \ - rd_reg_dword_relaxed((_rsp)->rsp_q_in); \ - } \ - } while (0) - - is_shadow_hba = IS_SHADOW_REG_CAPABLE(ha); - follow_inptr = is_shadow_hba ? ql2xrspq_follow_inptr : - ql2xrspq_follow_inptr_legacy; - - __update_rsp_in(follow_inptr, is_shadow_hba, rsp, rsp_in); - - while ((likely(follow_inptr && - rsp->ring_index != rsp_in && - rsp->ring_ptr->signature != RESPONSE_PROCESSED)) || - (!follow_inptr && - rsp->ring_ptr->signature != RESPONSE_PROCESSED)) { + while (rsp->ring_ptr->signature != RESPONSE_PROCESSED) { pkt = (struct sts_entry_24xx *)rsp->ring_ptr; cur_ring_index = rsp->ring_index; @@ -3906,8 +3887,6 @@ process_err: } pure_item = qla27xx_copy_fpin_pkt(vha, (void **)&pkt, &rsp); - __update_rsp_in(follow_inptr, is_shadow_hba, - rsp, rsp_in); if (!pure_item) break; qla24xx_queue_purex_item(vha, pure_item, --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c @@ -338,16 +338,6 @@ module_param(ql2xdelay_before_pci_error_ MODULE_PARM_DESC(ql2xdelay_before_pci_error_handling, "Number of seconds delayed before qla begin PCI error self-handling (default: 5).\n"); -int ql2xrspq_follow_inptr = 1; -module_param(ql2xrspq_follow_inptr, int, 0644); -MODULE_PARM_DESC(ql2xrspq_follow_inptr, - "Follow RSP IN pointer for RSP updates for HBAs 27xx and newer (default: 1)."); - -int ql2xrspq_follow_inptr_legacy = 1; -module_param(ql2xrspq_follow_inptr_legacy, int, 0644); -MODULE_PARM_DESC(ql2xrspq_follow_inptr_legacy, - "Follow RSP IN pointer for RSP updates for HBAs older than 27XX. (default: 1)."); - static void qla2x00_clear_drv_active(struct qla_hw_data *); static void qla2x00_free_device(scsi_qla_host_t *); static int qla2xxx_map_queues(struct Scsi_Host *shost);