package/xr819-xradio: fix build failure on Linux 6.1
PATCH 1/1 package/xr819-xradio: fix build failure on Linux 6.1
Add 2 local patches pending upstream[0] to fix build failure with Linux 6.1
[0]: https://github.com/fifteenhex/xradio/pull/19
Fixes:
Still not produced
--- ...missing-prandom_u32-with-Linux-6.1.0.patch | 34 +++++++++++++++++++ ...ailure-due-to-ieee80211_nullfunc_get.patch | 34 +++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 package/xr819-xradio/0001-wsm.c-fix-missing-prandom_u32-with-Linux-6.1.0.patch create mode 100644 package/xr819-xradio/0002-ap.c-fix-build-failure-due-to-ieee80211_nullfunc_get.patch
package/xr819-xradio/0001-wsm.c-fix-missing-prandom_u32-with-Linux-6.1.0.patch new file +34 -0
@@ -0,0 +1,34 @@ +From d336006f0d9e9663a5ff61d38e98ddd33e175167 Mon Sep 17 00:00:00 2001 +From: Giulio Benetti <[email protected]> +Date: Fri, 30 Dec 2022 00:44:30 +0100 +Subject: [PATCH] wsm.c: fix missing prandom_u32() with Linux >= 6.1.0 + +prandom_u32() previously was only calling get_random_u32() so it's been +dropped with Linux 6.1.0. So let's directly call get_random_u32() if Linux +version >= 6.1.0. + +[Upstream status: https://github.com/fifteenhex/xradio/pull/19] +Signed-off-by: Giulio Benetti <[email protected]> +--- + wsm.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/wsm.c b/wsm.c +index 85eeef8..ea73770 100644 +--- a/wsm.c ++++ b/wsm.c +@@ -2609,7 +2609,11 @@ static int xradio_get_prio_queue(struct xradio_vif *priv, + edca = &priv->edca.params[i]; + score = ((edca->aifns + edca->cwMin) << 16) + + (edca->cwMax - edca->cwMin) * ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)) ++ (get_random_u32() & 0xFFFF); ++#else + (prandom_u32() & 0xFFFF); ++#endif + if (score < best && (winner < 0 || i != 3)) { + best = score; + winner = i; +-- +2.34.1 +
package/xr819-xradio/0002-ap.c-fix-build-failure-due-to-ieee80211_nullfunc_get.patch new file +34 -0
@@ -0,0 +1,34 @@ +From 5f0dd19dc8acad9816bb1b857551f3289e386d32 Mon Sep 17 00:00:00 2001 +From: Giulio Benetti <[email protected]> +Date: Fri, 30 Dec 2022 00:52:30 +0100 +Subject: [PATCH] ap.c: fix build failure due to ieee80211_nullfunc_get() + change in Linux 6.1 + +Starting from Linux 6.1 it's been added 'int link_id' parameter to +ieee80211_nullfunc_get() to comply to MSO, but this module doesn't support +it. So let's handle this case by passing default 0 as link_id parameter. + +[Upstream status: https://github.com/fifteenhex/xradio/pull/19] +Signed-off-by: Giulio Benetti <[email protected]> +--- + ap.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/ap.c b/ap.c +index 51b8a44..649d6bf 100644 +--- a/ap.c ++++ b/ap.c +@@ -1145,7 +1145,9 @@ static int xradio_upload_null(struct xradio_vif *priv) + .rate = 0xFF, + }; + +-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 17)) ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)) ++ frame.skb = ieee80211_nullfunc_get(priv->hw, priv->vif, 0, false); ++#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 17)) + frame.skb = ieee80211_nullfunc_get(priv->hw, priv->vif, false); + #else + frame.skb = ieee80211_nullfunc_get(priv->hw, priv->vif); +-- +2.34.1 +
Signature · 6 lines
2.34.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Please drop this patch since local patches have already been upstreamed. I will wait some day next time before submitting local patches and see if upstream merge them soon.
Patch with version bump comes soon.
Sorry for the noise
Best regards
Signature · 2 lines
Giulio Benetti CEO/CTO@Benetti Engineering sas
Quoted 85 lines · Giulio Benetti
Add 2 local patches pending upstream[0] to fix build failure with Linux 6.1
[0]: https://github.com/fifteenhex/xradio/pull/19
Fixes:
Still not producedSigned-off-by Giulio Benetti <[email protected]>--- ...missing-prandom_u32-with-Linux-6.1.0.patch | 34 +++++++++++++++++++ ...ailure-due-to-ieee80211_nullfunc_get.patch | 34 +++++++++++++++++++ 2 files changed, 68 insertions(+)create mode 100644
package/xr819-xradio/0001-wsm.c-fix-missing-prandom_u32-with-Linux-6.1.0.patchcreate mode 100644package/xr819-xradio/0002-ap.c-fix-build-failure-due-to-ieee80211_nullfunc_get.patchpackage/xr819-xradio/0001-wsm.c-fix-missing-prandom_u32-with-Linux-6.1.0.patch new file +34
-0@@ -0,0 +1,34 @@ +From d336006f0d9e9663a5ff61d38e98ddd33e175167 Mon Sep 17 00:00:00 2001 +From: Giulio Benetti <[email protected]> +Date: Fri, 30 Dec 2022 00:44:30 +0100 +Subject: [PATCH] wsm.c: fix missing prandom_u32() with Linux >= 6.1.0 + +prandom_u32() previously was only calling get_random_u32() so it's been +dropped with Linux 6.1.0. So let's directly call get_random_u32() if Linux +version >= 6.1.0. + +[Upstream status: https://github.com/fifteenhex/xradio/pull/19] +Signed-off-by: Giulio Benetti <[email protected]> +--- + wsm.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/wsm.c b/wsm.c +index 85eeef8..ea73770 100644 +--- a/wsm.c ++++ b/wsm.c +@@ -2609,7 +2609,11 @@ static int xradio_get_prio_queue(struct xradio_vif *priv, + edca = &priv->edca.params[i]; + score = ((edca->aifns + edca->cwMin) << 16) + + (edca->cwMax - edca->cwMin) * ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)) ++ (get_random_u32() & 0xFFFF); ++#else + (prandom_u32() & 0xFFFF); ++#endif + if (score < best && (winner < 0 || i != 3)) { + best = score; + winner = i; +-- +2.34.1 +package/xr819-xradio/0002-ap.c-fix-build-failure-due-to-ieee80211_nullfunc_get.patch new file +24
-0@@ -0,0 +1,34 @@ +From 5f0dd19dc8acad9816bb1b857551f3289e386d32 Mon Sep 17 00:00:00 2001 +From: Giulio Benetti <[email protected]> +Date: Fri, 30 Dec 2022 00:52:30 +0100 +Subject: [PATCH] ap.c: fix build failure due to ieee80211_nullfunc_get() + change in Linux 6.1 + +Starting from Linux 6.1 it's been added 'int link_id' parameter to +ieee80211_nullfunc_get() to comply to MSO, but this module doesn't support +it. So let's handle this case by passing default 0 as link_id parameter. + +[Upstream status: https://github.com/fifteenhex/xradio/pull/19] +Signed-off-by: Giulio Benetti <[email protected]> +--- + ap.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/ap.c b/ap.c +index 51b8a44..649d6bf 100644 +--- a/ap.c ++++ b/ap.c +@@ -1145,7 +1145,9 @@ static int xradio_upload_null(struct xradio_vif *priv) + .rate = 0xFF, + }; +
package/xr819-xradio/0002-ap.c-fix-build-failure-due-to-ieee80211_nullfunc_get.patch line 34
Quoted 10 lines
package/xr819-xradio/0002-ap.c-fix-build-failure-due-to-ieee80211_nullfunc_get.patch new file +10
-0+-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 17)) ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)) ++ frame.skb = ieee80211_nullfunc_get(priv->hw, priv->vif, 0, false); ++#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 17)) + frame.skb = ieee80211_nullfunc_get(priv->hw, priv->vif, false); + #else + frame.skb = ieee80211_nullfunc_get(priv->hw, priv->vif); +-- +2.34.1 +
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot