Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2709749imm; Sun, 12 Aug 2018 22:01:02 -0700 (PDT) X-Google-Smtp-Source: AA+uWPymOU1ciarCjQUDXOkYeM39WBFWd0PwH8LId6cI4hAbIuXHPJm+FU9dj8nVcACWUZBBlPvg X-Received: by 2002:a62:2983:: with SMTP id p125-v6mr7957140pfp.128.1534136462536; Sun, 12 Aug 2018 22:01:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534136462; cv=none; d=google.com; s=arc-20160816; b=U9wx7bdES854iOzPXcY0NJ3kvLpFK6m7hywDNgGh3GOBBFBjEyv5g9l86/ETIrElqM Tpi5VJMdalu40JhunOAwuXUP3hlQK739/r/xI3l2HPM/JR0l01ntPAbHuFYLc4QOBwrk fFeAKrf5+Bcy3Kyregx7tlL9hXxSsffgQ7ViUKmIPB63D6m/bhqqpftVkoyOres12WP2 mXAWY1/nTm9pwpjVYmYyD/8jPGLJmZpqnOeK1qw6iXj0OtSyYFifxk7LJjNH5trS1LQX Pqth2ie9qEAbx85pu9iAssovzs92OmPlUJqhW0PWz4OJPh83AS5pCaldn/aiCcxy5FQr NjnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature :arc-authentication-results; bh=EYXpJfwsER+EeXHbgL8do+8ipCe/rSy/AGFQDlxEo3Y=; b=QMC+RfnLNq7FdBtsFpGC7gPfXDaNvQZ/GH2WhHPgFGniPXk6br6bYbSARLGjZ3rcHw 5OgfMIzAmEtuEfvD5lLhScxpPVVyZwBmQbjklw6wQ48LCJVqMqfPVfUQiIPzAplepa1D d3k4cLZrZZ2tIjk7hU2onU1bk1DmibUleyPwyD0U+qX7I7fXocgWPAAkiSkY0Yvx+9WU R5l66AKusXnc55ejJ8+TZ2dOH88XSdCWxzfztAnhskVHjTF9/Y+p2ytpI6sz8B3hlTgB cgleWO2f1snZFtWu8vvXXTUHtaoAH7wTp9sgBxXTJ56e+vBR+57S8Xicw5NGRvWUzJO6 EPYw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="FyF0/qiO"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r189-v6si16439070pgr.634.2018.08.12.22.00.48; Sun, 12 Aug 2018 22:01:02 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@gmail.com header.s=20161025 header.b="FyF0/qiO"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728215AbeHMHjU (ORCPT + 99 others); Mon, 13 Aug 2018 03:39:20 -0400 Received: from mail-it0-f66.google.com ([209.85.214.66]:40364 "EHLO mail-it0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726037AbeHMHjU (ORCPT ); Mon, 13 Aug 2018 03:39:20 -0400 Received: by mail-it0-f66.google.com with SMTP id h23-v6so11780495ita.5; Sun, 12 Aug 2018 21:58:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=EYXpJfwsER+EeXHbgL8do+8ipCe/rSy/AGFQDlxEo3Y=; b=FyF0/qiO3W2i4AMhzO/U6/V6zxAIcGSOG0uFZXgBwwap6rLF3TLL4GlsqwCX2eUKUS 9f1O8sjo+tEerYAKioFn7/cng5zP9WKlh1SmnmKYZAg+4VfpUPRVAGIBaOwkKOOKLIcZ eG2PdSA3KeSQlyQCJkNpFnwncWYe7ZYCZJJ0U5a0zBK0DxGmOY4OJAYgO4ZmPF+NnxZH 5IitCuw6/RWCXz2fDuxtD5ndX6vJAhob3MiobmOX225r39YpHOsr5GHObfIC4O4KIDAm TOOABNYiU0vFwHzW2Htn3jy1ZKSEoMvySas5fdlbiONfMXTOmdpzOFN9uPnRzqE6Gvnd ++HA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=EYXpJfwsER+EeXHbgL8do+8ipCe/rSy/AGFQDlxEo3Y=; b=BVITx6gUcEoDzRT4qrJlFxDJPiYp+LjnIMozH+o2Y557osnViCydHqQbU2+OEcFXuC Lt6JHqSy5MbLn8nwITGQKdk5ijwUqlEQa09mJyVDeX+lto9rncI4jmrJxCMhzD58naku GHVFWjE5PTxpt/Iam3qTWo8N+WnmkswGkjsLNeqi5mvoodWOLpn6aRdusrMn6OlbaCiv kG1gTWMQkJ9vC4HaQAwYiMVDDFGXms+UtPITL/g0aYe2x6RFEMF1N0ZiMFP0YSAgVKPt UuS4+89tzEjSuXFXm+jZYOlUeR5H33C42RkOZwEfX9Q8ewYb8wv8XERiJLH14brbP2cK D3eQ== X-Gm-Message-State: AOUpUlGb5HfRF+N9n+GXliOpQUhmNMnP4tWzOZ+Rj8wfQtpCm1Z2z6nI 1gCJsJZMUHxOmYgj/4JsWBTSXI1ovwvOvSBLqn5Hx+5s X-Received: by 2002:a24:1c0a:: with SMTP id c10-v6mr10230704itc.101.1534136327042; Sun, 12 Aug 2018 21:58:47 -0700 (PDT) MIME-Version: 1.0 References: <20180812145207.11395-1-kristian.evensen@gmail.com> <871sb3zc3v.fsf@kamboji.qca.qualcomm.com> <5B708025.4090906@broadcom.com> In-Reply-To: <5B708025.4090906@broadcom.com> From: Kristian Evensen Date: Mon, 13 Aug 2018 06:58:35 +0200 Message-ID: Subject: Re: [PATCH] mt76: Enable NL80211_EXT_FEATURE_CQM_RSSI_LIST To: arend.vanspriel@broadcom.com Cc: kvalo@codeaurora.org, linux-wireless@vger.kernel.org, Network Development , linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Kalle & Arnd, On Sun, Aug 12, 2018 at 8:44 PM Arend van Spriel wrote: > > So have you tested this and with what devices? For example, does it work > > with recently added USB devices? > > I was looking into this as it looks suspicious to me. From reading the > description of this ext_feature flag it seems this is an extention of CQM: Thank you very much for your feedback. My commit message should have been more detailed, sorry about that. I have checked that the flag works as intended with mt7602-, mt7603- and mt7612-based wifi cards. I have not had the opportunity to test with any of the recently added USB devices, as I don't have access to any of those. In order to test the flag, I wrote a small program which subscribes to the CQM-multicast group, passes an RSSI threshold-list to the kernel and logs the received CQM-events. I then disconnected and connected the wifi-antennas of the different cards. My threshold list was {-70, -60, -50, -40} and while unscrewing the antenna I received multiple below-events. When I attached the antenna again, I received multiple above-events. As an example, here is the log when I tested with mt7612 (singal level when starting was ~-48 dBm): Requested nl80211 generic netlink id nl80211 has generic netlink id: 23 mlme ID is 5 Added socket to mlme group Sent NL80211_CMD_SET_CQM No error Wifi (idx 18) went below threshold. RSSI -52 Wifi (idx 18) went above threshold. RSSI -49 Wifi (idx 18) went below threshold. RSSI -52 Wifi (idx 18) went below threshold. RSSI -62 Wifi (idx 18) went above threshold. RSSI -59 Wifi (idx 18) went above threshold. RSSI -49 Based on how I interpret the output and my understanding of how CQM + RSSI_LIST works, this output shows that mt76 works fine with NL80211_EXT_FEATURE_CQM_RSSI_LIST (at least for my cards). The list was interpreted and handled correctly, as I received events when the RSSI passed different thresholds in my list (-50, -60). BR, Kristian