Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp4661298rwb; Tue, 17 Jan 2023 04:01:11 -0800 (PST) X-Google-Smtp-Source: AMrXdXsTzOFRriq5rUtp0qCbOFZrjgPh0KrWKBrAprhT/juMcDVg4mudXbynRY/0pzP7sR0JE2r/ X-Received: by 2002:a17:907:8d18:b0:7c0:d6b6:1ee9 with SMTP id tc24-20020a1709078d1800b007c0d6b61ee9mr2846194ejc.11.1673956871749; Tue, 17 Jan 2023 04:01:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673956871; cv=none; d=google.com; s=arc-20160816; b=IQvEMyl82wnG7IXLAvW9BuGfrPqunK3nYStLCpoHQx5wkHpeG4MQOMj741tq+ZQKog 2CqDS8/UnpUHPh6NxXIGtguSy0HaI1WDObpbhNGIJfAJ3r8Xl9vnfVsk1MLbuPy8FLhj 71AynyB6ku6S6ChfoPrHhx2eTp5dq3+XzgtxphOmC5T4QNFh9qN134wGpC9JqWSJSr6t XoAJFQKayJ/q3RbnpYG1uwj8Oh0qDcNh4aX+06AkXXUcVsrzsMh3u4okyJoKifRjBaKB Hf3/tEkW8u9sMTwV8gJWJYEBm/N6aDvsnmlAuRlXLpepxb8thm7fRa2remdNgD+iv+ZL 12MQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:date:message-id:user-agent:cc:to:references :in-reply-to:from:subject:content-transfer-encoding:mime-version :dkim-signature; bh=GuCZPz4/40FwpuHq0IUTRAe1NG7YjG37n1jRmwKFlhc=; b=HXiyXFbGXgDl8MjuRLJdlEOenLJw320nSLPeo4NQCk5/GcXZY7OxQRfC9IuSE5bfCm P17lLwIZ+Lj1fjwVdnENK0o63h/JZvM7XoR32cxnEgawY55gs1TnQKI5R8j8X72mIIGz E6khLxLOhlNglReqIH7hkwnNNvDH57l1oIw9rvep8om0SvlbEl55adT2xMxfn98SZmYT tSgWdbXw9CY+5SQ+XExLUYu2sBa5YuTIbLXUgLmIFF99VgVhgFOQ27Ep0kEFM863apmM Y61Xs0BCAjVweMQnM3+QSA/6LU9/F1RVTy1uxO/J8AEXtwqaF8Zs52e0fu39Ybpyjdx6 7aAw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Dix/JRvz"; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hp18-20020a1709073e1200b007b2a6aaff06si35882880ejc.50.2023.01.17.04.00.51; Tue, 17 Jan 2023 04:01:11 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-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=@kernel.org header.s=k20201202 header.b="Dix/JRvz"; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-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 S236438AbjAQLwz (ORCPT + 63 others); Tue, 17 Jan 2023 06:52:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33350 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236058AbjAQLwy (ORCPT ); Tue, 17 Jan 2023 06:52:54 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 583DF233CF; Tue, 17 Jan 2023 03:52:53 -0800 (PST) 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 07FD5B815AA; Tue, 17 Jan 2023 11:52:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F245EC433D2; Tue, 17 Jan 2023 11:52:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1673956370; bh=+fBuNs29t8yNPv6q51lyGENRRsy/0iZMXu1O4lAOniQ=; h=Subject:From:In-Reply-To:References:To:Cc:Date:From; b=Dix/JRvzda3WspkxvRp3kxxnBmsIoxY2NgLSprROHZ0qlxGw7s/fUzJ6BB0AsmhAi LDhkNPFamjnwUqZndKAWqtN+NWeazr3C0tgpwfbRycye0X+SSJYz6AW/LAxKMo9P0M 3ltjdPBkrnSa5/f86OYQX3l9mlyGeTD6RafI61+QmsapV2/OkPtGk1Y2U7/DbZdyr6 uUI8RyjQdgYqmYhh/1/Fi8KYz7RM4ZuKW61y/o9g+tRmVelUvaGL5wvt5PHC7GtrkM c7hIaNX9RpQCTWhVO5ithzfwSbj9cap7IM24/IO/k9ynW6fyiiS5mboZFuGiJFeOVs B+W8SirZu/7Gg== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: Re: [PATCH v4] wifi: ath9k: htc_hst: free skb in ath9k_htc_rx_msg() if there is no callback function From: Kalle Valo In-Reply-To: <20230104123546.51427-1-pchelkin@ispras.ru> References: <20230104123546.51427-1-pchelkin@ispras.ru> To: Fedor Pchelkin Cc: =?utf-8?q?Toke_H=C3=B8iland-J=C3=B8rgensen?= , Fedor Pchelkin , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Sujith , "John W. Linville" , Vasanthakumar Thiagarajan , Senthil Balasubramanian , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Alexey Khoroshilov , lvc-project@linuxtesting.org, syzbot+e008dccab31bd3647609@syzkaller.appspotmail.com, syzbot+6692c72009680f7c4eb2@syzkaller.appspotmail.com User-Agent: pwcli/0.1.1-git (https://github.com/kvalo/pwcli/) Python/3.7.3 Message-ID: <167395636331.22891.14427855957409091076.kvalo@kernel.org> Date: Tue, 17 Jan 2023 11:52:46 +0000 (UTC) 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-wireless@vger.kernel.org Fedor Pchelkin wrote: > It is stated that ath9k_htc_rx_msg() either frees the provided skb or > passes its management to another callback function. However, the skb is > not freed in case there is no another callback function, and Syzkaller was > able to cause a memory leak. Also minor comment fix. > > Found by Linux Verification Center (linuxtesting.org) with Syzkaller. > > Fixes: fb9987d0f748 ("ath9k_htc: Support for AR9271 chipset.") > Reported-by: syzbot+e008dccab31bd3647609@syzkaller.appspotmail.com > Reported-by: syzbot+6692c72009680f7c4eb2@syzkaller.appspotmail.com > Signed-off-by: Fedor Pchelkin > Signed-off-by: Alexey Khoroshilov > Acked-by: Toke Høiland-Jørgensen > Signed-off-by: Kalle Valo Patch applied to ath-next branch of ath.git, thanks. 9b25e3985477 wifi: ath9k: htc_hst: free skb in ath9k_htc_rx_msg() if there is no callback function -- https://patchwork.kernel.org/project/linux-wireless/patch/20230104123546.51427-1-pchelkin@ispras.ru/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches