From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ua0-x235.google.com (mail-ua0-x235.google.com [IPv6:2607:f8b0:400c:c08::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.bufferbloat.net (Postfix) with ESMTPS id 7397B3B2A4 for ; Wed, 18 Jan 2017 01:58:31 -0500 (EST) Received: by mail-ua0-x235.google.com with SMTP id i68so3118158uad.0 for ; Tue, 17 Jan 2017 22:58:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=u0qjoKsJv6ZgTDKHSdLbQnYI1lEb+jd6V9/1Zr9jSkk=; b=S5NN4WuT4xE0tuUo3pg+H7xzscwyHUFWV8CTp1zDwRHCwBeFzJaPSVb1lbZtYty2dI lC1dcQXpFBXkRG+sN9W3UvdaF0nyCDzurPUdfSpTQJ2TPuUiu5xjKoYhFfInbpPCXgFX Izy1R6TvP4xTOjOuOjavIlYoV1M/kIF9u8jnrVfPu0J9YgtN6RjcgB+q/CneNCKrotwP fFJj67CBX1q+sFjniHiiMJ+EgEb+I5l52yeHoVCUOPe0FvYwms7FG4wPdz8bHSXiki5r VcKnvr9ZTJclpfszLe6SsbmaG30CGciO9cocJKe+8tAgveAWVaPSnupVp5Ep69l2Cr2E TOGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=u0qjoKsJv6ZgTDKHSdLbQnYI1lEb+jd6V9/1Zr9jSkk=; b=dH1cQPnQUPnGl/Yj484G99207tWmwB7n92enQD1QOfvx7C3wUkO2J00c+/UHIGdWoR TpHOiYtB4lefGuSHU8+EsUZD1oOu4ytKqtxZs4EDM1xzkq0eEJRTk4gOWj2apFYHLi50 c9Nj0VmHWmV3S0Zh15gW11JqDbyMTyd4GC5qbyndGC5t0VSCM81Aisw6QOaWsa+86h1t P7nXrbwjT1/+BjB+Qt4Cn6oKpqRXcTSuaPMW50hhD+cUyyOSsNXuNzcvNvsEkzuZ0+sw E/bL+JAed00wEz6dd5JBw/GiE5dB9ywuQMpkO+Bpfqq8M7e90ym78iBvl1/ZDeWeD0ju ENhA== X-Gm-Message-State: AIkVDXKAMWhf3NBeWbXVw5DQ0buExsEDBPaZsZa7WQJfMdT4s7RvFzKxGSFT6IaUSw55p0DacoEK4hHkSi5K7Q== X-Received: by 10.176.4.196 with SMTP id 62mr875803uaw.172.1484722710825; Tue, 17 Jan 2017 22:58:30 -0800 (PST) MIME-Version: 1.0 Received: by 10.31.59.5 with HTTP; Tue, 17 Jan 2017 22:58:30 -0800 (PST) Received: by 10.31.59.5 with HTTP; Tue, 17 Jan 2017 22:58:30 -0800 (PST) In-Reply-To: References: From: Jon Pike Date: Tue, 17 Jan 2017 22:58:30 -0800 Message-ID: To: make-wifi-fast@lists.bufferbloat.net Content-Type: multipart/alternative; boundary=94eb2c1255f0c4cd8b054658f1af Subject: Re: [Make-wifi-fast] Fwd: [PATCH] mac80211: prevent skb/txq mismatch X-BeenThere: make-wifi-fast@lists.bufferbloat.net X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jan 2017 06:58:31 -0000 --94eb2c1255f0c4cd8b054658f1af Content-Type: text/plain; charset=UTF-8 I'm pretty clueless on this, but as a single data point, my Archer C7 has abt 21 days of uptime now, since my last update, as the single router in a 4 person household. I've been running cake/piece of cake the whole time. Standard disclaimers apply as to clueless user not knowing if his FW version has anything to do with the issue in question, or if its connected to other things like whatever is going on with the airtime fairness. But the comment in the third paragraph sounded interesting in light of my lack of a crash and running a SQM method, FWIW. My last update was a sysupgrade to LEDE Reboot SNAPSHOT r2687-dc5f496 pretty sure date was 12-27-16. Today's Topics: 1. Fwd: [PATCH] mac80211: prevent skb/txq mismatch (Dave Taht) ---------- Forwarded message ---------- From: Dave Taht To: make-wifi-fast@lists.bufferbloat.net Cc: Date: Thu, 12 Jan 2017 10:44:12 -0800 Subject: [Make-wifi-fast] Fwd: [PATCH] mac80211: prevent skb/txq mismatch yea! (I think) ---------- Forwarded message ---------- From: Michal Kazior Date: Thu, Jan 12, 2017 at 6:28 AM Subject: [PATCH] mac80211: prevent skb/txq mismatch To: johannes@sipsolutions.net Cc: linux-wireless@vger.kernel.org, greearb@candelatech.com, mohammed@qti.qualcomm.com, Michal Kazior Station structure is considered as not uploaded (to driver) until drv_sta_state() finishes. This call is however done after the structure is attached to mac80211 internal lists and hashes. This means mac80211 can lookup (and use) station structure before it is uploaded to a driver. If this happens (structure exists, but sta->uploaded is false) fast_tx path can still be taken. Deep in the fastpath call the sta->uploaded is checked against to derive "pubsta" argument for ieee80211_get_txq(). If sta->uploaded is false (and sta is actually non-NULL) ieee80211_get_txq() effectively downgraded to vif->txq. At first glance this may look innocent but coerces mac80211 into a state that is almost guaranteed (codel may drop offending skb) to crash because a station-oriented skb gets queued up on vif-oriented txq. The ieee80211_tx_dequeue() ends up looking at info->control.flags and tries to use txq->sta which in the fail case is NULL. .......... _______________________________________________ Make-wifi-fast mailing list Make-wifi-fast@lists.bufferbloat.net https://lists.bufferbloat.net/listinfo/make-wifi-fast --94eb2c1255f0c4cd8b054658f1af Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I'm pretty clueless on this, =C2=A0but as a single da= ta point, my Archer C7 has abt 21 days of uptime now, since my last update,= as the single router in a 4 person household.=C2=A0 I've been running = cake/piece of cake the whole time.

Standard disclaimers apply as to clueless user not knowing if his FW v= ersion has anything to do with the issue in question, or if its connected t= o other things like whatever is going on with the airtime fairness.=C2=A0 B= ut the comment in the third paragraph sounded interesting in light of my la= ck of a crash and running a SQM method, FWIW.
<= br>
My last update was a sysupgrade to LEDE= Reboot SNAPSHOT r2687-dc5f496 pretty sure date was 12-27-16.


Today's Topics:

=C2=A0 =C2=A01. Fwd: [PATCH] mac80211: prevent skb/txq mismatch (Dave Taht)=


---------- Forwarded message ----------
From:=C2=A0Dave Taht <= ;dave.taht@gmail.c= om>
To:=C2=A0make-wifi-fast@lists.bufferbloat.net
Cc:= =C2=A0
Date:=C2=A0Thu, 12 Jan 2017 10:44:12 -0800
Subject:=C2=A0[Make= -wifi-fast] Fwd: [PATCH] mac80211: prevent skb/txq mismatch
yea! (I thin= k)


---------- Forwarded message ----------
From: Michal Kazior <michal.kazior@tieto.com>
Date: Thu, Jan 12, 2017 at 6:28 AM
Subject: [PATCH] mac80211: prevent skb/txq mismatch
To: johannes= @sipsolutions.net
Cc: lin= ux-wireless@vger.kernel.org, greearb@candelatech.com,
mohammed@qti= .qualcomm.com, Michal Kazior <michal.kazior@tieto.com>


Station structure is considered as not uploaded
(to driver) until drv_sta_state() finishes. This
call is however done after the structure is
attached to mac80211 internal lists and hashes.
This means mac80211 can lookup (and use) station
structure before it is uploaded to a driver.

If this happens (structure exists, but
sta->uploaded is false) fast_tx path can still be
taken. Deep in the fastpath call the sta->uploaded
is checked against to derive "pubsta" argument for
ieee80211_get_txq(). If sta->uploaded is false
(and sta is actually non-NULL) ieee80211_get_txq()
effectively downgraded to vif->txq.

At first glance this may look innocent but coerces
mac80211 into a state that is almost guaranteed
(codel may drop offending skb) to crash because a
station-oriented skb gets queued up on
vif-oriented txq. The ieee80211_tx_dequeue() ends
up looking at info->control.flags and tries to use
txq->sta which in the fail case is NULL.
..........

_______________________________________________
Make-wifi-fast mailing list
M= ake-wifi-fast@lists.bufferbloat.net
https://lists.bufferbloat.net/listinfo/mak= e-wifi-fast

--94eb2c1255f0c4cd8b054658f1af--