Received: by 2002:a17:90a:88:0:0:0:0 with SMTP id a8csp112859pja; Fri, 22 Nov 2019 04:13:15 -0800 (PST) X-Google-Smtp-Source: APXvYqyqcJNp4axIRmLg+mTMGWh+4ZhadJdu3vLYjZzNL1geeUj7OJ2g8g3gEZnVb46qPwDGxB/E X-Received: by 2002:a17:906:53c7:: with SMTP id p7mr21656850ejo.88.1574424795129; Fri, 22 Nov 2019 04:13:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574424795; cv=none; d=google.com; s=arc-20160816; b=BzuXpkPfYZFFt2gkMVBgzlpCpFXknEH2xmCqumNviIfvc0UXNeb2ZK+bu6CzhYgEuK Pm21DKZVl7+ySP3YI6rV/Lm7DnBsubkIszMIzpO6xDw7DZuXVLcoPTwqEMiL1dPykqmu tBfP7lVYrvOhgUv9jJZN2iIRWMp2FkmXxpcr86UbadI4DX3dqMO1CWk8hz7y1MTaR8js CwvnO3BrxfWZRQPsY4mvFSDAN1VuOL23A22hncIbweMM7Z/UlnsjEW7BcPTNbtLQ/2yT MgQghfgjrPJlrdMyEwjV7V4Pbeus8g3bXbGUvaZ2JyT/zplAAF4AXRPkUPWQyQDvYzib 751w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=FYEsWw5/DQK8ULsbfJgzkakXzBb2cVcDtmONZ3axhUc=; b=EBZ5yVDoz5gPeIXhDC5W0cSYqxbAmz3Jd13z8/N/AyPwZkLQTcDg/oOLA9KlinJw5T vOvL7bbcWzcMuFxxG4awwAB0bITdZNb6YBOZSxSwci4BA96f1sDWiL25HqB94tjgtZqs 1/JO23nmaOoaysadGfR3VibrOid0psNSuNruW7JsEJp+gF8r/qtDFnOdwI8HYNhKFU93 W5mGDdm0FM+FlV6nzhn7WR8LmeN4g03dmW4rEPAF9v/drWE7h0nBfFYmRAnhPzAUnjbN 6V+ltoVwp3R0YPMGipudJKXYfHNgDDF9sVTdmbvVZlXOW9kYyAfjjulh7M7E0lgCUo0/ 9YFw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k13si6329062edj.324.2019.11.22.04.12.49; Fri, 22 Nov 2019 04:13:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726852AbfKVMMl (ORCPT + 99 others); Fri, 22 Nov 2019 07:12:41 -0500 Received: from s3.sipsolutions.net ([144.76.43.62]:44452 "EHLO sipsolutions.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726739AbfKVMMk (ORCPT ); Fri, 22 Nov 2019 07:12:40 -0500 Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.92.3) (envelope-from ) id 1iY7nj-0002lN-42; Fri, 22 Nov 2019 13:12:39 +0100 Message-ID: <3e7bea0cc643714ec90978a7999022544a39b118.camel@sipsolutions.net> Subject: Re: [PATCH v11 2/4] mac80211: Import airtime calculation code from mt76 From: Johannes Berg To: Kan Yan Cc: linux-wireless@vger.kernel.org, make-wifi-fast@lists.bufferbloat.net, toke@redhat.com, nbd@nbd.name, yiboz@codeaurora.org, john@phrozen.org, lorenzo@kernel.org, rmanohar@codeaurora.org, kevinhayes@google.com Date: Fri, 22 Nov 2019 13:12:37 +0100 In-Reply-To: <20191119060610.76681-3-kyan@google.com> (sfid-20191119_070625_522904_ADC19544) References: <20191119060610.76681-1-kyan@google.com> <20191119060610.76681-3-kyan@google.com> (sfid-20191119_070625_522904_ADC19544) Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.30.5 (3.30.5-1.fc29) MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Mon, 2019-11-18 at 22:06 -0800, Kan Yan wrote: > From: Toke Høiland-Jørgensen > > Felix recently added code to calculate airtime of packets to the mt76 > driver. Import this into mac80211 so we can use it for airtime queue limit > calculations. > > The airtime.c file is copied verbatim from the mt76 driver, and adjusted to > be usable in mac80211. This involves: > > - Switching to mac80211 data structures. > - Adding support for 160 MHz channels and HE mode. > - Moving the symbol and duration calculations around a bit to avoid > rounding with the higher rates and longer symbol times used for HE rates. :) I'll apply this, I guess, but I do wonder to what extent it overlaps with cfg80211_calculate_bitrate()? johannes