Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp1013081pxb; Thu, 9 Sep 2021 18:00:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzI86t6lU9QoD7YEA7mDAAZbH8yIG3hDN07XZnx9KBWsAmgzT+ZwzbDDUIfc4aneU4XDTTJ X-Received: by 2002:a5e:c609:: with SMTP id f9mr5066105iok.127.1631235616821; Thu, 09 Sep 2021 18:00:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631235616; cv=none; d=google.com; s=arc-20160816; b=AgWl67zD4jdI4JuxZSb7MDOKlUT7emgIrr+1j2HRo1E5/C2osNNqF2wkM3rl4eCBcu TCi57ZnTswwug97uchIhe6Q71wRev+FVzHf7x9EacCpLWJnydSZQVlou/KOwjE7fz3Z1 etJt2X2nHYh2yJVeCALDVFcsoBGQbH0hd6t+Sl3RnbpOZUpyDVmRHco9sMWmPGCJTwqH RFpzyXgCGs5iVwtsocwa/u4VRnhLAbaZKol5QwXD7xghteBcwOXzLAHjd1xAzhyIIf7r FxLFKd82Zngm9YXTfx0oqRe5dy0CoIs0K1AK4xQ881BA4BWaGdUxuDR/3rTm0FoyN5Uk jQ5A== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=dnYaGFaute0nFa+Yt1o5z49r+PhoJIeEXvWkjWD8U+8=; b=IUHm++9198Be8ch+veqhrhHpX3RS2kp7rReif7ddnSIks1LpVWOsTRM7ogKSWK/Gee t6U2sUTGZNZ7cCO9KAuaThvSKL7EylWL91UVseygIFk1trK35fs82MbClagEv3KvABWK aUWf1zoFf4t99UTEA0Jys6aDhSyfvNQKVv11RQzVtmBmCqlVl6GjTZm0idi4JFxlMTXG qsHxJrWzMVoz5Adt1lnwJPBWgugzQ/8Wo+EAD6XpSu9nD7H+KHY948LuApmN1bZc4F5E fZQFJSvdtN4LQWnob49HSj2R0m8LwVeFDnaF3yoJfxWomUniPWzz2D08sWHimtIPGkc/ XTvg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PfEC84bD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c32si3525778jaa.44.2021.09.09.18.00.04; Thu, 09 Sep 2021 18:00:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PfEC84bD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243872AbhIJA7R (ORCPT + 99 others); Thu, 9 Sep 2021 20:59:17 -0400 Received: from mail.kernel.org ([198.145.29.99]:48566 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234190AbhIJAXA (ORCPT ); Thu, 9 Sep 2021 20:23:00 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 848EA60F24; Fri, 10 Sep 2021 00:21:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1631233310; bh=zE/zs8pjurMpZbAT0rpUZiaXHYIwRvJkegYn8d7RSJs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PfEC84bDNihD2EuYDZThl7bY5QzrIRvK++N5DiXsrNymql+Kj/eBmlJccnin5Zer3 REK1dpuId5x47wqwez/gTdLNe7Zxw7M2nixVbdtxY+q3zw20H/5iwjjmg1CrAurAAL 0xj9PLUWG/x+BczNRw1gPj4SZXtoIQcOhow8/6YKNTdrYnIDViKCTwwk2gq4EVJ+CE ORA6KgcyGbAI6hIaxZ0Raw9eDroOQmYsv4IqbwVhiEdwNJ2DtdcpINqkqwIZgXBGgo /Mzjfuf25UtNl3uSGS5cdnl4wkUA4kSQIv8jrqMwce9pLweS+Ya8mRsOYyhR4z64DM aU63THRLR9LXQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Mike McGowen , Kevin Barnett , Scott Benesh , Scott Teel , Don Brace , "Martin K . Petersen" , Sasha Levin , storagedev@microchip.com, linux-scsi@vger.kernel.org Subject: [PATCH AUTOSEL 5.4 05/37] scsi: smartpqi: Fix ISR accessing uninitialized data Date: Thu, 9 Sep 2021 20:21:10 -0400 Message-Id: <20210910002143.175731-5-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210910002143.175731-1-sashal@kernel.org> References: <20210910002143.175731-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mike McGowen [ Upstream commit 0777a3fb98f0ea546561d04db4fd325248c39961 ] Correct driver's ISR accessing a data structure member that has not been fully initialized during driver initialization. The pqi queue groups can have uninitialized members when an interrupt fires. This has not resulted in any driver crashes. This was found during our own internal testing. No bugs were ever filed. Link: https://lore.kernel.org/r/20210714182847.50360-9-don.brace@microchip.com Reviewed-by: Kevin Barnett Reviewed-by: Scott Benesh Reviewed-by: Scott Teel Signed-off-by: Mike McGowen Signed-off-by: Don Brace Signed-off-by: Martin K. Petersen Signed-off-by: Sasha Levin --- drivers/scsi/smartpqi/smartpqi_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/smartpqi/smartpqi_init.c b/drivers/scsi/smartpqi/smartpqi_init.c index 9bc451004184..824f19475b27 100644 --- a/drivers/scsi/smartpqi/smartpqi_init.c +++ b/drivers/scsi/smartpqi/smartpqi_init.c @@ -7208,11 +7208,11 @@ static int pqi_ctrl_init(struct pqi_ctrl_info *ctrl_info) pqi_init_operational_queues(ctrl_info); - rc = pqi_request_irqs(ctrl_info); + rc = pqi_create_queues(ctrl_info); if (rc) return rc; - rc = pqi_create_queues(ctrl_info); + rc = pqi_request_irqs(ctrl_info); if (rc) return rc; -- 2.30.2