* [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart
@ 2020-12-15 17:30 Youghandhar Chintala
2021-02-05 22:02 ` Abhishek Kumar
2021-02-12 8:36 ` Johannes Berg
0 siblings, 2 replies; 4+ messages in thread
From: Youghandhar Chintala @ 2020-12-15 17:30 UTC (permalink / raw)
To: johannes
Cc: davem, kuba, linux-wireless, netdev, linux-kernel, kuabhs,
dianders, briannorris, pillair, Youghandhar Chintala
Many wifi drivers (e.g. ath10k using qualcomm wifi chipsets)
support silent target hardware restart/recovery. Out of these
drivers which support target hw restart, certain chipsets
have the wifi mac sequence number addition for transmitted
frames done by the firmware. For such chipsets, a silent
target hardware restart breaks the continuity of the wifi
mac sequence number, since the wifi mac sequence number
restarts from 0 after the restart, which in-turn leads
to the peer access point dropping all the frames from device
until it receives the frame with the mac sequence which was
expected by the AP.
Add a wiphy flag for the driver to indicate that it needs a
trigger for STA disconnect after hardware restart.
Tested on ath10k using WCN3990, QCA6174.
Signed-off-by: Youghandhar Chintala <youghand@codeaurora.org>
---
include/net/cfg80211.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index ab249ca..7fba6f6 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -4311,6 +4311,9 @@ struct cfg80211_ops {
* @WIPHY_FLAG_HAS_STATIC_WEP: The device supports static WEP key installation
* before connection.
* @WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK: The device supports bigger kek and kck keys
+ * @WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART: The device needs a trigger to
+ * disconnect STA after target hardware restart. This flag should be
+ * exposed by drivers which support target recovery.
*/
enum wiphy_flags {
WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK = BIT(0),
@@ -4337,6 +4340,7 @@ enum wiphy_flags {
WIPHY_FLAG_SUPPORTS_5_10_MHZ = BIT(22),
WIPHY_FLAG_HAS_CHANNEL_SWITCH = BIT(23),
WIPHY_FLAG_HAS_STATIC_WEP = BIT(24),
+ WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART = BIT(25),
};
/**
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart
2020-12-15 17:30 [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart Youghandhar Chintala
@ 2021-02-05 22:02 ` Abhishek Kumar
2021-02-12 8:36 ` Johannes Berg
1 sibling, 0 replies; 4+ messages in thread
From: Abhishek Kumar @ 2021-02-05 22:02 UTC (permalink / raw)
To: Youghandhar Chintala
Cc: Johannes Berg, David S. Miller, Jakub Kicinski, linux-wireless,
netdev, LKML, Douglas Anderson, Brian Norris, Rakesh Pillai
LGTM! If no one has any objections, I would be happy to see this
considered for upstream.
Reviewed-by: Abhishek Kumar <kuabhs@chromium.org>
Thanks
Abhishek
On Tue, Dec 15, 2020 at 9:30 AM Youghandhar Chintala
<youghand@codeaurora.org> wrote:
>
> Many wifi drivers (e.g. ath10k using qualcomm wifi chipsets)
> support silent target hardware restart/recovery. Out of these
> drivers which support target hw restart, certain chipsets
> have the wifi mac sequence number addition for transmitted
> frames done by the firmware. For such chipsets, a silent
> target hardware restart breaks the continuity of the wifi
> mac sequence number, since the wifi mac sequence number
> restarts from 0 after the restart, which in-turn leads
> to the peer access point dropping all the frames from device
> until it receives the frame with the mac sequence which was
> expected by the AP.
>
> Add a wiphy flag for the driver to indicate that it needs a
> trigger for STA disconnect after hardware restart.
>
> Tested on ath10k using WCN3990, QCA6174.
>
> Signed-off-by: Youghandhar Chintala <youghand@codeaurora.org>
> ---
> include/net/cfg80211.h | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
> index ab249ca..7fba6f6 100644
> --- a/include/net/cfg80211.h
> +++ b/include/net/cfg80211.h
> @@ -4311,6 +4311,9 @@ struct cfg80211_ops {
> * @WIPHY_FLAG_HAS_STATIC_WEP: The device supports static WEP key installation
> * before connection.
> * @WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK: The device supports bigger kek and kck keys
> + * @WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART: The device needs a trigger to
> + * disconnect STA after target hardware restart. This flag should be
> + * exposed by drivers which support target recovery.
> */
> enum wiphy_flags {
> WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK = BIT(0),
> @@ -4337,6 +4340,7 @@ enum wiphy_flags {
> WIPHY_FLAG_SUPPORTS_5_10_MHZ = BIT(22),
> WIPHY_FLAG_HAS_CHANNEL_SWITCH = BIT(23),
> WIPHY_FLAG_HAS_STATIC_WEP = BIT(24),
> + WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART = BIT(25),
> };
>
> /**
> --
> 2.7.4
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart
2020-12-15 17:30 [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart Youghandhar Chintala
2021-02-05 22:02 ` Abhishek Kumar
@ 2021-02-12 8:36 ` Johannes Berg
1 sibling, 0 replies; 4+ messages in thread
From: Johannes Berg @ 2021-02-12 8:36 UTC (permalink / raw)
To: Youghandhar Chintala
Cc: davem, kuba, linux-wireless, netdev, linux-kernel, kuabhs,
dianders, briannorris, pillair
On Tue, 2020-12-15 at 23:00 +0530, Youghandhar Chintala wrote:
>
> * @WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK: The device supports bigger kek and kck keys
> + * @WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART: The device needs a trigger to
> + * disconnect STA after target hardware restart. This flag should be
> + * exposed by drivers which support target recovery.
You're not doing anything with this information in cfg80211, so
consequently it doesn't belong there.
johannes
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart
@ 2020-12-15 17:21 Youghandhar Chintala
0 siblings, 0 replies; 4+ messages in thread
From: Youghandhar Chintala @ 2020-12-15 17:21 UTC (permalink / raw)
To: johannes
Cc: davem, kuba, linux-wireless, netdev, linux-kernel, kuabhs,
dianders, briannorris, pillair, Youghandhar Chintala
Many wifi drivers (e.g. ath10k using qualcomm wifi chipsets)
support silent target hardware restart/recovery. Out of these
drivers which support target hw restart, certain chipsets
have the wifi mac sequence number addition for transmitted
frames done by the firmware. For such chipsets, a silent
target hardware restart breaks the continuity of the wifi
mac sequence number, since the wifi mac sequence number
restarts from 0 after the restart, which in-turn leads
to the peer access point dropping all the frames from device
until it receives the frame with the mac sequence which was
expected by the AP.
Add a wiphy flag for the driver to indicate that it needs a
trigger for STA disconnect after hardware restart.
Tested on ath10k using WCN3990, QCA6174.
Signed-off-by: Youghandhar Chintala <youghand@codeaurora.org>
---
include/net/cfg80211.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index ab249ca..7fba6f6 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -4311,6 +4311,9 @@ struct cfg80211_ops {
* @WIPHY_FLAG_HAS_STATIC_WEP: The device supports static WEP key installation
* before connection.
* @WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK: The device supports bigger kek and kck keys
+ * @WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART: The device needs a trigger to
+ * disconnect STA after target hardware restart. This flag should be
+ * exposed by drivers which support target recovery.
*/
enum wiphy_flags {
WIPHY_FLAG_SUPPORTS_EXT_KEK_KCK = BIT(0),
@@ -4337,6 +4340,7 @@ enum wiphy_flags {
WIPHY_FLAG_SUPPORTS_5_10_MHZ = BIT(22),
WIPHY_FLAG_HAS_CHANNEL_SWITCH = BIT(23),
WIPHY_FLAG_HAS_STATIC_WEP = BIT(24),
+ WIPHY_FLAG_STA_DISCONNECT_ON_HW_RESTART = BIT(25),
};
/**
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-02-12 8:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-15 17:30 [PATCH 1/3] cfg80211: Add wiphy flag to trigger STA disconnect after hardware restart Youghandhar Chintala
2021-02-05 22:02 ` Abhishek Kumar
2021-02-12 8:36 ` Johannes Berg
-- strict thread matches above, loose matches on Subject: below --
2020-12-15 17:21 Youghandhar Chintala
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).