Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp2894579rwb; Mon, 15 Aug 2022 13:30:11 -0700 (PDT) X-Google-Smtp-Source: AA6agR5YoTOtSLyxH1DfJ3AUZKkgf9MaWU06z/xEXWkWpAHzzKjCtcyiIuVxcjmyHYC0hadaL6Qu X-Received: by 2002:a17:907:28d6:b0:731:10ff:86a6 with SMTP id en22-20020a17090728d600b0073110ff86a6mr11543505ejc.128.1660595411681; Mon, 15 Aug 2022 13:30:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660595411; cv=none; d=google.com; s=arc-20160816; b=PhlgssA4TRsSASjBWSWAbSZptc/UnAXRORuav5Oi8gJ19z0QoUM7ObzL73lxtW4Zg0 0kyL2l0pM8GN+o92DOKGJWuKukqdnP28mKUWKK1G7PMZprcgb3YL+yQUNTsvcmKjCEFh eNAAzaTEJs9M2JYpLMhf1yhd2WrIxWQ1jFbOJvzWuQ0Hb/d7EUbyMFfCmXSsrc+8EBVZ 2nqV8N4sZBVyrVQPheq1PsdXvOHfOLpRsj9YChk4K61Pu/siM+BXKyNJDWJ3j+LZDFiX wVSAGM9dqsW/J7hwFJ6+L7oX8EwO6WIdexzRPLKjNPciG48o3Xqnc8gKiNqUNDowvLJU JuBA== 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=Gdy1vYR43D4YLrhwux4IfLCUcNvlfiMGdpRtxrI892U=; b=WVgbT49riiWgkMqaNKuouFMACUnpjofT/vCekObzR7P/Id45gSjG7/C71xQoLFoWQ0 QX+qiwDNoYhzUMzM66Wi6jjydVsW9eaIhmw4xvGAhy2B7bbM/nJNRLD0Uc/Z6hn08DQS N3BbVt9G9YRcZwKYSpkv7XtD9Z+7151D6pcEVTXHtyVVcu/DPIQZojhtfSBW5fcUoj7S h29T+qjIDYx1vkK9ucN9VA8mEOTobYte6DwNFV5AeGhA1LGHgKeTiJs4B7y7S+Z9ITTA 3rj207ViFnrLJhBFbKnEH7Ls8hp1DTxHNm+N87jRbRMyUCkehai6uOkD0wqQCn0EynVj OPyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=mxfC9WbY; 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 sg43-20020a170907a42b00b00734be0d7167si7998119ejc.825.2022.08.15.13.29.40; Mon, 15 Aug 2022 13:30:11 -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=mxfC9WbY; 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 S1347414AbiHOUZY (ORCPT + 99 others); Mon, 15 Aug 2022 16:25:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241843AbiHOURH (ORCPT ); Mon, 15 Aug 2022 16:17:07 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 807E3C6B; Mon, 15 Aug 2022 12:00:21 -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 277B7611D6; Mon, 15 Aug 2022 19:00:20 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 29782C433B5; Mon, 15 Aug 2022 19:00:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660590019; bh=zEedom811/5se5b7aljK1JSNDPwuR5xYRPX2z+nxSlI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=mxfC9WbYIpEwvB5LwhTpqJz8qo2qv61rJ+ZOMQmzPnn5+rVNby4Ui52L0IPJ1qt2y AcpaKat80pRWOUTRnrUmErTsyws2eAInOW8WSOrKAYFHphxQ6/m6O243/whRB2HW/h 9ZW2ECj2ME+w8p2GhC95bdQYucAnLJXaVCwH1VSU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Himanshu Madhani , Bikash Hazarika , Quinn Tran , Nilesh Javali , "Martin K. Petersen" Subject: [PATCH 5.18 0097/1095] scsi: qla2xxx: Zero undefined mailbox IN registers Date: Mon, 15 Aug 2022 19:51:36 +0200 Message-Id: <20220815180433.564851189@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180429.240518113@linuxfoundation.org> References: <20220815180429.240518113@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,T_SCC_BODY_TEXT_LINE 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: Bikash Hazarika commit 6c96a3c7d49593ef15805f5e497601c87695abc9 upstream. While requesting a new mailbox command, driver does not write any data to unused registers. Initialize the unused register value to zero while requesting a new mailbox command to prevent stale entry access by firmware. Link: https://lore.kernel.org/r/20220713052045.10683-4-njavali@marvell.com Cc: stable@vger.kernel.org Reviewed-by: Himanshu Madhani Signed-off-by: Bikash Hazarika Signed-off-by: Quinn Tran Signed-off-by: Nilesh Javali Signed-off-by: Martin K. Petersen Signed-off-by: Greg Kroah-Hartman --- drivers/scsi/qla2xxx/qla_mbx.c | 2 ++ 1 file changed, 2 insertions(+) --- a/drivers/scsi/qla2xxx/qla_mbx.c +++ b/drivers/scsi/qla2xxx/qla_mbx.c @@ -238,6 +238,8 @@ qla2x00_mailbox_command(scsi_qla_host_t ql_dbg(ql_dbg_mbx, vha, 0x1112, "mbox[%d]<-0x%04x\n", cnt, *iptr); wrt_reg_word(optr, *iptr); + } else { + wrt_reg_word(optr, 0); } mboxes >>= 1;