Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp1019713rwi; Wed, 19 Oct 2022 05:55:50 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6r+C68LWVPkyNQV4bwv2zoK7lMW64tD1XsJlnc4FRme6LCfZfTxrlT1+abg4YSJr3cEagS X-Received: by 2002:aa7:c98d:0:b0:45c:6451:320e with SMTP id c13-20020aa7c98d000000b0045c6451320emr7352113edt.172.1666184150231; Wed, 19 Oct 2022 05:55:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666184150; cv=none; d=google.com; s=arc-20160816; b=bkyqRy1RZCPC1tKM8vZwxqKwwhveWe5L6yapuB4Yyn+qkMlG26DI/dzT7hVYPZa+U2 yP68DsAnMz1IAQ2j7sHStQKAsDAe34PX/VButYpNcjiE1c6lfi+LO1A5YPLoH00HIEu0 xVwt5DP+2xFI0MdgfeDNSr0MFENXppkjTIpd0tJ0kQvRQxMKHeZS6EY/IwXv5t69YxSK wVTf/8KgD+vNKp41wyQq/xlTAdM/451Gk13SQiKC6GIN/gGRa/anpxQd1lWnXwLTwDwm OZXbgGVK7VVBhEixhB/bg/67cYSU5y1S4RUs/+RgjZQUfxBzg7hIzaeazy/ksDgvH1Ue uKYw== 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=B56lol8SL30SE8KEiPRKxYcaJXhxaU7EC+drJR+BzQY=; b=nJxGrIxhLqvx3dzhSrMfSTpa6mwo9BqtVPpllXSe358MlDcnNEfrlzsXihhOpXXzqr iKuZqH0hTa+wwot6QrO4QLs7xpsC3BRnJ1DSXeKjp5BhsDoyMJztKAp/BELt+xkuZkpu XcigfGwXm3i9RVHlo3tzNMZuC+aOdP1+Z9boxjh1tHWBvy4D7O7uK84fB2uSY7eTVqrG O623KkAzbhkBlBn5ItbdRhn/sFLL5kM65WJimdBD0uvdRVm8BF0S6WRW213MspB+8Y+C +RW8e9xahb6uGzugmToCCblsf5IivCd/PtdSrj8hMXMSyjMd8FFwKbqSVQAA/AwhpgI9 bWwg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=f1ugUAqn; 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 qk10-20020a1709077f8a00b0078d112eaf80si14859903ejc.86.2022.10.19.05.55.22; Wed, 19 Oct 2022 05:55:50 -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=f1ugUAqn; 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 S232524AbiJSMDq (ORCPT + 99 others); Wed, 19 Oct 2022 08:03:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37980 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231713AbiJSMDO (ORCPT ); Wed, 19 Oct 2022 08:03:14 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BFA2B4C627; Wed, 19 Oct 2022 04:39:45 -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 ams.source.kernel.org (Postfix) with ESMTPS id 37FE1B8239B; Wed, 19 Oct 2022 08:51:16 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id AA378C433D6; Wed, 19 Oct 2022 08:51:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666169475; bh=HEgbHPH4lSpqw0IoD5a5jolqD6Cro97cGscbSfURixw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=f1ugUAqnjPZykZh2zVV+TFVO09corr+XSB4Z0FxV1IRK8HBkuvJ64cWbqPGBKmMQI l7yY7WAyewahUJnI+iNAtNoQYGAsPpaB8OCNu9HTtdbGkH8wBGpPtChIgbkHQDSbHT s/IvAtaYZ6Lcj7QU5IDp3n5LxOO+4ifAYvRJtaqE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Lorenzo Bianconi , Felix Fietkau , Sasha Levin Subject: [PATCH 6.0 290/862] wifi: mt76: fix uninitialized pointer in mt7921_mac_fill_rx Date: Wed, 19 Oct 2022 10:26:17 +0200 Message-Id: <20221019083302.829350594@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221019083249.951566199@linuxfoundation.org> References: <20221019083249.951566199@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.4 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: Lorenzo Bianconi [ Upstream commit 9be57ad73984545d594ed359dac19457bcb9fc27 ] Initialize msta pointer to NULL in mt7921_mac_fill_rx() in order to not dereference a uninitialized pointer. Fixes: 0880d40871d1d ("mt76: connac: move mt76_connac2_reverse_frag0_hdr_trans in mt76-connac module") Signed-off-by: Lorenzo Bianconi Signed-off-by: Felix Fietkau Signed-off-by: Sasha Levin --- drivers/net/wireless/mediatek/mt76/mt7921/mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c index 6bd9fc9228a2..e8a7a5831782 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c @@ -235,7 +235,7 @@ mt7921_mac_fill_rx(struct mt7921_dev *dev, struct sk_buff *skb) u32 rxd2 = le32_to_cpu(rxd[2]); u32 rxd3 = le32_to_cpu(rxd[3]); u32 rxd4 = le32_to_cpu(rxd[4]); - struct mt7921_sta *msta; + struct mt7921_sta *msta = NULL; u16 seq_ctrl = 0; __le16 fc = 0; u8 mode = 0; -- 2.35.1