Received: by 2002:a05:6a10:8a4d:0:0:0:0 with SMTP id dn13csp1014730pxb; Fri, 13 Aug 2021 11:20:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxKysSbfAMVQ/pIynGgUqhnZ22Aqm5hAB9JMC3rMKlPnoQ48yHRssHJoeTS6zdxRN7Y/Lu6 X-Received: by 2002:a17:907:7752:: with SMTP id kx18mr3651604ejc.276.1628878840901; Fri, 13 Aug 2021 11:20:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628878840; cv=none; d=google.com; s=arc-20160816; b=yv1I/cBgCZYKXKSnT28gbBwi5VdOebISlzZLXuPgv8gQbyArRAQWAKSE8lorfXxmJ9 xAYZU2eXffJ8RkdjbVhhE2DVlKzc6WhmEE3WNdiE5OdFRPH9xqyPluQa6oaLQvxAnQdM XG6O3w6WAEq50yYVs2KXMbyEf3gq4WEOzPAybV7AoH8lyhBdKB71OALF6WC6Dvhgu+Tb H2/TNihzRtz5uVa98FH2FthC+5hOkiLlfHVdoZnUsYQh78ugisnELZAhC4muZWNWki7X gbVx0fuOnzcEXkInLDU3uhdSZdN1F21eAKRcih6mAf4m6hAJ7VGK5V99Nb1ksnTb6FRR mA5A== 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:date:cc:to:from:subject :message-id:dkim-signature; bh=rq6VfTjLJfvWeGU0hw3GUv7MRF3dGVPTx8dKGrBFFlo=; b=xoXtxNSQe8fDn7IO+s7beADKIghne0urMcSR5vKJmQspEBehW99+kreWAXno19hAKg 2yF4LvGgfKfHYhPXpUcE11822Fd2wQcrhRaKdW8v+u+tmhvhtgx7vWKT+8vd1jDMmUFP 5nx8TysqSJdYDUVRA4HkIAIFxB/5YULlzpATjSA2wHzsRFXhU0VNhsDF7t8fG9BQiI9K WVKQhHlOYPiaWrLQvgqVg2nnsT4ZuBqOOcnqrbTarR/MiPg6MZpj0YpisFvsPLpUzAdL lq/DfCiRpkXBdqR2Nyl7s0XF3JL6l9oVTdsSFmLVfPLSVVIlqrh8VkoZabWbU3jzWyuv O1TQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=I5S0gRU1; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i5si2242068edt.602.2021.08.13.11.20.01; Fri, 13 Aug 2021 11:20:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-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=@sipsolutions.net header.s=mail header.b=I5S0gRU1; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232877AbhHMSUU (ORCPT + 99 others); Fri, 13 Aug 2021 14:20:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34268 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232796AbhHMSUU (ORCPT ); Fri, 13 Aug 2021 14:20:20 -0400 Received: from sipsolutions.net (s3.sipsolutions.net [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E470EC061756; Fri, 13 Aug 2021 11:19:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sipsolutions.net; s=mail; h=Content-Transfer-Encoding:MIME-Version: Content-Type:References:In-Reply-To:Date:Cc:To:From:Subject:Message-ID:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-To: Resent-Cc:Resent-Message-ID; bh=rq6VfTjLJfvWeGU0hw3GUv7MRF3dGVPTx8dKGrBFFlo=; t=1628878793; x=1630088393; b=I5S0gRU1+S7GtJy5aucqUbOjnJXdvDVKjcmWggxsgLj+Opo fyzGd1Bxvte1qlq90HpPXLYOG5gI5qMJ7VnNQl1B4jan0JC4gHk2zw75449DN/FGvBQKNyN+RVPPQ Yv0F94jwEyHXmz9q7GfJpw7qFXxpYv1ji2N+o4yfZwwFYekhLwwD6pno1DHlKCG4v8p6HAB8055oi cGfDJwwYyYvzjoEsDzLEkxB5wgw5S08ft+zSZYxxSmDLzTiwJBJ/FDpq6hWKKzZhz6typDdPRVMvM bIqKAX1GvQmBOLCjqk//FqnBP0mvuceUUgRl16qmg0f0wnFBITH4K6XjE7wWI/mg==; Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.94.2) (envelope-from ) id 1mEbmM-00ALlG-5g; Fri, 13 Aug 2021 20:19:38 +0200 Message-ID: <465daabf002e098f0a24cf07f72a69d7e20c7440.camel@sipsolutions.net> Subject: Re: [PATCH 39/64] mac80211: Use memset_after() to clear tx status From: Johannes Berg To: Kees Cook Cc: "David S. Miller" , Jakub Kicinski , "Gustavo A. R. Silva" , Keith Packard , Greg Kroah-Hartman , Andrew Morton , linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-staging@lists.linux.dev, linux-block@vger.kernel.org, linux-kbuild@vger.kernel.org, clang-built-linux@googlegroups.com, linux-hardening@vger.kernel.org Date: Fri, 13 Aug 2021 20:19:36 +0200 In-Reply-To: <202108130907.FD09C6B@keescook> References: <20210727205855.411487-1-keescook@chromium.org> <20210727205855.411487-40-keescook@chromium.org> <202107310852.551B66EE32@keescook> <202108130907.FD09C6B@keescook> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.38.4 (3.38.4-1.fc33) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-malware-bazaar: not-scanned Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Fri, 2021-08-13 at 09:08 -0700, Kees Cook wrote: > > > > The common helper should also clear ack_signal, but that was broken by > > commit e3e1a0bcb3f1 ("mac80211: reduce IEEE80211_TX_MAX_RATES"), because > > that commit changed the order of the fields and updated carl9170 and p54 > > properly but not the common helper... > > It looks like p54 actually uses the rates, which is why it does this > manually. I can't see why carl9170 does this manually, though. mac80211 also uses the rates later again on status reporting, it just expects the # of attempts to be filled etc. I haven't looked at carl9170, but I would expect it to do something there and do it correctly, even though old it's a well-written driver and uses mac80211 rate control, so this would need to be correct for decent performance. But I guess it could be that the helper could be used because the rates were already handed to the firmware, and the code was just copy/pasted from p54 (the drivers were, IIRC, developed by the same folks) johannes