Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp381196ybb; Fri, 10 Apr 2020 01:55:34 -0700 (PDT) X-Google-Smtp-Source: APiQypLkQHKbB2wwr0oeKHffhdIJXiO6bK9zuxXTRrjMkjddvZ4+L/to/uftMlTcz8kYJ1QRZUq4 X-Received: by 2002:a37:7605:: with SMTP id r5mr2720580qkc.345.1586508934465; Fri, 10 Apr 2020 01:55:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586508934; cv=none; d=google.com; s=arc-20160816; b=Zuzrk+3nOI/xZJ+6kB0Ui7hYw9o2dKtpbd6Wk0sTAX9+F2rQECb42hhy6UcqQn/VIv VMmGVVjkdx8Znhd308wiF8O3Q1mJXfMwmhOTMO9eOoERYjktFrLUNXO05L4ZHzVaKOvy HH7iRYbKR72HINJRp5NWNWxWnwecQxyLXqFK6LmHuAKbSGTN+nUnDO1IgkXSZvXNvldq QEQPH4SlHdheRnnHOGptFX4nkhP/kst0wg6vLMC5Ld5/8KjhnMME45/xeCvg+lo+pkk6 WmWm6Ik1LOWdV4y6+70D2OxS9ucHVnYmeHCny5dvrbxM8jkEkoCi6Z2FGuFVF8A1Nn0/ MX+A== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=R4UNxlS3PDE1UfNxbLRmAkrZkGkj9T94n61g04lPjas=; b=P5kGiK/EHq1vCkmBc62jgmN/OJgnhcg2CkSSKyPb67pFFC8FDZ4rLZo3ot0fzEZ5jB +bVYyfA1G+YjM12f2teBrcoYFOCYy2191S9p+dd38ix+C5YYEQCrDzJmipacfomXEWgY BZsUWtjvqV32kPY8zKwY70t8ijUWiH/Hzi9dyNCDXiY/O2e2GkDf/mLN7wkW3pngQD6x ZGunXBrjiu8vjyYyvIvonraCxn9FOrqzF7IkpYVMXtGs0m/QE1Qs4TtRsNfH7yfAgaHB 56txAsf9uraywdNkbEdxnA9IF3PYDw39pNmdkKkFHvWl3cS71N2oahZ2YN/83w7oxqqm AcEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=LoCz0nuV; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f19si689009qve.155.2020.04.10.01.55.14; Fri, 10 Apr 2020 01:55:34 -0700 (PDT) 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; dkim=pass header.i=@mediatek.com header.s=dk header.b=LoCz0nuV; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726092AbgDJIzI (ORCPT + 99 others); Fri, 10 Apr 2020 04:55:08 -0400 Received: from mailgw01.mediatek.com ([210.61.82.183]:53015 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1725955AbgDJIzH (ORCPT ); Fri, 10 Apr 2020 04:55:07 -0400 X-UUID: 93097433b08e415ba9a08eeb5c3bf62e-20200410 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=R4UNxlS3PDE1UfNxbLRmAkrZkGkj9T94n61g04lPjas=; b=LoCz0nuVOvO709krKd4eYZTNWkdOZ7z9/oAR7PPup+A+72+0ga8oa/U3thymfpkT3rj1hRpIiOIIVJKAYouQgJGyw2Nvqqq1zpzGZZDpdk7CQL2sRjUBNtp+JOc1FYKih2iz6zqJw46BXKPVuS/P665WhXF6ln2etqPbr1A5AgQ=; X-UUID: 93097433b08e415ba9a08eeb5c3bf62e-20200410 Received: from mtkexhb01.mediatek.inc [(172.21.101.102)] by mailgw01.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 1560573274; Fri, 10 Apr 2020 16:55:03 +0800 Received: from MTKCAS06.mediatek.inc (172.21.101.30) by mtkmbs02n1.mediatek.inc (172.21.101.77) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 10 Apr 2020 16:54:54 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by MTKCAS06.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Fri, 10 Apr 2020 16:54:54 +0800 From: Ryder Lee To: Felix Fietkau , Lorenzo Bianconi CC: Shayne Chen , YF Luo , Yiwei Chung , Chih-Min Chen , Evelyn Tsai , Sean Wang , , , Ryder Lee Subject: [PATCH 03/16] mt76: add Rx stats support for radiotap Date: Fri, 10 Apr 2020 16:54:40 +0800 Message-ID: <03f4b34864472f86aa5608fe08b4ca493e436140.1586507878.git.ryder.lee@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Content-Transfer-Encoding: base64 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org SEUgZGVpdmNlcyBuZWVkIHRvIGFkZCBSeCByYWRpb3RhcCBoZWFkZXIuDQoNClNpZ25lZC1vZmYt Ynk6IFJ5ZGVyIExlZSA8cnlkZXIubGVlQG1lZGlhdGVrLmNvbT4NCi0tLQ0KIGRyaXZlcnMvbmV0 L3dpcmVsZXNzL21lZGlhdG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