Skip to content

Commit

Permalink
Merge branch 'bananapi4' of github.com:rmandrad/openwrt into bananapi4
Browse files Browse the repository at this point in the history
  • Loading branch information
N-Storm committed Oct 7, 2024
2 parents 56990a0 + e2f20a2 commit fcf09a5
Show file tree
Hide file tree
Showing 11 changed files with 210 additions and 199 deletions.
21 changes: 21 additions & 0 deletions package/firmware/wireless-regdb/patches/999-GB-add-320mhz.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
--- a/db.txt
+++ b/db.txt
@@ -705,13 +705,13 @@
# GB: https://www.ofcom.org.uk/__data/assets/pdf_file/0028/84970/ir-2030.pdf
# GB: https://www.ofcom.org.uk/__data/assets/pdf_file/0013/126121/Statement_Implementing-Ofcoms-decision-on-the-57-71GHz-band.pdf
country GB: DFS-ETSI
- (2400 - 2483.5 @ 40), (100 mW)
- (5150 - 5250 @ 80), (200 mW), NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
- (5250 - 5350 @ 80), (100 mW), NO-OUTDOOR, DFS, AUTO-BW, wmmrule=ETSI
+ (2400 - 2483.5 @ 40), (250 mW)
+ (5150 - 5250 @ 80), (250 mW), NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
+ (5250 - 5350 @ 80), (250 mW), NO-OUTDOOR, DFS, AUTO-BW, wmmrule=ETSI
(5470 - 5730 @ 160), (500 mW), DFS, wmmrule=ETSI
# short range devices (ETSI EN 300 440-1)
- (5725 - 5850 @ 80), (200 mW), NO-OUTDOOR
- (5925 - 6425 @ 160), (250 mW), NO-OUTDOOR, wmmrule=ETSI
+ (5725 - 5850 @ 80), (500 mW), NO-OUTDOOR
+ (5925 - 6425 @ 320), (500 mW), NO-OUTDOOR, wmmrule=ETSI
# 60 GHz band channels 1-6
(57000 - 71000 @ 2160), (40)

This file was deleted.

10 changes: 5 additions & 5 deletions package/kernel/mt76/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ PKG_RELEASE=1
PKG_LICENSE:=GPLv2
PKG_LICENSE_FILES:=

#PKG_SOURCE_URL:=https://github.com/openwrt/mt76
PKG_SOURCE_URL:=https://github.com/rmandrad/mt76
PKG_SOURCE_URL:=https://github.com/openwrt/mt76
#PKG_SOURCE_URL:=https://github.com/rmandrad/mt76
PKG_SOURCE_PROTO:=git
PKG_SOURCE_DATE:=2024-09-29
PKG_SOURCE_DATE:=2024-10-06
#PKG_SOURCE_VERSION:=680bc70f161fde0f167e2ae50c771be4775eb50a
PKG_SOURCE_VERSION:=6db91bfbc17863f034ca511526ebf7cd85c38858
PKG_MIRROR_HASH:=f97e40c7e7d6dc98f3b14eb03dc003e4a249329b7fc2ba51952d34b2831e6824
PKG_SOURCE_VERSION:=82a452919f525a29a6d1a140dc6df2e50ec4df19
PKG_MIRROR_HASH:=dce25a8f93a00f7dbab89d1fb6a2f1e4f97b8e71ffdbf3e2f8873100132d3dcf

PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
PKG_USE_NINJA:=0
Expand Down
64 changes: 0 additions & 64 deletions package/kernel/mt76/patches/100-api_update.patch

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ hostapd_common_add_device_config() {
config_add_int rts_threshold
config_add_int rssi_reject_assoc_rssi
config_add_int rssi_ignore_probe_request
config_add_int rssi_reject_assoc_timeout
config_add_int maxassoc
config_add_int reg_power_type
config_add_boolean stationary_ap
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ mac80211_hostapd_setup_base() {
ht_capab=
case "$htmode" in
VHT20|HT20|HE20|EHT20) ;;
HT40*|VHT40|VHT80|VHT160|HE40*|HE80|HE160|EHT40*|EHT80|EHT160|EHT320*)
HT40*|VHT40|VHT80|VHT160|HE40*|HE80|HE160|EHT40*|EHT80|EHT160)
case "$hwmode" in
a)
case "$(( (($channel / 4) + $chan_ofs) % 2 ))" in
Expand Down Expand Up @@ -219,28 +219,32 @@ mac80211_hostapd_setup_base() {
[ -n "$ieee80211n" ] && {
append base_cfg "ieee80211n=1" "$N"

set_default ht_coex 0
append base_cfg "ht_coex=$ht_coex" "$N"
set_default ht_coex 0
append base_cfg "ht_coex=$ht_coex" "$N"

[ "$ht_coex" -eq 1 ] && {
set_default obss_interval 300
append base_cfg "obss_interval=$obss_interval" "$N"
}

json_get_vars \
ldpc:1 \
greenfield:0 \
short_gi_20:1 \
short_gi_40:1 \
tx_stbc:1 \
rx_stbc:3 \
max_amsdu:1 \
dsss_cck_40:1
json_get_vars \
ldpc:1 \
greenfield:0 \
short_gi_20:1 \
short_gi_40:1 \
tx_stbc:1 \
rx_stbc:3 \
max_amsdu:1 \
dsss_cck_40:1

ht_cap_mask=0
for cap in $(iw phy "$phy" info | grep 'Capabilities: 0x' | cut -d: -f2); do
ht_cap_mask="$(($ht_cap_mask | $cap))"
done

[ "$band" = "2g" ] && {
ht_cap_mask=$(iw phy phy0 info | grep 'Band 1:' -A 1 | grep 'Capabilities: ' | cut -d: -f2)
}
[ "$band" = "5g" ] && {
ht_cap_mask=$(iw phy phy1 info | grep 'Band 2:' -A 1 | grep 'Capabilities: ' | cut -d: -f2)
}

cap_rx_stbc=$((($ht_cap_mask >> 8) & 3))
[ "$rx_stbc" -lt "$cap_rx_stbc" ] && cap_rx_stbc="$rx_stbc"
Expand Down Expand Up @@ -270,6 +274,8 @@ mac80211_hostapd_setup_base() {

idx="$channel"
case "$htmode" in
VHT20|HE20|EHT20) enable_ac=1;;
VHT40|HE40|EHT40)
VHT20|HE20|EHT20) enable_ac=1;;
VHT40|HE40|EHT40)
case "$(( (($channel / 4) + $chan_ofs) % 2 ))" in
Expand All @@ -279,6 +285,7 @@ mac80211_hostapd_setup_base() {
enable_ac=1
vht_center_seg0=$idx
;;
VHT80|HE80|EHT80)
VHT80|HE80|EHT80)
case "$(( (($channel / 4) + $chan_ofs) % 4 ))" in
1) idx=$(($channel + 6));;
Expand Down Expand Up @@ -396,7 +403,7 @@ mac80211_hostapd_setup_base() {
mu_beamformee:1 \
vht_txop_ps:1 \
htc_vht:1 \
beamformee_antennas:4 \
beamformee_antennas:5 \
beamformer_antennas:4 \
rx_antenna_pattern:1 \
tx_antenna_pattern:1 \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import * as uci from 'uci';

const bands_order = [ "6G", "5G", "2G" ];
const htmode_order = [ "EHT", "HE", "VHT", "HT" ];
const htmode_order = [ "EHT", "HE", "VHT", "HT" ];

let board = json(readfile("/etc/board.json"));
if (!board.wlan)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ function wiphy_detect() {
band_info.vht = true;
let he_phy_cap = 0;
let eht_phy_cap = 0;
let eht_phy_cap = 0;
for (let ift in band.iftype_data) {
if (!ift.he_cap_phy)
Expand All @@ -127,6 +128,12 @@ function wiphy_detect() {
band_info.eht = true;
eht_phy_cap |= ift.eht_cap_phy[0];
if (!ift.eht_cap_phy)
continue;
band_info.eht = true;
eht_phy_cap |= ift.eht_cap_phy[0];
}
if (band_name != "2G" &&
Expand All @@ -149,17 +156,23 @@ function wiphy_detect() {
push(modes, "HE20");
if (band_info.eht)
push(modes, "EHT20");
if (band_info.eht)
push(modes, "EHT20");
if (band.ht_capa & 0x2) {
push(modes, "HT40");
if (band_info.vht)
push(modes, "VHT40")
}
if (he_phy_cap & 2)
if (he_phy_cap & 2)
push(modes, "HE40");
if (eht_phy_cap && he_phy_cap & 2)
push(modes, "EHT40");
if (eht_phy_cap && he_phy_cap & 2)
push(modes, "EHT40");
for (let freq in band.freqs) {
if (freq.disabled)
continue;
Expand All @@ -173,6 +186,11 @@ function wiphy_detect() {
if (band_name == "2G")
continue;
if (he_phy_cap & 4)
push(modes, "HE40");
if (eht_phy_cap && he_phy_cap & 4)
push(modes, "EHT40");
if (he_phy_cap & 4)
push(modes, "HE40");
if (eht_phy_cap && he_phy_cap & 4)
Expand All @@ -183,6 +201,8 @@ function wiphy_detect() {
push(modes, "HE80");
if (eht_phy_cap && he_phy_cap & 4)
push(modes, "EHT80");
if (eht_phy_cap && he_phy_cap & 4)
push(modes, "EHT80");
if ((band.vht_capa >> 2) & 0x3)
push(modes, "VHT160");
if (he_phy_cap & 0x18)
Expand Down
4 changes: 4 additions & 0 deletions package/network/services/hostapd/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ ifneq ($(CONFIG_DRIVER_11BE_SUPPORT),)
HOSTAPD_IEEE80211BE:=y
endif

ifneq ($(CONFIG_DRIVER_11BE_SUPPORT),)
HOSTAPD_IEEE80211BE:=y
endif

CORE_DEPENDS = +ucode +libubus +libucode +ucode-mod-fs +ucode-mod-nl80211 +ucode-mod-rtnl +ucode-mod-ubus +ucode-mod-uloop +libblobmsg-json +libudebug
OPENSSL_DEPENDS = +PACKAGE_$(1):libopenssl +PACKAGE_$(1):libopenssl-legacy

Expand Down
Loading

0 comments on commit fcf09a5

Please sign in to comment.