Skip to content

Commit 8fca74f

Browse files
Merge branch 'openwrt:main' into wax206
2 parents 8c0d667 + 902f739 commit 8fca74f

79 files changed

Lines changed: 16473 additions & 252 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

package/boot/uboot-ath79/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
include $(TOPDIR)/rules.mk
22
include $(INCLUDE_DIR)/kernel.mk
33

4-
PKG_VERSION:=2025.04
5-
PKG_HASH:=439d3bef296effd54130be6a731c5b118be7fddd7fcc663ccbc5fb18294d8718
4+
PKG_VERSION:=2025.10
5+
PKG_HASH:=b4f032848e56cc8f213ad59f9132c084dbbb632bc29176d024e58220e0efdf4a
66

77
UBOOT_USE_INTREE_DTC:=1
88

package/boot/uboot-ath79/patches/400-ath79-add-support-for-NEC-AR9344-Aterm-series.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Subject: [PATCH] ath79: add support for NEC AR9344 Aterm series
2222

2323
--- a/arch/mips/dts/Makefile
2424
+++ b/arch/mips/dts/Makefile
25-
@@ -24,6 +24,7 @@ dtb-$(CONFIG_BOARD_GARDENA_SMART_GATEWAY
25+
@@ -23,6 +23,7 @@ dtb-$(CONFIG_BOARD_GARDENA_SMART_GATEWAY
2626
dtb-$(CONFIG_BOARD_LINKIT_SMART_7688) += linkit-smart-7688.dtb
2727
dtb-$(CONFIG_TARGET_OCTEON_EBB7304) += mrvl,octeon-ebb7304.dtb
2828
dtb-$(CONFIG_TARGET_OCTEON_NIC23) += mrvl,octeon-nic23.dtb

package/boot/uboot-ath79/patches/401-mips-ath79-add-support-for-NEC-QCA9558-Aterm-series.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ mips: ath79: cleanup defconfig for NEC QCA9558 Aterm series
2323

2424
--- a/arch/mips/dts/Makefile
2525
+++ b/arch/mips/dts/Makefile
26-
@@ -25,6 +25,7 @@ dtb-$(CONFIG_BOARD_LINKIT_SMART_7688) +=
26+
@@ -24,6 +24,7 @@ dtb-$(CONFIG_BOARD_LINKIT_SMART_7688) +=
2727
dtb-$(CONFIG_TARGET_OCTEON_EBB7304) += mrvl,octeon-ebb7304.dtb
2828
dtb-$(CONFIG_TARGET_OCTEON_NIC23) += mrvl,octeon-nic23.dtb
2929
dtb-$(CONFIG_BOARD_NEC_AR9344_ATERM) += nec,ar9344-aterm.dtb

package/network/config/wifi-scripts/files-ucode/usr/share/ucode/wifi/hostapd.uc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,8 @@ function generate(config) {
483483
append_vars(config, [ 'noscan' ]);
484484

485485
/* airtime */
486-
append_vars(config, [ 'airtime_mode' ]);
486+
if (config.airtime_mode)
487+
append_vars(config, [ 'airtime_mode' ]);
487488

488489
/* assoc/thresholds */
489490
append_vars(config, [ 'rssi_reject_assoc_rssi', 'rssi_ignore_probe_request', 'iface_max_num_sta', 'no_probe_resp_if_max_sta' ]);
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
From: Felix Fietkau <nbd@nbd.name>
2+
Date: Thu, 9 Oct 2025 14:11:55 +0200
3+
Subject: [PATCH] fs: add mkdtemp() method for creating temporary directories
4+
5+
Returns the directory path as a string, following the same template
6+
handling pattern as mkstemp().
7+
8+
Signed-off-by: Felix Fietkau <nbd@nbd.name>
9+
---
10+
11+
--- a/lib/fs.c
12+
+++ b/lib/fs.c
13+
@@ -2632,6 +2632,86 @@ uc_fs_mkstemp(uc_vm_t *vm, size_t nargs)
14+
}
15+
16+
/**
17+
+ * Creates a unique temporary directory based on the given template.
18+
+ *
19+
+ * If the template argument is given and contains a relative path, the created
20+
+ * directory will be placed relative to the current working directory.
21+
+ *
22+
+ * If the template argument is given and contains an absolute path, the created
23+
+ * directory will be placed relative to the given directory.
24+
+ *
25+
+ * If the template argument is given but does not contain a directory separator,
26+
+ * the directory will be placed in `/tmp/`.
27+
+ *
28+
+ * If no template argument is given, the default `/tmp/XXXXXX` is used.
29+
+ *
30+
+ * The template argument must end with six consecutive X characters (`XXXXXX`),
31+
+ * which will be replaced with a random string to create the unique directory name.
32+
+ * If the template does not end with `XXXXXX`, it will be automatically appended.
33+
+ *
34+
+ * Returns a string containing the path of the created directory on success.
35+
+ *
36+
+ * Returns `null` if an error occurred, e.g. on insufficient permissions or
37+
+ * inaccessible directory.
38+
+ *
39+
+ * @function module:fs#mkdtemp
40+
+ *
41+
+ * @param {string} [template="/tmp/XXXXXX"]
42+
+ * The path template to use when forming the temporary directory name.
43+
+ *
44+
+ * @returns {?string}
45+
+ *
46+
+ * @example
47+
+ * // Create a unique temporary directory in the current working directory
48+
+ * const tempDir = mkdtemp('./data-XXXXXX');
49+
+ */
50+
+static uc_value_t *
51+
+uc_fs_mkdtemp(uc_vm_t *vm, size_t nargs)
52+
+{
53+
+ uc_value_t *template = uc_fn_arg(0);
54+
+ bool ends_with_template = false;
55+
+ char *path, *t, *result;
56+
+ uc_value_t *rv;
57+
+ size_t l;
58+
+
59+
+ if (template && ucv_type(template) != UC_STRING)
60+
+ err_return(EINVAL);
61+
+
62+
+ t = ucv_string_get(template);
63+
+ l = ucv_string_length(template);
64+
+
65+
+ ends_with_template = (l >= 6 && strcmp(&t[l - 6], "XXXXXX") == 0);
66+
+
67+
+ if (t && strchr(t, '/')) {
68+
+ if (ends_with_template)
69+
+ xasprintf(&path, "%s", t);
70+
+ else
71+
+ xasprintf(&path, "%s.XXXXXX", t);
72+
+ }
73+
+ else if (t) {
74+
+ if (ends_with_template)
75+
+ xasprintf(&path, "/tmp/%s", t);
76+
+ else
77+
+ xasprintf(&path, "/tmp/%s.XXXXXX", t);
78+
+ }
79+
+ else {
80+
+ xasprintf(&path, "/tmp/XXXXXX");
81+
+ }
82+
+
83+
+ result = mkdtemp(path);
84+
+
85+
+ if (!result) {
86+
+ free(path);
87+
+ err_return(errno);
88+
+ }
89+
+
90+
+ rv = ucv_string_new(result);
91+
+ free(path);
92+
+
93+
+ return rv;
94+
+}
95+
+
96+
+/**
97+
* Checks the accessibility of a file or directory.
98+
*
99+
* The optional modes argument specifies the access modes which should be
100+
@@ -3065,6 +3145,7 @@ static const uc_function_list_t global_f
101+
{ "basename", uc_fs_basename },
102+
{ "lsdir", uc_fs_lsdir },
103+
{ "mkstemp", uc_fs_mkstemp },
104+
+ { "mkdtemp", uc_fs_mkdtemp },
105+
{ "access", uc_fs_access },
106+
{ "readfile", uc_fs_readfile },
107+
{ "writefile", uc_fs_writefile },

scripts/feeds

Lines changed: 25 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -198,30 +198,40 @@ my %update_method = (
198198
# src-git: pull broken
199199
# src-cpy: broken if `basename $src` != $name
200200

201-
sub update_feed_via($$$$$$$) {
201+
sub update_feed_via($$$$$$$$) {
202202
my $type = shift;
203203
my $name = shift;
204204
my $src = shift;
205205
my $relocate = shift;
206206
my $force = shift;
207207
my $rebase = shift;
208208
my $stash = shift;
209+
my $flags = shift;
209210

210211
my $m = $update_method{$type};
211-
my $localpath = "./feeds/$name";
212-
my $safepath = $localpath;
213-
$safepath =~ s/'/'\\''/;
212+
my $safename = $name;
213+
$safename =~ s/'/'\\''/;
214+
my $localpath = "./feeds/$safename";
215+
my $localpath_orig;
216+
if (defined $flags->{'root'}) {
217+
$safename .= "_root";
218+
$localpath_orig = $localpath;
219+
$localpath .= "_root";
220+
}
214221
my ($base_branch, $branch) = split(/;/, $src, 2);
215222
my ($base_commit, $commit) = split(/\^/, $src, 2);
216223

217224
if( $relocate || !$m->{'update'} || !-d "$localpath/$m->{'controldir'}" ) {
218-
system("rm -rf '$safepath'");
225+
if (defined $flags->{'root'}) {
226+
system("rm -rf $localpath_orig; ln -s $safename/$flags->{'root'} $localpath_orig");
227+
}
228+
system("rm -rf '$localpath'");
219229
if ($m->{'init_branch'} and $branch) {
220-
system(sprintf($m->{'init_branch'}, $branch, $base_branch, $safepath)) == 0 or return 1;
230+
system(sprintf($m->{'init_branch'}, $branch, $base_branch, $localpath)) == 0 or return 1;
221231
} elsif ($m->{'init_commit'} and $commit) {
222-
system(sprintf($m->{'init_commit'}, $base_commit, $safepath, $safepath, $commit, $commit)) == 0 or return 1;
232+
system(sprintf($m->{'init_commit'}, $base_commit, $localpath, $localpath, $commit, $commit)) == 0 or return 1;
223233
} else {
224-
system(sprintf($m->{'init'}, $src, $safepath)) == 0 or return 1;
234+
system(sprintf($m->{'init'}, $src, $localpath)) == 0 or return 1;
225235
}
226236
} elsif ($m->{'init_commit'} and $commit) {
227237
# in case git hash has been provided don't update the feed
@@ -236,11 +246,11 @@ sub update_feed_via($$$$$$$) {
236246
if ($stash && exists $m->{'update_stash'}) {
237247
$update_cmd = $m->{'update_stash'};
238248
}
239-
system("cd '$safepath'; $update_cmd") == 0 or return 1;
249+
system("cd '$localpath'; $update_cmd") == 0 or return 1;
240250
}
241251
if ($m->{'post_update'}) {
242252
my $cmd = $m->{'post_update'};
243-
system("cd '$safepath'; $cmd") == 0 or return 1;
253+
system("cd '$localpath'; $cmd") == 0 or return 1;
244254
}
245255

246256
return 0;
@@ -793,14 +803,15 @@ sub uninstall {
793803
return 0;
794804
}
795805

796-
sub update_feed($$$$$$)
806+
sub update_feed($$$$$$$)
797807
{
798808
my $type=shift;
799809
my $name=shift;
800810
my $src=shift;
801811
my $force_update=shift;
802812
my $rebase_update=shift;
803813
my $stash_update=shift;
814+
my $flags=shift;
804815
my $force_relocate=update_location( $name, "@$src" );
805816
my $rv=0;
806817

@@ -815,7 +826,7 @@ sub update_feed($$$$$$)
815826
my $failed = 1;
816827
foreach my $feedsrc (@$src) {
817828
warn "Updating feed '$name' from '$feedsrc' ...\n";
818-
if (update_feed_via($type, $name, $feedsrc, $force_relocate, $force_update, $rebase_update, $stash_update) != 0) {
829+
if (update_feed_via($type, $name, $feedsrc, $force_relocate, $force_update, $rebase_update, $stash_update, $flags) != 0) {
819830
if ($force_update) {
820831
$rv=1;
821832
$failed=0;
@@ -860,10 +871,10 @@ sub update {
860871

861872
my @index_feeds;
862873
foreach my $feed (@feeds) {
863-
my ($type, $name, $src) = @$feed;
874+
my ($type, $name, $src, $flags) = @$feed;
864875
next unless $#ARGV == -1 or $opts{a} or $argv_feeds{$name};
865876
if (not $opts{i}) {
866-
update_feed($type, $name, $src, $opts{f}, $opts{r}, $opts{s}) == 0 or $failed=1;
877+
update_feed($type, $name, $src, $opts{f}, $opts{r}, $opts{s}, $flags) == 0 or $failed=1;
867878
}
868879
push @index_feeds, $name;
869880
}
Lines changed: 142 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,142 @@
1+
From d33941523a8379e30070374b133b28a2077dcef8 Mon Sep 17 00:00:00 2001
2+
From: Christian Marangi <ansuelsmth@gmail.com>
3+
Date: Mon, 13 Oct 2025 20:45:25 +0200
4+
Subject: [PATCH] PCI/sysfs: enforce single creation of sysfs entry for pdev
5+
MIME-Version: 1.0
6+
Content-Type: text/plain; charset=UTF-8
7+
Content-Transfer-Encoding: 8bit
8+
9+
In some specific scenario it's possible that the
10+
pci_create_resource_files() gets called multiple times and the created
11+
entry actually gets wrongly deleted with extreme case of having a NULL
12+
pointer dereference when the PCI is removed.
13+
14+
This mainly happen due to bad timing where the PCI bus is adding PCI
15+
devices and at the same time the sysfs code is adding the entry causing
16+
double execution of the pci_create_resource_files function and kernel
17+
WARNING.
18+
19+
To be more precise there is a race between the late_initcall of
20+
pci-sysfs with pci_sysfs_init and PCI bus.c pci_bus_add_device that also
21+
call pci_create_sysfs_dev_files.
22+
23+
With correct amount of ""luck"" (or better say bad luck)
24+
pci_create_sysfs_dev_files in bus.c might be called with pci_sysfs_init
25+
is executing the loop.
26+
27+
This has been reported multiple times and on multiple system, like imx6
28+
system, ipq806x systems...
29+
30+
To address this, imlement multiple improvement to the implementation:
31+
1. Add a bool to pci_dev to flag when sysfs entry are created
32+
(sysfs_init)
33+
2. Implement a simple completion to wait pci_sysfs_init execution.
34+
3. Permit additional call of pci_create_sysfs_dev_files only after
35+
pci_sysfs_init has finished.
36+
37+
With such logic in place, we address al kind of timing problem with
38+
minimal change to any driver.
39+
40+
A notice worth to mention is that the remove function are not affected
41+
by this as the pci_remove_resource_files have enough check in place to
42+
always work and it's always called by pci_stop_dev.
43+
44+
Cc: stable@vger.kernel.org
45+
Reported-by: Krzysztof Hałasa <khalasa@piap.pl>
46+
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=215515
47+
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
48+
---
49+
drivers/pci/pci-sysfs.c | 34 +++++++++++++++++++++++++++++-----
50+
include/linux/pci.h | 1 +
51+
2 files changed, 30 insertions(+), 5 deletions(-)
52+
53+
--- a/drivers/pci/pci-sysfs.c
54+
+++ b/drivers/pci/pci-sysfs.c
55+
@@ -13,6 +13,7 @@
56+
*/
57+
58+
#include <linux/bitfield.h>
59+
+#include <linux/completion.h>
60+
#include <linux/kernel.h>
61+
#include <linux/sched.h>
62+
#include <linux/pci.h>
63+
@@ -36,6 +37,7 @@
64+
#endif
65+
66+
static int sysfs_initialized; /* = 0 */
67+
+static DECLARE_COMPLETION(sysfs_init_completion);
68+
69+
/* show configuration fields */
70+
#define pci_config_attr(field, format_string) \
71+
@@ -1533,12 +1535,32 @@ static const struct attribute_group pci_
72+
.is_visible = resource_resize_is_visible,
73+
};
74+
75+
+static int __pci_create_sysfs_dev_files(struct pci_dev *pdev)
76+
+{
77+
+ int ret;
78+
+
79+
+ ret = pci_create_resource_files(pdev);
80+
+ if (ret)
81+
+ return ret;
82+
+
83+
+ /* on success set sysfs correctly created */
84+
+ pdev->sysfs_init = true;
85+
+ return 0;
86+
+}
87+
+
88+
int __must_check pci_create_sysfs_dev_files(struct pci_dev *pdev)
89+
{
90+
if (!sysfs_initialized)
91+
return -EACCES;
92+
93+
- return pci_create_resource_files(pdev);
94+
+ /* sysfs entry already created */
95+
+ if (pdev->sysfs_init)
96+
+ return 0;
97+
+
98+
+ /* wait for pci_sysfs_init */
99+
+ wait_for_completion(&sysfs_init_completion);
100+
+
101+
+ return __pci_create_sysfs_dev_files(pdev);
102+
}
103+
104+
/**
105+
@@ -1559,21 +1581,23 @@ static int __init pci_sysfs_init(void)
106+
{
107+
struct pci_dev *pdev = NULL;
108+
struct pci_bus *pbus = NULL;
109+
- int retval;
110+
+ int retval = 0;
111+
112+
sysfs_initialized = 1;
113+
for_each_pci_dev(pdev) {
114+
- retval = pci_create_sysfs_dev_files(pdev);
115+
+ retval = __pci_create_sysfs_dev_files(pdev);
116+
if (retval) {
117+
pci_dev_put(pdev);
118+
- return retval;
119+
+ goto exit;
120+
}
121+
}
122+
123+
while ((pbus = pci_find_next_bus(pbus)))
124+
pci_create_legacy_files(pbus);
125+
126+
- return 0;
127+
+exit:
128+
+ complete_all(&sysfs_init_completion);
129+
+ return retval;
130+
}
131+
late_initcall(pci_sysfs_init);
132+
133+
--- a/include/linux/pci.h
134+
+++ b/include/linux/pci.h
135+
@@ -484,6 +484,7 @@ struct pci_dev {
136+
unsigned int rom_attr_enabled:1; /* Display of ROM attribute enabled? */
137+
pci_dev_flags_t dev_flags;
138+
atomic_t enable_cnt; /* pci_enable_device has been called */
139+
+ bool sysfs_init; /* sysfs entry has been created */
140+
141+
spinlock_t pcie_cap_lock; /* Protects RMW ops in capability accessors */
142+
u32 saved_config_space[16]; /* Config space saved at suspend time */

target/linux/ipq806x/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ CPU_SUBTYPE:=neon-vfpv4
1111
SUBTARGETS:=generic chromium
1212

1313
KERNEL_PATCHVER:=6.6
14+
KERNEL_TESTING_PATCHVER:=6.12
1415

1516
KERNELNAME:=zImage Image dtbs
1617

0 commit comments

Comments
 (0)