Received: by 2002:a25:b323:0:0:0:0:0 with SMTP id l35csp1796868ybj; Sun, 22 Sep 2019 12:08:18 -0700 (PDT) X-Google-Smtp-Source: APXvYqx/XDG+imHveu2CrweN5hRWNDsL8d/IM+BUk14Ijdr6UrzNz/xDkpTomKhC2BU03f6hBnVi X-Received: by 2002:a17:906:3543:: with SMTP id s3mr27165351eja.240.1569179298426; Sun, 22 Sep 2019 12:08:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569179298; cv=none; d=google.com; s=arc-20160816; b=kVCodZUwMXMWF1UStzXtrkOGdg5TLZgrdh1JLibmY+4wDkC/z3wQLeQEvO0xk7Wrnv bgYXv+4DuPH/WFPsxLjiOd50i6q9QqrwbM4eg5o8VeYmh9gQvuwhoqWPftOZDy4OdZga qNFBd3pHyBpdvldA+No/J3+jCVSlsXwzmnYD9aGOJsmJFWXb+YJ40obBe62mjiZKBHjT qRYRfGnQfPBIf+XXJI3WXdRJese9RplOQUOCDKsITvwUeF0wIjX6tpt0zN8anT+3vHga xBnleOtTlyCb0xDlUqRCZJfZ5eQSCS8CKPw9KNkngWuibZ6T+rNlROeXtoxRxe+agnS+ fmGg== 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; bh=XhLiIJuH0SGTBMO9tG834CM4qGoWDAVIb1x577qt9Tg=; b=oKz4+GN078PkpgOG49zU8w9V5aTqUbWCbb+jRN0l97amt/S536iV7r/0OH4j5wvk5U KRHvDS+YRpjOYu0VBxm9aciYUSizQVWQKbbO6AL8W1acWydLeCv3OpYNOftOmg2NlJL0 E8k/+6N/w0tpr2bK0gRNyS2NY8M+r2ON3no1CKA/1QJulko2Muxl3lbMrZimSbveJiPI Gh5PEu0averabuBJPa24gVSaAueRzQxCznyw7LdbsQzHU2MKznlK2wWymKIng3rhy6tR vlR8rZv2MNrwSiCDtB3axgCe+vtqdXnK05eRIKdNNWcFgasmNb8+y00IKlkAgrGwNvGd 0sNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=oTl5KYVI; 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=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d22si5427732ede.131.2019.09.22.12.07.52; Sun, 22 Sep 2019 12:08:18 -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=@chromium.org header.s=google header.b=oTl5KYVI; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405556AbfITWdh (ORCPT + 99 others); Fri, 20 Sep 2019 18:33:37 -0400 Received: from mail-qt1-f196.google.com ([209.85.160.196]:34293 "EHLO mail-qt1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405501AbfITWdh (ORCPT ); Fri, 20 Sep 2019 18:33:37 -0400 Received: by mail-qt1-f196.google.com with SMTP id 3so8047153qta.1 for ; Fri, 20 Sep 2019 15:33:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=XhLiIJuH0SGTBMO9tG834CM4qGoWDAVIb1x577qt9Tg=; b=oTl5KYVIwDytGG95Cdmiw73bbg3Y9rwJTRHhL/XFpoOlUimoeY3/LBXCoo4jeE7nat PfxB3s0E+p6yPFmENuBxiOWsBC+JqmyhClAKFrKkzGOctOjc8IEhU/3Wg7jzD6UH3I6J v5AsZaC3x8I11P7IhUzwZ74P0/jZwpH+yQGyc= 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=XhLiIJuH0SGTBMO9tG834CM4qGoWDAVIb1x577qt9Tg=; b=QP7tWMdQ7te6w7NFWudFa1NLr/U/f0yYZzGpsd94nVX2NToc2pacaJ/Z8juGE2Mgjk zJHn1G4CQI672qTHbU4o5ybj34zqm1SjicnshSirPbztTX83Nz5ueZWUlT9sXeAv27hN QDKcCCG6urRVPQ5XH9NBJpUjoqT5YKmf4HgYCksj23hBb2eFw+EVHgPQo5nfjd0A0Ros uWB9KW470LIteebDfi+dA1Gsi4/AXs2paDozf06o2fljcDgQ4pW+cNgC3TUtGXEwQkhx 8f5cinblWQYACCEJonQv0jcXWgevlkqiQZfyd4baB1ZZj+FOs0w0IWOCcrT7D+2y2Uld m/vg== X-Gm-Message-State: APjAAAXouQDk14HTA3jSbfm0f8HYGWMoaqSQKlZWXZY9+G6sUb6pRfc+ PGmKmNIhtrJa71M4PnPNqThw4/ITTwM= X-Received: by 2002:a05:6214:452:: with SMTP id cc18mr15275657qvb.41.1569018815672; Fri, 20 Sep 2019 15:33:35 -0700 (PDT) Received: from mail-qt1-f180.google.com (mail-qt1-f180.google.com. [209.85.160.180]) by smtp.gmail.com with ESMTPSA id j80sm1617136qke.94.2019.09.20.15.33.34 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 20 Sep 2019 15:33:34 -0700 (PDT) Received: by mail-qt1-f180.google.com with SMTP id d2so10501394qtr.4 for ; Fri, 20 Sep 2019 15:33:34 -0700 (PDT) X-Received: by 2002:ac8:2d0f:: with SMTP id n15mr5975215qta.305.1569018814060; Fri, 20 Sep 2019 15:33:34 -0700 (PDT) MIME-Version: 1.0 References: <1568617425-28062-1-git-send-email-yhchuang@realtek.com> <1568617425-28062-6-git-send-email-yhchuang@realtek.com> <87tv97ctsp.fsf@codeaurora.org> In-Reply-To: From: Brian Norris Date: Fri, 20 Sep 2019 15:33:22 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 05/15] rtw88: pci: release tx skbs DMAed when stop To: Tony Chuang Cc: Kalle Valo , linux-wireless Content-Type: text/plain; charset="UTF-8" Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Fri, Sep 20, 2019 at 1:29 AM Tony Chuang wrote: > > Brian Norris writes: > > > Ah, I was a bit confused. So it does get called from "PS" routines: > > I thought you're talking about IEEE80211_CONF_PS instead of > IEEE80211_CONF_IDLE. Like I said, I was confused :) On first glance, I just saw the codepath showing up in ps.c, but then I noticed it's only for IDLE, not PS. > Also if possible you should queue patch 2, that reordering will cause > two H2C skbs not be released because HCI hasn't started, everytime > enter/leave IDLE state (rtw_power_[on|off]). That patch also looks good to me, FWIW. Side note: it's a little bit strange that your driver can silently misbehave so badly, just by TX'ing in the wrong state. Would this be a good case to add some WARN_ON() or WARN_ON_ONCE() (e.g., in functions like rtw_fw_send_h2c_packet()), to check for the appropriate "started" state? Brian