Stop overriding CCACHE_COMPILERCHECK from rules.mk and rely on
ccache's default, which hashes the compiler binary's mtime and
size.
For a local tree that is enough: the toolchain only changes when
it is rebuilt, and a rebuild updates mtime and size. Users who
want a stricter check can still set CCACHE_COMPILERCHECK in their
environment.
CI does not depend on this export either. The workflow writes a
secondary ccache.conf with
compiler_check=string:<toolchain-commit-sha>
so the cache key is tied to the toolchain source revision. That
is both stricter than the previous "%compiler% -v -c" setting
and portable across runners, where compiler mtimes would not
match after restoring a cache archive.
Link: https://github.com/openwrt/openwrt/pull/22995
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 3956287514e5457723070f4b8bc7ed8084019d39)
(cherry picked from commit a6149ff867c92daa1aaa050b27ba8c6053d7cfe0)
Update the compiler check for ccache so we don't
end up with the wrong binaries. Right now the
compiler check will not be able to correctly
distinguish the compiler used for build
ARMv8 binaries from the one used to build
ARMv7 binaries.
Signed-off-by: Markus Gothe <markus.gothe@genexis.eu>
Link: https://github.com/openwrt/openwrt/pull/16290
Signed-off-by: John Crispin <john@phrozen.org>
(cherry picked from commit 3859e8eeb82950d8594f60d40e5ee23fd02207c9)
(cherry picked from commit 71d259b59998a214049c9e456f330cd8f292468f)
This fixes a simple logic error in the macaddr existence check in mac80211.uc.
Signed-off-by: Harin Lee <me@harin.net>
Link: https://github.com/openwrt/openwrt/pull/21277
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 2ebcda1ea6b757864c4700e543a9767752ca766e)
Link: https://github.com/openwrt/openwrt/pull/23100
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit b76c38f9e2316e3ad125f6f2e4c7e27d025fad6e)
Drop HIDDEN option from U-Boot default for Airoha while support for ATF
gets pushed.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit cce81ed05bf944bb8188875757f2ab2ddfbfa4a8)
(cherry picked from commit c5de245171de11c694bb7720f5d30ab4467829ca)
Introduce support for U-Boot for Airoha EN7581/AN7583. For EN7581
initial patch are already in U-Boot mainline and doesn't require
backport, for AN7583 some patch are still pending but already posted
upstream.
Also add for now, precompiled binary for ATF BL2 and BL31. Support for
ATF is planned and will come later.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit 04f6769a4a87ed6de4c8a875d35743ca1783e947)
(cherry picked from commit 507bd4c77520af2bf68406654b4b9e146c27b4a6)
The GitHub CI was sometimes still building some tools again even when
the same version was already pre-built. This change fixes the problem
and should improve the speed of the GitHub CI actions. The duration of
the "Build tools" step will be reduced from 5 to 20 minutes down to
10 to 15 seconds.
make also checks that dependencies are not more recent than the target
it wants to build. Previously find returned files in an arbitrary order
and touch set the current timestamp. Since touch is called per file the
timestamps differ in fractional seconds, so not all files got the same
time. make detected a more recent dependency and started to rebuild.
Now all files are set to the same timestamp and make will assume
everything is up to date.
It is sufficient to only touch the stamp files to prevent rebuilding.
Link: https://github.com/openwrt/openwrt/pull/22888
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit cd6cb9f765df46eea7aefaab9d61e143c3996423)
(cherry picked from commit 44df9972d59ea1ec9365bc821af974f1e8686e02)
Swig 4.3.0 has changed SWIG_Python_AppendOutput, which now requires an
additional parameter `is_void`. SWIG_AppendOutput remains unchanged.
This was fixed upstream in u-boot/u-boot@a63456b
```
scripts/dtc/pylibfdt/libfdt_wrap.c: In function '_wrap_fdt_next_node':
scripts/dtc/pylibfdt/libfdt_wrap.c:5581:17: error: too few arguments to function 'SWIG_Python_AppendOutput'
5581 | resultobj = SWIG_Python_AppendOutput(resultobj, val);
| ^~~~~~~~~~~~~~~~~~~~~~~~
```
This is the same fix as applied in 363e07d.
Signed-off-by: Trix Taiclet <git@trix.moe>
Link: https://github.com/openwrt/openwrt/pull/22870
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 9d0bafca525d8309b836e7fa1780f9decb3a0c20)
Swig 4.3.0 has changed SWIG_Python_AppendOutput, which now requires an
additional parameter `is_void`. SWIG_AppendOutput remains unchanged.
This was fixed upstream in u-boot/u-boot@a63456b
```
scripts/dtc/pylibfdt/libfdt_wrap.c: In function '_wrap_fdt_next_node':
scripts/dtc/pylibfdt/libfdt_wrap.c:5581:17: error: too few arguments to function 'SWIG_Python_AppendOutput'
5581 | resultobj = SWIG_Python_AppendOutput(resultobj, val);
| ^~~~~~~~~~~~~~~~~~~~~~~~
```
This is the same fix as applied in 363e07d.
Signed-off-by: Trix Taiclet <git@trix.moe>
Link: https://github.com/openwrt/openwrt/pull/22870
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 1e61a54d7224eaa5c5067ca9d0edd3c8374fe75f)
No need to add another aliases node just for the label-mac-device,
luckily DTC was smart enough to combine them together in the final DTB.
Signed-off-by: Robert Marko <robimarko@gmail.com>
(cherry picked from commit 1f535037b19731cd37512ed00b648a35b40ad13c)
(cherry picked from commit fbca86e8bd815921a37d432f4007564974eb3fc5)
The correct label mac is needed in a downstream project.
Signed-off-by: Steffen Förster <nemesis@chemnitz.freifunk.net>
Link: https://github.com/openwrt/openwrt/pull/22802
Signed-off-by: Robert Marko <robimarko@gmail.com>
(cherry picked from commit beaf298c4cb6f0d678cfdc251060af207ee4bab8)
The Xiaomi Redmi/Mi Router AC2100 does have the correct label mac on the WAN interface.
This MAC is available as gmac1.
Signed-off-by: Florian Maurer <f.maurer@outlook.de>
Link: https://github.com/openwrt/openwrt/pull/22567
(cherry picked from commit b1713d623be30d26da0bd48ecff9032881ce5684)
Link: https://github.com/openwrt/openwrt/pull/22624
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit a64f028d39597448f5949c34b4fdd646deca92d8)
Release previously allocated memory and OF node before return.
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/22276
Signed-off-by: Robert Marko <robimarko@gmail.com>
(cherry picked from commit 4778e35464d4ae38f2dc508be5caf3861e1799b3)
Link: https://github.com/openwrt/openwrt/pull/22348
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 2120db27b569d5242ba9d1baef645d578678dc25)
The bootcount init script is missing the executable bit (644 instead of 755),
causing the script to not be executable:
/etc/preinit: line 44: /etc/init.d/bootcount: Permission denied
Fixes: c3b8108a2be4 ("ramips: Add support for Xiaomi MiWiFi 3A")
Signed-off-by: Oliver Sedlbauer <os@dev.tdt.de>
Link: https://github.com/openwrt/openwrt/pull/22446
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit a15b224e8309fa203dcc23fe95c8cf8dd748255d)
(cherry picked from commit 81be8a8869a36828ded87c8f5de09214d594d433)
The MIPS code assigns the clock node based on the device tree node name.
This name was renamed with kernel 6.12.58 and v6.6.117. Adapt our out of
tree device tree files to this rename to fix loading the STP GPIO
driver.
Without this fix the driver fails like this:
```
[ 0.320000] gpio-stp-xway 1e100bb0.stp: Failed to get clock
[ 0.330000] gpio-stp-xway 1e100bb0.stp: probe with driver gpio-stp-xway failed with error -2
```
Link: https://git.kernel.org/linus/b0d04fe6a633ada2c7bc1b5ddd011cbd85961868
Fixes: https://github.com/openwrt/openwrt/issues/21697
Co-Authored-By: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/22444
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit d405685b44c61b8d0f1ec046d58adfd8b1426893)
[Fix danube.dtsi too]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 3214b8a3289bfa219706447804a2f1daad3521d9)
Cherry pick an upstream patch to fix a memory leak.
Fixed in OpenWrt main branch in commit
2c2cea8864db ("package: update jsonfilter to latest HEAD 2026-03-12")
Link: e086664e6a
Link: https://github.com/openwrt/openwrt/pull/22440
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 77d54cca84ffbb7754d592712ee96b0fcbff0d92)
Update procd cherry-picking fixes from main branch to dedicated
openwrt-24.10 backport branch.
c59f2d8 instance: don't print error in case cgroups are disabled
196291a instance: use positive error numbers for strerror()
d23ddec rcS, ubus: constify char * arguments and variables where appropriate
aeeef20 instance: use mkdir_p helper
d033b7c signal: handle SIGUSR1 as halt
8bc8377 cgroups: fix syntax error
909d02b instance: check length of names when creating cgroups
5ec782f procd: jail/cgroups: fix OOB write in cgroups_apply()
8581313 hotplug-dispatch: fix filter disallowing setting PATH
6265463 service instance: Improve handling of watchdog config changes
45bef92 service instance: Fix overwriting of watchdog linked list members
8294471 coldplug: fix missing header include
fb1c92b hotplug-dispatch: fix missing header include
6dafa86 initd/coldplug: create /dev/null before running udevtrigger
c268f13 hotplug-dispatch: redirect output to /dev/null
b8c4f86 hotplug-dispatch: use stat if d_type is DT_UNKNOWN
1f2aa1a system: fix arguments validation in ubus handler
7e5e049 service: fix use-after-free on service data update
3f48d76 instance: convert jail feature flags to bitmap
2c7c0d2 rcS: avoid duplicate pending "running" calls
5a9b16d service: re-run init script "running" command after instance restart
d5a45ff jail: fix NULL-pointer dereference when connection to ubus failed
8de8cdf jail: always handle mkdir() return value
fa594db jail: seccomp-oci: fix uninitialized pointer read in error path
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
(cherry picked from commit 3e77f8c7abdefa321f2fbc97a27e9d482789a183)
a52cdb354d13 dns: validate IPv4 record addresses
b798c24205b5 dns: validate IPv6 record addresses
a3dcb4adc635 dns: validate reverse dns query name lengths
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
(cherry picked from commit 8a7eb57ab8366045d7e1470c003827391e37684b)
(cherry picked from commit 68befe26ac033d7817014ff014e8eedc4c701360)
75bedc5 wireless-regdb: Update regulatory info for Australia (AU) for 2025
a6e5195 wireless-regdb: Update broken link in regulatory.bin(5) manpage
9e8c67f wireless-regdb: Update regulatory info for Malaysia (MY) for 2024
61a4637 wireless-regdb: Update regulatory info for Malaysia (MY) for 2025
5cefe55 wireless-regdb: Update regulatory info for Tunisia (TN) on 6GHz for 2025
1a729ae wireless-regdb: Update regulatory info for Canada (CA) for 2025
ea20dfa wireless-regdb: update regulatory database based on preceding changes
Link: https://github.com/openwrt/openwrt/pull/22150
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 7c5e329b541066613c09aafd89f7bb6cd8b3bc67)
(cherry picked from commit fb624926e3ed1165a40f07e9a47b6ea5ebacb487)
The MT7531 has an incorrect interrupt number described in the DTS.
This commit also adds PHY interrupts. They work the same as on
the MT7988.
Tested on Gemtek W1700k.
Suggested-by: Benjamin Larsson <benjamin.larsson@genexis.eu>
Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
Link: https://github.com/openwrt/openwrt/pull/21016
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 788958880b66dd3f451d53801c8d25e5e6cfe1b8)
[ fix conflict error, adapt for kernel 6.6 ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit 6f55a705896900d199a338a82d2e5e3238b74681)
Let node unit address same as reg.
Signed-off-by: Ziyang Huang <hzyitc@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/20482
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 077120fb64450f6780f07139faccd67e587560a5)
(cherry picked from commit 2045b37953a8dccd8adb6b0c85d3b2be8d3aff26)
Different boards use different port map. For example, some board may use
a GE port as WAN. So defining the led label in board-level is better.
Signed-off-by: Ziyang Huang <hzyitc@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/20482
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit ea54b6a4786c1f6e687010a46e9f22a4d19e8219)
(cherry picked from commit 0dbc3f8a3c01afb5141f4feb80a0d6edfd04c247)
Different boards use different port map. Defining the port labels in
board-level is better.
Signed-off-by: Ziyang Huang <hzyitc@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/20482
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit e2f7ad08c76593c8cb5abb70088b0813005aa09c)
(cherry picked from commit 90b84588082233019268ab14c6ab60727756159a)
Some board only use some of them, so enable as necessary in
board-level dts.
Signed-off-by: Ziyang Huang <hzyitc@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/20482
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 007aa5a51ce8bd596d35d8e2c7bec2240dbca94d)
(cherry picked from commit ef3c7ee1fbd4deafecdeaaf420bebd51078e9d53)
Cleanup kernel config and drop all unrelated configs. This have the side
effect of fixing the port not going up automatically due to Bridge VLAN
Filtering disabled.
Link: https://github.com/openwrt/openwrt/pull/18112
(cherry picked from commit 7805100e15005ab5a4db59d0cd42612f6fa87c45)
[ fix conflict errors ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit 6dda63a37316d9afb9900fafa80c92a3ee85c3f4)
Enable and configure DMA contiguous memory allocator. Without this
CMA itself will be disabled.
Fixes: ae8bf1a26e ("imx: add imx8m support")
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
(cherry picked from commit eef354ff348ab2c1ec9db753ba192682d61ad313)
Link: https://github.com/openwrt/openwrt/pull/22203
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 01aff6f3c24f0fbef56bd32287090063ea6368aa)
Backport changes to the pinctrl driver to bring it closer to
the upstream version. Also fix the bug in the pinctrl driver:
pinctrl-airoha ...pinctrl: invalid function mdio in map table
Fixes: bd7f5b3 ("airoha: replace AN7583 pinctrl patch with upstream version")
Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Link: https://github.com/openwrt/openwrt/pull/20770
(cherry picked from commit 69f0ee5bafee745540e65f6e43d3fbf1ceb0f6d8)
[ fix conflict errors, adapt to 6.6 ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit 9c04f527c62b38faf25e39e958679d2c717c618d)
Replace Airoha AN7583 pinctrl patch with upstream version as it has been
accepted upstream. Add the related kernel version tag to identify it.
(cherry picked from commit bd7f5b32a6b343a07a2171236671fece947c5d57)
[ fix conflict errors, adapt to 6.6 ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
(cherry picked from commit 530cd87815992c8234964d23bd1417251c47f298)
The shared reset procedure of MT7610 and MT7612 stop all queues before
starting the reset sequence.
They however never restart these like other supported mt76 chips
do in the reconfig_complete call. This leads to TX not continuing
after the reset.
Restart queues in the reconfig_complete callback to restore
functionality after the reset.
Signed-off-by: David Bauer <mail@david-bauer.net>
Link: https://patchwork.kernel.org/project/linux-wireless/patch/20251129023904.288484-1-mail@david-bauer.net/
(cherry picked from commit a89e40993bd2bbd79d5dcc70900f2eed7767e79d)
On MT7620-class platforms (CONFIG_NET_RALINK_MT7620) we observe sporadic
wrong-jump-targets, kernel oopses, hanging, corrupted backtraces or even
"half-written" instructions when the compiler emits a direct 'jal imm26'
call.
This is triggered in:
- the small random helpers inside get_random_u32_below(), and
- the blkcg_maybe_throttle_current() call in resume_user_mode_work().
This patch forces those two call sites to use an indirect call via
a volatile function pointer (load into register + jalr) when building
for MT7620, avoiding embedding a 26-bit immediate jump target.
Additionally, on MT7620 builds the exec path in fs/exec.c is modified:
- skip arch_align_stack() + PAGE_ALIGN() in setup_arg_pages()
because the micro-randomization (< PAGE_SIZE) implemented by many
ports (including MT7620) is negated immediately by PAGE_ALIGN().
Skipping the redundant PAGE_ALIGN() reduces exposure to the
problematic code pattern.
These changes are targeted workarounds for MT7620; behavioral logic is unchanged.
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/20553
(cherry picked from commit 22ccb445e611018ede702e6c0798640353632cce)
Link: https://github.com/openwrt/openwrt/pull/22216
Signed-off-by: Robert Marko <robimarko@gmail.com>
(cherry picked from commit f7005097ae35508ad619251ce7ed127580218e61)
Add some additional Gateworks Venice boards to sysupgrade support.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/22202
Signed-off-by: Robert Marko <robimarko@gmail.com>
(cherry picked from commit a9f4daa3febdcd7975316b2d113efb7a8928980b)
(cherry picked from commit 2bd8d4921f76d83d5d69bb963a0703c9e098a937)
Add support so openwrt can be compiled using
coreutils from GNU or uutils.
Signed-off-by: Marcos Alano <marcoshalano@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/19883
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 67345ead6cf2c406df11f1c341f5c34dfe28bd01)
(cherry picked from commit 1bd47397ae890fc951d77f3010d58ace73839f76)
Switch the mac lookup to NVMEM on UBI layout and add label-mac for 24.10
Signed-off-by: Steffen Förster <nemesis@chemnitz.freifunk.net>
(cherry picked from commit 73819013eebca620944673e333dc47fb36bec95c)
The GPIO line connecting to the reset signals of the GS1900-24E(A1)'s
external ICs (RTL8218B phys and RTL8231 expander) cannot be asserted by
the MDIO subsystem, as the reset is shared between busses.
To prevent users from accidentally asserting the reset line, a GPIO hog
is created to permanently de-assert the signal, reliably keeping the
phys and GPIO expanders on.
Tested-by: Simon Fischer <simi.fischa@gmail.com>
Signed-off-by: Sander Vanheule <sander@svanheule.net>
(cherry picked from commit ba57225066243b28d2802ea5c47313c97767150e)
(cherry picked from commit a98f49b968a55d0a33e841259b76eb38b9396386)