From: Lorenzo Bianconi <lorenzo@kernel.org>
To: Kalle Valo <kvalo@codeaurora.org>
Cc: Felix Fietkau <nbd@nbd.name>,
linux-wireless <linux-wireless@vger.kernel.org>
Subject: Re: pull request: mt76 2020-12-04 v2
Date: Mon, 7 Dec 2020 15:49:05 +0100 [thread overview]
Message-ID: <20201207144905.GA292338@lore-desk> (raw)
In-Reply-To: <20201207102432.AD525C433C6@smtp.codeaurora.org>
[-- Attachment #1: Type: text/plain, Size: 4220 bytes --]
> Felix Fietkau <nbd@nbd.name> wrote:
>
> > Hi Kalle,
> >
> > sorry about the last one. Here's the updated PR with the missing
> > S-o-b fixed.
> >
> > - Felix
> >
> > The following changes since commit 9eb597c74483ad5c230a884449069adfb68285ea:
> >
> > Merge ath-next from git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git (2020-12-02 21:46:55 +0200)
> >
> > are available in the Git repository at:
> >
> > https://github.com/nbd168/wireless tags/mt76-for-kvalo-2020-12-04
> >
> > for you to fetch changes up to f12758f6f929dbcd37abdb1d91d245539eca48f8:
> >
> > mt76: mt7615: Fix fall-through warnings for Clang (2020-12-04 22:24:54 +0100)
> >
> > ----------------------------------------------------------------
> > mt76 patches for 5.11
> >
> > * mt7915 fixes
> > * mt7615 fixes
> > * support for more sta interfaces on mt7615/mt7915
> > * mt7915 encap offload
> > * performance improvements
> > * channel noise report on mt7915
> > * usb/sdio support improvements
> > * mt7915 testmode support
> > * mt7915 DBDC support
> > * warning fixes
> >
> > ----------------------------------------------------------------
>
> This conflicted with commit 807982017730 ("mt76: usb: fix crash on device
> removal") from wireless-drivers. I fixed with a diff below and pushed it to the
> pending branch:
>
> https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next.git/commit/?h=pending&id=f4a243bfdb0d9afc850d35755dc0bae0b980b4ac
>
> Please double check my resolution. Also I wonder should the usb.status_worker
> have a similar fix as tx_worker had? If yes, someone please send a followup
> patch for that.
Hi Kalle,
the patch seems fine to me, probably we can move
mt76_worker_{disable,enable}(&dev->usb.status_worker) inside the if (!ret)
block as originally done by Stanislaw. Something like:
diff --git a/drivers/net/wireless/mediatek/mt76/usb.c b/drivers/net/wireless/mediatek/mt76/usb.c
index dc850109de22..18444f26103e 100644
--- a/drivers/net/wireless/mediatek/mt76/usb.c
+++ b/drivers/net/wireless/mediatek/mt76/usb.c
@@ -1039,8 +1039,6 @@ void mt76u_stop_tx(struct mt76_dev *dev)
{
int ret;
- mt76_worker_disable(&dev->usb.status_worker);
-
ret = wait_event_timeout(dev->tx_wait, !mt76_has_tx_pending(&dev->phy),
HZ / 5);
if (!ret) {
@@ -1059,6 +1057,7 @@ void mt76u_stop_tx(struct mt76_dev *dev)
usb_kill_urb(q->entry[j].urb);
}
+ mt76_worker_disable(&dev->usb.status_worker);
mt76_worker_disable(&dev->tx_worker);
/* On device removal we maight queue skb's, but mt76u_tx_kick()
@@ -1077,13 +1076,12 @@ void mt76u_stop_tx(struct mt76_dev *dev)
}
mt76_worker_enable(&dev->tx_worker);
+ mt76_worker_enable(&dev->usb.status_worker);
}
cancel_work_sync(&dev->usb.stat_work);
clear_bit(MT76_READING_STATS, &dev->phy.state);
- mt76_worker_enable(&dev->usb.status_worker);
-
mt76_tx_status_check(dev, NULL, true);
}
EXPORT_SYMBOL_GPL(mt76u_stop_tx);
Regards,
Lorenzo
>
> diff --cc drivers/net/wireless/mediatek/mt76/usb.c
> index f1ae9ff835b2,81393788f98e..000000000000
> --- a/drivers/net/wireless/mediatek/mt76/usb.c
> +++ b/drivers/net/wireless/mediatek/mt76/usb.c
> @@@ -1020,6 -1039,9 +1039,8 @@@ void mt76u_stop_tx(struct mt76_dev *dev
> {
> int ret;
>
> - mt76_worker_disable(&dev->tx_worker);
> + mt76_worker_disable(&dev->usb.status_worker);
> +
> ret = wait_event_timeout(dev->tx_wait, !mt76_has_tx_pending(&dev->phy),
> HZ / 5);
> if (!ret) {
> @@@ -1061,6 -1078,9 +1082,8 @@@
> cancel_work_sync(&dev->usb.stat_work);
> clear_bit(MT76_READING_STATS, &dev->phy.state);
>
> - mt76_worker_enable(&dev->tx_worker);
> + mt76_worker_enable(&dev->usb.status_worker);
> +
> mt76_tx_status_check(dev, NULL, true);
> }
> EXPORT_SYMBOL_GPL(mt76u_stop_tx);
>
>
>
> --
> https://patchwork.kernel.org/project/linux-wireless/patch/f42bcdc1-2cd4-9f44-2889-bbb9e10e038a@nbd.name/
>
> https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2020-12-07 14:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-18 10:38 pull request: mt76 2020-11-18 Felix Fietkau
2020-12-02 19:18 ` Kalle Valo
[not found] ` <20201202191852.525E8C43461@smtp.codeaurora.org>
2020-12-04 13:44 ` pull request: mt76 2020-12-04 Felix Fietkau
2020-12-04 20:29 ` Kalle Valo
2020-12-04 21:29 ` pull request: mt76 2020-12-04 v2 Felix Fietkau
2020-12-07 10:24 ` Kalle Valo
2020-12-07 14:49 ` Lorenzo Bianconi [this message]
2020-12-08 7:42 ` Kalle Valo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201207144905.GA292338@lore-desk \
--to=lorenzo@kernel.org \
--cc=kvalo@codeaurora.org \
--cc=linux-wireless@vger.kernel.org \
--cc=nbd@nbd.name \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).