diff --git a/include/feeds.mk b/include/feeds.mk index e499ac2684..632fecb4a3 100644 --- a/include/feeds.mk +++ b/include/feeds.mk @@ -43,7 +43,7 @@ endef # 1: package name define GetABISuffix -$(call FormatABISuffix,$(1),$(if $(ABIV_$(1)),$(ABIV_$(1)),$(foreach v,$(wildcard $(STAGING_DIR)/pkginfo/$(1).version),$(shell cat $(v))))) +$(if $(ABIV_$(1)),$(ABIV_$(1)),$(call FormatABISuffix,$(1),$(foreach v,$(wildcard $(STAGING_DIR)/pkginfo/$(1).version),$(shell cat $(v))))) endef # 1: package name diff --git a/package/base-files/files/bin/config_generate b/package/base-files/files/bin/config_generate index 967ef1b100..f5367fbe3b 100755 --- a/package/base-files/files/bin/config_generate +++ b/package/base-files/files/bin/config_generate @@ -114,9 +114,17 @@ generate_network() { add network device set network.@device[-1].name='br-$1' set network.@device[-1].type='bridge' - set network.@device[-1].macaddr='$macaddr' EOF for port in $ports; do uci add_list network.@device[-1].ports="$port"; done + [ -n "$macaddr" ] && { + for port in $ports; do + uci -q batch <<-EOF + add network device + set network.@device[-1].name='$port' + set network.@device[-1].macaddr='$macaddr' + EOF + done + } device=br-$1 type= macaddr="" diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile index 0ade95e35e..d0620c556a 100644 --- a/package/kernel/mac80211/Makefile +++ b/package/kernel/mac80211/Makefile @@ -98,7 +98,7 @@ PKG_CONFIG_DEPENDS += \ define KernelPackage/cfg80211 $(call KernelPackage/mac80211/Default) TITLE:=cfg80211 - wireless configuration API - DEPENDS+= +iw +wireless-regdb + DEPENDS+= +iw +iwinfo +wireless-regdb ABI_VERSION:=$(PKG_VERSION)-$(PKG_RELEASE) FILES:= \ $(PKG_BUILD_DIR)/compat/compat.ko \ diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh index f8972da40c..ced0bf8b60 100644 --- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh +++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh @@ -116,7 +116,7 @@ mac80211_add_he_capabilities() { set -- $capab [ "$(($4))" -gt 0 ] || continue [ "$(((0x$2) & $3))" -gt 0 ] || { - eval "$4=0" + eval "$1=0" continue } append base_cfg "$1=1" "$N" diff --git a/package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch b/package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch new file mode 100644 index 0000000000..787254b4df --- /dev/null +++ b/package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch @@ -0,0 +1,23 @@ +From: Felix Fietkau +Date: Thu, 17 Jun 2021 12:05:54 +0200 +Subject: [PATCH] mac80211: minstrel_ht: fix sample time check + +We need to skip sampling if the next sample time is after jiffies, not before. +This patch fixes an issue where in some cases only very little sampling (or none +at all) is performed, leading to really bad data rates + +Fixes: 80d55154b2f8 ("mac80211: minstrel_ht: significantly redesign the rate probing strategy") +Signed-off-by: Felix Fietkau +--- + +--- a/net/mac80211/rc80211_minstrel_ht.c ++++ b/net/mac80211/rc80211_minstrel_ht.c +@@ -1498,7 +1498,7 @@ minstrel_ht_get_rate(void *priv, struct + (info->control.flags & IEEE80211_TX_CTRL_PORT_CTRL_PROTO)) + return; + +- if (time_is_before_jiffies(mi->sample_time)) ++ if (time_is_after_jiffies(mi->sample_time)) + return; + + mi->sample_time = jiffies + MINSTREL_SAMPLE_INTERVAL; diff --git a/package/utils/ugps/files/ugps.init b/package/utils/ugps/files/ugps.init index 3cd1ca1b8d..77c3603066 100644 --- a/package/utils/ugps/files/ugps.init +++ b/package/utils/ugps/files/ugps.init @@ -16,11 +16,16 @@ start_service() { local disabled="$(uci get gps.@gps[-1].disabled || echo 0)" [ "$disabled" == "0" ] || return + [ "$tty" ] || return - [ -c "$tty" ] || { - tty="/dev/$tty" - [ -c "$tty" ] || return - } + case "$tty" in + "/"*) + true + ;; + *) + tty="/dev/$tty" + ;; + esac procd_open_instance procd_set_param command "$PROG" diff --git a/scripts/json_overview_image_info.py b/scripts/json_overview_image_info.py index 8dbd24af2d..45c05012b1 100755 --- a/scripts/json_overview_image_info.py +++ b/scripts/json_overview_image_info.py @@ -18,19 +18,33 @@ work_dir = Path(getenv("WORK_DIR")) output = {} + +def get_initial_output(image_info): + # preserve existing profiles.json + if output_path.is_file(): + profiles = json.loads(output_path.read_text()) + if profiles["version_code"] == image_info["version_code"]: + return profiles + return image_info + + for json_file in work_dir.glob("*.json"): image_info = json.loads(json_file.read_text()) + if not output: - output.update(image_info) + output = get_initial_output(image_info) + + # get first and only profile in json file + device_id, profile = next(iter(image_info["profiles"].items())) + if device_id not in output["profiles"]: + output["profiles"][device_id] = profile else: - # get first (and only) profile in json file - device_id = next(iter(image_info["profiles"].keys())) - if device_id not in output["profiles"]: - output["profiles"].update(image_info["profiles"]) - else: - output["profiles"][device_id]["images"].append( - image_info["profiles"][device_id]["images"][0] - ) + output["profiles"][device_id]["images"].extend(profile["images"]) + +# make image lists unique by name, keep last/latest +for device_id, profile in output["profiles"].items(): + profile["images"] = list({e["name"]: e for e in profile["images"]}.values()) + if output: default_packages, output["arch_packages"] = run(