From: Kalle Valo <kvalo@codeaurora.org>
To: "Rafał Miłecki" <zajec5@gmail.com>
Cc: "Rafał Miłecki" <zajec5@gmail.com>,
"Arend van Spriel" <arend.vanspriel@broadcom.com>,
"Franky Lin" <franky.lin@broadcom.com>,
"Hante Meuleman" <hante.meuleman@broadcom.com>,
"Pieter-Paul Giesberts" <pieter-paul.giesberts@broadcom.com>,
"Franky (Zhenhui) Lin" <frankyl@broadcom.com>,
linux-wireless@vger.kernel.org (open list:BROADCOM BRCM80211
IEEE802.11n WIRELESS DRIVER),
brcm80211-dev-list.pdl@broadcom.com (open list:BROADCOM
BRCM80211 IEEE802.11n WIRELESS DRIVER),
netdev@vger.kernel.org (open list:NETWORKING DRIVERS),
linux-kernel@vger.kernel.org (open list)
Subject: Re: [1/2] brcmfmac: delete interface directly in code that sent fw request
Date: Fri, 8 Jul 2016 13:46:05 +0000 (UTC) [thread overview]
Message-ID: <20160708134605.3BF7E60260@smtp.codeaurora.org> (raw)
In-Reply-To: <1467230067-3302-2-git-send-email-zajec5@gmail.com>
Rafał Miłecki wrote:
> So far when receiving event about in-firmware-interface removal our
> event worker was notifying listener and afterwards it was removing Linux
> interface.
>
> First of all it was resulting in slightly unexpected order. The listener
> (del_virtual_intf callback) was (usually) returning with success before
> we even called unregister_netdev(ice).
>
> Please note this couldn't be simply fixed by changing order of calls in
> brcmf_fweh_handle_if_event as unregistering interface earlier could free
> struct brcmf_if.
>
> Another problem of current implementation are possible lockups. Focus on
> the time slot between calling event handler and removing Linux
> interface. During that time original caller may leave (unlocking rtnl
> semaphore) *and* another call to the same code may be done (locking it
> again). If that happens our event handler will stuck at removing Linux
> interface, it won't handle another event and will block process holding
> rtnl lock.
>
> This can be simply solved by unregistering interface in a proper
> callback, right after receiving confirmation event from firmware. This
> only required modifying worker to don't unregister on its own if there
> is someone waiting for the event.
>
> Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Thanks, 2 patches applied to wireless-drivers-next.git:
a63b09872c1d brcmfmac: delete interface directly in code that sent fw request
dba8fbc67ecd brcmfmac: support removing AP interfaces with "interface_remove"
--
Sent by pwcli
https://patchwork.kernel.org/patch/9206157/
next prev parent reply other threads:[~2016-07-08 13:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-18 18:18 [PATCH RFC 1/2] brcmfmac: remove interface before notifying listener Rafał Miłecki
2016-06-18 18:18 ` [PATCH RFC 2/2] brcmfmac: support removing AP interfaces with "interface_remove" Rafał Miłecki
2016-06-18 18:18 ` Rafał Miłecki
2016-06-18 19:32 ` Arend van Spriel
2016-06-18 19:26 ` [PATCH RFC 1/2] brcmfmac: remove interface before notifying listener Arend van Spriel
2016-06-18 21:58 ` Rafał Miłecki
2016-06-18 21:58 ` Rafał Miłecki
2016-06-18 22:42 ` Rafał Miłecki
2016-06-19 16:23 ` [PATCH V2 RFC 1/2] brcmfmac: delete interface directly in code that sent fw request Rafał Miłecki
2016-06-19 16:23 ` Rafał Miłecki
2016-06-19 16:23 ` [PATCH V2 RFC 2/2] brcmfmac: support removing AP interfaces with "interface_remove" Rafał Miłecki
[not found] ` <1467230067-3302-1-git-send-email-zajec5@gmail.com>
2016-06-29 19:54 ` [PATCH 1/2] brcmfmac: delete interface directly in code that sent fw request Rafał Miłecki
2016-07-08 13:46 ` Kalle Valo [this message]
2016-06-29 19:54 ` [PATCH 2/2] brcmfmac: support removing AP interfaces with "interface_remove" Rafał Miłecki
2016-06-29 19:57 ` [PATCH 0/2] brcmfmac: support removing AP interfaces with new fw Rafał Miłecki
2016-06-29 19:57 ` Rafał Miłecki
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=20160708134605.3BF7E60260@smtp.codeaurora.org \
--to=kvalo@codeaurora.org \
--cc=arend.vanspriel@broadcom.com \
--cc=brcm80211-dev-list.pdl@broadcom.com \
--cc=franky.lin@broadcom.com \
--cc=frankyl@broadcom.com \
--cc=hante.meuleman@broadcom.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pieter-paul.giesberts@broadcom.com \
--cc=zajec5@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.