openwrt/staging/wigyori.git
5 months agotools/gnulib: allow forced exclusion of functions after configure
Michael Pratt [Sat, 8 Jun 2024 03:52:56 +0000 (23:52 -0400)]
tools/gnulib: allow forced exclusion of functions after configure

Overriding variables used in both the macros and the headers
like setting REPLACE_FCNTL to 0 while invoking Make causes the
function aliases like rpl_fcntl() to not be defined,
however the object may still be built with the fnctl() function.

Usually this is enough for building while avoiding
the need to link the resulting libgnu library
to every single other build target for a project
in order to include the gnulib copy of the function,
because in these cases we don't care which version
of the function is used.

However for functions like fcntl() this doesn't work
as it is designed to use either the alias or standard declaration
from gnulib headers in order to be
a wrapper for the native host copy of fcntl()
by containing recursive calls to fcntl() within itself
after undefining the gnulib function declaration.

Overriding the variables used by the header when invoking Make
causes the header's declarations to be blocked,
and this results in the gnulib version of fcntl()
to call itself recursively and indefinitely
leading to segmentation faults.

Fix this by using macros defined with those variables
in order to exclude the function during preprocessing.

While at it, do the same for reallocarray()
so that the configure option --avoid=reallocarray
and Make variable REPLACE_REALLOCARRAY set to 0
would have a similar effect.

In the future this patch can be expanded to include
more functions and some version of this may be upstreamable.

Signed-off-by: Michael Pratt <mcpratt@pm.me>
Link: https://github.com/openwrt/openwrt/pull/15690
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 months agobcm27xx: add support for RPI A, A+, 3A+, Zero2 and Zero2W
Dave Brand [Sat, 13 Apr 2024 19:36:07 +0000 (15:36 -0400)]
bcm27xx: add support for RPI A, A+, 3A+, Zero2 and Zero2W

These devices were already supported. I merely added missing entries to:
1. make them easier to locate in firmware selector
2. allow firmware upgrades to proceed without dire warnings

Sample dire warning contains:
    upgrade: Device raspberrypi,model-zero-2-w not supported by this image
    upgrade: Supported devices: rpi-3-b rpi-3-b-plus rpi-zero-2 \
      raspberrypi,2-model-b-rev2 raspberrypi,3-model-b \
      raspberrypi,3-model-b-plus raspberrypi,3-compute-module \
      raspberrypi,compute-module-3 raspberrypi,model-zero-2

With this patch, the firmware upgrade proceeds normally.

Signed-off-by: Dave Brand <dbrand666@users.noreply.github.com>
5 months agobase-files: migrate old UCI network bridge ports syntax
Rafał Miłecki [Sat, 15 May 2021 21:04:35 +0000 (23:04 +0200)]
base-files: migrate old UCI network bridge ports syntax

netifd supports more accurate "ports" option (instead of "ifname") for
years now. Relevant changes were even backported to OpenWrt 21.02. Add
uci-defaults script that translates config files using deprecated
syntax.

Identical commit f716c30241d5 ended up reverted back in 2021 by
80be798d4a4f due to breaking downgrades. With 19.07 support ended it
should no longer be an issue.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
5 months agotools/fakeroot: update to 1.33
Christian Marangi [Tue, 18 Jun 2024 15:02:54 +0000 (17:02 +0200)]
tools/fakeroot: update to 1.33

fakeroot (1.33-1) unstable; urgency=medium

  * New upstream version.
    - Patch from Samuel Thibault to add renameat2 support.
      closes: #1061257.

 -- Clint Adams <clint@debian.org>  Sun, 21 Jan 2024 11:56:06 -0500

fakeroot (1.32.2-1) unstable; urgency=medium

  * New upstream version.
    - Romanian man page translation from Remus-Gabriel Chelu.
      closes: #1055386.
    - patch from Rudi Heitbaum to add missing wrapped.h dependency.
      closes: #1041674.

 -- Clint Adams <clint@debian.org>  Mon, 06 Nov 2023 07:15:47 -0500

fakeroot (1.32.1-1) unstable; urgency=medium

  * New upstream version.
  * Updated German translation from Chris Leick.  closes: #1032206.
  * Patch from John Paul Adrian Glaubitz to add build profile to
    allow bootstrapping.  closes: #1040828.

 -- Clint Adams <clint@debian.org>  Wed, 12 Jul 2023 09:59:17 -0400

fakeroot (1.32-1) unstable; urgency=medium

  * New upstream version.

 -- Clint Adams <clint@debian.org>  Mon, 10 Jul 2023 09:14:43 -0400

fakeroot (1.31-1) unstable; urgency=medium

  * New upstream version.
    - patch from Johannes Schauer Marin Rodrigues to not use
      temporary file in chown test.  closes: #1026132.

 -- Clint Adams <clint@debian.org>  Mon, 06 Feb 2023 10:12:11 -0500

fakeroot (1.30.1-1) unstable; urgency=medium

  * New upstream version.
    - fixes and extends time64 support to fstatat64.
      closes: #1023286.

 -- Clint Adams <clint@debian.org>  Thu, 03 Nov 2022 15:04:55 -0400

fakeroot (1.30-1) unstable; urgency=medium

  * New upstream version.
    - tries to cope with time64 on 32-bit architectures.
      closes: #1023286.
  * Drop kludge for glibc 2.33.

 -- Clint Adams <clint@debian.org>  Wed, 02 Nov 2022 20:17:56 -0400

Link: https://github.com/openwrt/openwrt/pull/15746
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoramips: Fix DOS line endings
Hauke Mehrtens [Mon, 17 Jun 2024 20:57:02 +0000 (22:57 +0200)]
ramips: Fix DOS line endings

Convert line endings from DOS to Unix using dos2unix.

Fixes: 2da2705a441a ("ramips: add support for WINSTARS WS-WN536P3")
Fixes: 5560791bbd6d ("ramips: add support for OpenFi 5Pro Travel Router")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 months agoscripts/download.pl: detach mirror URLs from script file
Christian Marangi [Tue, 18 Jun 2024 14:09:30 +0000 (16:09 +0200)]
scripts/download.pl: detach mirror URLs from script file

Detach URL from download script to make it easier to change and update
the URLs.

The mirror list is moved to a JSON file in the scripts directory called
projectsmirrors.json.

Link: https://github.com/openwrt/openwrt/pull/15745
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotools: tar: update to 1.35
Robert Marko [Tue, 18 Jun 2024 11:32:31 +0000 (13:32 +0200)]
tools: tar: update to 1.35

Instead of backporting select 1.35 fixes to make tar work for us, lets
update to 1.35 now that we have identified the upstream fix for macOS.

Signed-off-by: Robert Marko <robimarko@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15743
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agobcm27xx: remove 6.6 CONFIG_ARCH_BCM_63XX symbol
Álvaro Fernández Rojas [Tue, 18 Jun 2024 19:04:22 +0000 (21:04 +0200)]
bcm27xx: remove 6.6 CONFIG_ARCH_BCM_63XX symbol

This symbol was removed upstream, but it was present on bcm27xx due to a
malformed upstream RPi patch.

Fixes: 8c405cdcccad ("bcm27xx: add 6.6 kernel patches")
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
5 months agobcm27xx: enable 6.6 testing kernel
Álvaro Fernández Rojas [Fri, 10 May 2024 16:49:13 +0000 (18:49 +0200)]
bcm27xx: enable 6.6 testing kernel

The bcm27xx now supports 6.6 kernel as testing.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
5 months agobcm27xx: refresh 6.6 kernel config files
Álvaro Fernández Rojas [Fri, 10 May 2024 11:19:19 +0000 (13:19 +0200)]
bcm27xx: refresh 6.6 kernel config files

Refresh config for kernel 6.6 and add missing symbols.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
5 months agobcm27xx: add 6.6 kernel patches
Álvaro Fernández Rojas [Fri, 10 May 2024 11:19:19 +0000 (13:19 +0200)]
bcm27xx: add 6.6 kernel patches

The patches were generated from the RPi repo with the following command:
git format-patch v6.6.34..rpi-6.1.y

Some patches needed rebasing and, as usual, the applied and reverted, wireless
drivers, Github workflows, READMEs and defconfigs patches were removed.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
5 months agobcm27xx: copy kernel config from 6.1 to 6.6
Álvaro Fernández Rojas [Fri, 10 May 2024 12:50:19 +0000 (14:50 +0200)]
bcm27xx: copy kernel config from 6.1 to 6.6

This is preparation for 6.6 kernel support. Copying files makes it easier to
track their git history.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
5 months agogeneric: replace spi Silicon Labs patch with upstream version
Mieczyslaw Nalewaj [Mon, 17 Jun 2024 23:43:47 +0000 (01:43 +0200)]
generic: replace spi Silicon Labs patch with upstream version

Replace Silicon Labs patch with upstream version as they got merged in
kernel 6.3.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
[ rework commit title and description, use better patch ]
Link: https://github.com/openwrt/openwrt/pull/15300
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoath10k-ct: bump to version 6.7
Christian Marangi [Mon, 17 Jun 2024 17:00:05 +0000 (19:00 +0200)]
ath10k-ct: bump to version 6.7

Bump ath10k-ct to version 6.7.

Drop patch 100 that got merged upstream.

Link: https://github.com/openwrt/openwrt/pull/15735
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agomac80211: backport RX timestamp flags patch
Christian Marangi [Mon, 17 Jun 2024 16:56:53 +0000 (18:56 +0200)]
mac80211: backport RX timestamp flags patch

Backport RX timestamp flags patch needed for ath10k-ct to compile with
newer versions.

Link: https://github.com/openwrt/openwrt/pull/15735
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoath10k-ct: replace LEDs patch with upstream patch
Christian Marangi [Mon, 17 Jun 2024 16:36:58 +0000 (18:36 +0200)]
ath10k-ct: replace LEDs patch with upstream patch

LEDs support for ath10k has finally merged upstream hence replace it
with the upstream version.

Link: https://github.com/openwrt/openwrt/pull/15735
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agomac80211: ath10k: replace LEDs patch with upstream patch
Christian Marangi [Mon, 17 Jun 2024 16:23:44 +0000 (18:23 +0200)]
mac80211: ath10k: replace LEDs patch with upstream patch

LEDs support for ath10k has finally merged upstream hence replace it
with the upstream version.

Link: https://github.com/openwrt/openwrt/pull/15735
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agomvebu: uDPU/eDPU: mount F2FS with ZSTD compression
Robert Marko [Wed, 3 Jan 2024 12:25:04 +0000 (13:25 +0100)]
mvebu: uDPU/eDPU: mount F2FS with ZSTD compression

Now that we can pass the desired compression via cmdline, pass ZSTD as the
desired compression algorithm for F2FS.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
5 months agomvebu: uDPU/eDPU: mount misc partition with ZSTD compression
Robert Marko [Mon, 10 Jul 2023 11:43:51 +0000 (13:43 +0200)]
mvebu: uDPU/eDPU: mount misc partition with ZSTD compression

F2FS requires the compression algorith to be passed as argument while
mounting, so lets do so for the misc partition.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
5 months agomvebu: uDPU/eDPU: format F2FS partitons with compression support
Robert Marko [Mon, 10 Jul 2023 11:40:26 +0000 (13:40 +0200)]
mvebu: uDPU/eDPU: format F2FS partitons with compression support

In order to prolong the eMMC life and utilize ZSTD compression on Methode
devices, we must format the F2FS rootfs and misc partition with xattr and
compression support feature flags first.

This will only happen if partitions are broken currently, but later
commits will add support to convert existing boards to use compression.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
5 months agomvebu: cortexa53: include mkfs.f2fs and fdisk for sysupgrade
Robert Marko [Mon, 10 Jul 2023 11:37:42 +0000 (13:37 +0200)]
mvebu: cortexa53: include mkfs.f2fs and fdisk for sysupgrade

Methode devices require mkfs.f2fs in order to format rootfs and misc
partitions if they have not already been formatted.
fdisk is required if partition table got broke so it can be regenerated.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
5 months agomvebu: cortexa53: enable F2FS ZSTD compression support
Robert Marko [Tue, 27 Jun 2023 08:26:06 +0000 (10:26 +0200)]
mvebu: cortexa53: enable F2FS ZSTD compression support

We would love to utilize ZSTD compression support in F2FS on the
Methode euroDPU so lets enable the required kernel support.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
5 months agoRevert "mac80211: ath10k: replace LEDs patch with upstream patch"
Christian Marangi [Mon, 17 Jun 2024 16:33:19 +0000 (18:33 +0200)]
Revert "mac80211: ath10k: replace LEDs patch with upstream patch"

This reverts commit dc9c5d1ee72564d97b7d76ab4db239e038916d31.

Additional file for ath10k-ct slipped in, revert for a better version
pushed later.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agomac80211: ath10k: replace LEDs patch with upstream patch
Christian Marangi [Mon, 17 Jun 2024 16:23:44 +0000 (18:23 +0200)]
mac80211: ath10k: replace LEDs patch with upstream patch

LEDs support for ath10k has finally merged upstream hence replace it
with the upstream version.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agobuild: include tests/Makefile if available
Paul Spooren [Thu, 6 Jun 2024 17:28:52 +0000 (19:28 +0200)]
build: include tests/Makefile if available

Testing OpenWrt is important, and there is a test suite in the making.
For maximum convenience and minimal CI over-usage, make it simple to run
tests locally. The main Makefile now attempts to include
`tests/Makefile` and silently fails if it doesn't.

While the test suite[1] is still young, it provides good examples of how
to test things around OpenWrt: starting with shell scripts using
`bats`[2], followed by QEMU tests, and finally real device tests using
LabGrid[3]. This could lead to the creation of the best OpenWrt version
yet.

Please consult the `openwrt-tests.git` README.md for details on the
setup. Once installed you may run commands like the following:

* make tests/shell  # run shell tests
* make tests/x86-64 # run  and test x86/64 in QEMU

[1]: http://github.com/aparcar/openwrt-tests/
[2]: https://bats-core.readthedocs.io
[3]: https://labgrid.readthedocs.io

Signed-off-by: Paul Spooren <mail@aparcar.org>
Link: https://github.com/openwrt/openwrt/pull/15647
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agogeneric: 6.6: refresh patches
Daniel Golle [Mon, 17 Jun 2024 14:02:38 +0000 (15:02 +0100)]
generic: 6.6: refresh patches

Refresh patches as line numbers changed with newer upstream version
since original backport PR was opened.

Fixes: a5c095c453 ("generic: 6.6: replace (broken) downstream patch with upstream solution")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
5 months agobpf: also include toolchain standard header as system header
Christian Marangi [Sun, 5 May 2024 15:48:31 +0000 (17:48 +0200)]
bpf: also include toolchain standard header as system header

Also include toolchain standard header as system header. These are
required by xdp-tools that try to include stddef.h and stdbool.h for
some tools. These header are usually in /lib/gcc/../include but musl
also have some special variant in /include.

To fix compilation of xdp-tools, also include these standard header.
These header should follow ISO C standard and should not introduce
regression in bpf tools making them specific to an arch.

Link: https://github.com/openwrt/openwrt/pull/15390
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agobase-files: fix ipcalc bound calculation for /31 prefix
Leon M. Busch-George [Thu, 9 May 2024 09:32:26 +0000 (11:32 +0200)]
base-files: fix ipcalc bound calculation for /31 prefix

A small regress from the translation to shell.
Fixes #12921, originally fixed in #12925 (Github).

Signed-off-by: Leon M. Busch-George <leon@georgemail.eu>
Link: https://github.com/openwrt/openwrt/pull/15430
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agogeneric: 6.6: replace (broken) downstream patch with upstream solution
Daniel Golle [Thu, 30 May 2024 11:33:37 +0000 (12:33 +0100)]
generic: 6.6: replace (broken) downstream patch with upstream solution

Our downstream patch "net/core: add optional threading for backlog processing"
has been broken with the switch to Linux 6.6.
Replace it by backporting the now available upstream solution.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Link: https://github.com/openwrt/openwrt/pull/15592
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoxdp-tools: update to v1.4.2
Konstantin Demin [Thu, 13 Jun 2024 18:00:31 +0000 (21:00 +0300)]
xdp-tools: update to v1.4.2

- release notes:
  https://github.com/xdp-project/xdp-tools/releases/tag/v1.4.2
- patches rebased manually:
  - 010-configure-respect-LDFLAGS.patch

Signed-off-by: Konstantin Demin <rockdrilla@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15705
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoscripts/ext-toolchain: add missing libc library specs
Christian Marangi [Mon, 17 Jun 2024 11:19:52 +0000 (13:19 +0200)]
scripts/ext-toolchain: add missing libc library specs

Add missing libc library spec that weren't added to the ext-toolchain
script when the library were introduced in the packages libs toolchain
Makefile.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agolibquadmath: Add libquadmath to the toolchain
Carlos Miguel Ferreira [Wed, 12 Jun 2024 00:20:59 +0000 (01:20 +0100)]
libquadmath: Add libquadmath to the toolchain

This commit makes the libquadmath library available to the GCC
toolchain. This library is important for libraries such as
Boost.charconv

Signed-off-by: Carlos Miguel Ferreira <carlosmf.pt@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15637
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agouml: drop 6.1 kernel support files
Christian Lamparter [Sun, 2 Jun 2024 13:58:40 +0000 (15:58 +0200)]
uml: drop 6.1 kernel support files

Drop config+patches for kernel 6.1.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15713
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agouml: switch to 6.6 kernel
Christian Lamparter [Sun, 2 Jun 2024 13:56:56 +0000 (15:56 +0200)]
uml: switch to 6.6 kernel

Switch the uml target to kernel 6.6.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15713
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agouml: define "generic" subtarget
Christian Lamparter [Fri, 14 Jun 2024 15:05:47 +0000 (17:05 +0200)]
uml: define "generic" subtarget

UML didn't have a subtarget defined.

While this compiled fine, the patch caused funny filenames
for the generated files to appear:
 - "openwrt-uml--vmlinux"
 - "openwrt-uml--squashfs.img"
 - "openwrt-uml--ext4.img"
 - ...

since "generic" is implied anyway, let's just set it.

Fixes: d997477775bf ("treewide: remove implicit SUBTARGET")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15713
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoapm821xx: drop 6.1 kernel support files
Christian Lamparter [Sun, 2 Jun 2024 14:03:26 +0000 (16:03 +0200)]
apm821xx: drop 6.1 kernel support files

Drop config+patches for kernel 6.1.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15721
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoapm821xx: switch to 6.6 kernel
Christian Lamparter [Sun, 2 Jun 2024 14:01:04 +0000 (16:01 +0200)]
apm821xx: switch to 6.6 kernel

Switch the apm821xx targets to kernel 6.6.
no complains received.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15721
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotreewide: gpio to gpios
Rosen Penev [Mon, 10 Jun 2024 23:49:29 +0000 (16:49 -0700)]
treewide: gpio to gpios

gpio is deprecated. Found with dtc's -Wdeprecated_gpio_property

Used git grep -E $'\tgpio = <' to make the changes.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15681
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoqualcommax: ipq807x: use ath11k_patch_mac for SXK80
Andrew Smith [Tue, 28 May 2024 08:35:28 +0000 (09:35 +0100)]
qualcommax: ipq807x: use ath11k_patch_mac for SXK80

Use ath11k_patch_mac and ath11k_set_macflag functions for SXK80

Signed-off-by: Andrew Smith <gul.code@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/15732
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 months agokernel: armsr: Renesas: RZ: Ethernet module and ttySC0
John Vincent [Fri, 31 May 2024 13:56:24 +0000 (14:56 +0100)]
kernel: armsr: Renesas: RZ: Ethernet module and ttySC0

Ethernet module enable for Renesas RZ platform
inittab fix for ttySC0

Fixes: #15284
Signed-off-by: John Vincent <john.vincent.xa@bp.renesas.com>
5 months agoramips: add support for OpenFi 5Pro Travel Router
Sven Huang [Sat, 1 Jun 2024 03:53:31 +0000 (11:53 +0800)]
ramips: add support for OpenFi 5Pro Travel Router

OpenFi 5Pro is a DualBand Travel Router, based on MT7621A.

Specification:
- Type             : Travel Wi-Fi Router(built-in Type-C Power Cable)
- Size             : 63 x 93 x 24mm
- Power            : Internal Type-C Cable PD/DC 5V@2A
- SoC              : MediaTek MT7621A
- RAM              : DDR3 512 MB
- Flash            : SPI-NOR 64MB (W25Q512)
- WLAN             : 2.4/5GHz 2T2R (MediaTek MT7603e/MT7613)
- Ethernet         : 2x 10/100/1000Mbps
- USB              : 1 x USB 2.0
- SDHCI            : 1 x TF Slot (Max 512GB)
- LEDs             : 3 x LEDs  (GPIO#16 gpio#17 gpio#14)
- Button           : 1 x Reset (GPIO#18),  1 x WPS (GPIO#13)
- UART             : 1 x UART for Debug, 115200 8N1 (Pinout: GND TX RX 3.3V)
- UART 2           : 1xUART2  (Pinout: GND TX2 RX2 3.3V )

How to upgrade image in uboot

1. press reset button when boot for 5sec.
2. access 192.168.21.1 in web ui.
3. select image and upload

Signed-off-by: Sven Huang <1036456939@qq.com>
5 months agoramips: add support for WINSTARS WS-WN536P3
Sven Huang [Wed, 5 Jun 2024 02:39:51 +0000 (02:39 +0000)]
ramips: add support for WINSTARS WS-WN536P3

WS-WN536P3 is a 2.4/5 GHz band 11ac router, based on MT7621DA.

Specification:

- SoC               : MediaTek MT7621DA
- RAM               : DDR3 128 MB
- Flash             : SPI-NOR 16MB
- WLAN              : 2.4/5 GHz 2T2R (MediaTek MT7603e/MT7613)
- Ethernet          : 5x 10/100/1000 Mbps
- LEDs              : 1x Sys 1x WIFI 5x Ethernet LEDs(connect to switch)
- Keys              : 1x Reset 1x WPS 1x Turbo
- USB               : x1
- UART              : 1xUART
- settings        : 115200n8

How to upgrade image in uboot

1. press reset button when boot for 5sec.
2. access 192.168.10.1 in web ui.
3. select image and upload

Signed-off-by: Sven Huang <1036456939@qq.com>
5 months agokernel: generic: refresh patches
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 20:24:44 +0000 (22:24 +0200)]
kernel: generic: refresh patches

Refresh patches by 'make target/linux/refresh'

Fixes: 487cc3831ce8 ("generic: 6.6: drop patch adding support for multiple MTK PPE")
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agotools/sparse: fix compilation with GCC14
Rosen Penev [Fri, 14 Jun 2024 23:01:34 +0000 (16:01 -0700)]
tools/sparse: fix compilation with GCC14

Upstream backport.

Get rid of PKG_RELEASE as it's irrelevant to tools.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 months agoath79: diable some 6 MiB image size TP-Link devices
Shiji Yang [Sat, 15 Jun 2024 02:22:30 +0000 (02:22 +0000)]
ath79: diable some 6 MiB image size TP-Link devices

The max image sizes are too small to generate images.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
5 months agoath79: drop factory image for DIR-825 and TEW-673GRU
Shiji Yang [Sat, 15 Jun 2024 02:18:22 +0000 (02:18 +0000)]
ath79: drop factory image for DIR-825 and TEW-673GRU

The max image sizes are too small to generate factory images.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
5 months agorockchip: Add cache information to the SoC dtsi for RK356x
Milinda Brantini [Tue, 11 Jun 2024 03:27:42 +0000 (11:27 +0800)]
rockchip: Add cache information to the SoC dtsi for RK356x

Fix cacheinfo: Unable to detect cache hierarchy for CPU 0.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
5 months agoramips: tplink_8m: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 07:24:26 +0000 (09:24 +0200)]
ramips: tplink_8m: cleaning up nvmem-cells definitions

Move nvmem-cells definitions to dts files for compatibility with other files
in which mt7628an_tplink_8m.dtsi is loaded, to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agoramips: netgear_r6xxx: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 07:19:26 +0000 (09:19 +0200)]
ramips: netgear_r6xxx: cleaning up nvmem-cells definitions

Move nvmem-cells definitions to dts files to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agoramips: elecom_wrc-gs-1pci: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 07:16:35 +0000 (09:16 +0200)]
ramips: elecom_wrc-gs-1pci: cleaning up nvmem-cells definitions

Move nvmem-cells definitions to dts files to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agoramips: cudy_x6: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 07:11:25 +0000 (09:11 +0200)]
ramips: cudy_x6: cleaning up nvmem-cells definitions

Move nvmem-cells definitions to dts files to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agoramips: xiaomi,mi-ra75: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 06:59:41 +0000 (08:59 +0200)]
ramips: xiaomi,mi-ra75: cleaning up nvmem-cells definitions

Remove nvmem-cells definitions due to duplication
in mt7628an_xiaomi_mi-router-4.dtsi

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agoramips: tplink,archer-c2-v1: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 06:53:21 +0000 (08:53 +0200)]
ramips: tplink,archer-c2-v1: cleaning up nvmem-cells definitions

Remove nvmem-cells definitions due to duplication
in mt7620a_tplink_8m.dtsi

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agoramips: hiwifi,hc5861: cleaning up nvmem-cells definitions
Mieczyslaw Nalewaj [Sun, 16 Jun 2024 06:45:58 +0000 (08:45 +0200)]
ramips: hiwifi,hc5861: cleaning up nvmem-cells definitions

Remove nvmem-cells definitions due to duplication
in mt7620a_hiwifi_hc5x61.dtsi

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
5 months agogeneric: 6.6: drop patch adding support for multiple MTK PPE
Daniel Golle [Sun, 16 Jun 2024 17:40:07 +0000 (18:40 +0100)]
generic: 6.6: drop patch adding support for multiple MTK PPE

Partially revert commit 98ddfbc56a ("generic: 6.6: backport upstream
commits for mtk_eth_soc") as the commit breaks WED. A better solution to
assign PPE units in case of WED has still to be found.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
5 months agogeneric: 6.6: update NVMEM-on-MMC series
Daniel Golle [Fri, 14 Jun 2024 16:35:10 +0000 (17:35 +0100)]
generic: 6.6: update NVMEM-on-MMC series

Allow a wider audience to test this pending series.

Use about to be submitted v3 which factors out block notification support.
Apart from dropping the no longer needed (and problematic) fallback for
for the 'partitions' node being present at the device parent there are
no intended functional changes.

As opening a block device as file is not supported yet in Kernel v6.6,
use the previous method as backporting seems a bit too involving.

Fixes: #15642
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
5 months agogeneric: 6.6: move NVMEM-on-UBI patches from pending to backports
Daniel Golle [Fri, 14 Jun 2024 15:24:12 +0000 (16:24 +0100)]
generic: 6.6: move NVMEM-on-UBI patches from pending to backports

The series was merged for Linux v6.9, so move it to backports.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
5 months agogeneric: 6.6: backport upstream commits for mtk_eth_soc
Daniel Golle [Sun, 16 Jun 2024 12:20:37 +0000 (13:20 +0100)]
generic: 6.6: backport upstream commits for mtk_eth_soc

Backport two commits for mtk_eth_soc:
 * net: ethernet: mtk_eth_soc: handle dma buffer size soc specific
   (torvalds/linux@c57e558194430d10d5e5f4acd8a8655b68dade13)
 * net: ethernet: mtk_eth_soc: ppe: add support for multiple PPEs
   (torvalds/linux@dee4dd10c79aaca192b73520d8fb64628468ae0f)

Refresh pending patches which require that.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
5 months agompc85xx: fix label-mac-address for Enterasys WS-AP3710i
David Bauer [Sat, 15 Jun 2024 23:33:19 +0000 (01:33 +0200)]
mpc85xx: fix label-mac-address for Enterasys WS-AP3710i

The WS-AP3710i does not correctly expose its label-mac on eth0 anymore
since the change to simpleLoader.

Fix this by obtaining the label-mac from the U-Boot environment.

Signed-off-by: David Bauer <mail@david-bauer.net>
5 months agoramips: fix MAC address for some devices
Shiji Yang [Sat, 15 Jun 2024 01:20:50 +0000 (01:20 +0000)]
ramips: fix MAC address for some devices

1. Remove unused macaddr NVMEM cells.
2. Fix "mac-base" compatible cells references.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
5 months agokernel: bump 6.6 to 6.6.33 and adjust subarches
John Audia [Wed, 12 Jun 2024 20:46:19 +0000 (16:46 -0400)]
kernel: bump 6.6 to 6.6.33 and adjust subarches

This commit accomplishes three goals:
1. bump 6.6 to 6.6.33
2. kernel: modules: video: change package definition for fb for
   upstream changes[1]
3. kernel/multiple subtargets: add CONFIG_FB_IOMEM_FOPS=y to all
   subtargets which also set CONFIG_FB_CORE=y.

Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.33

Removed upstreamed:
pending-6.6/195-block-fix-and-simplify-blkdevparts-cmdline-parsing.patch[2]
gemini/patches-6.6/0003-net-ethernet-cortina-Locking-fixes.patch[3]

Manually rebased:
ramips/patches-6.6/810-uvc-add-iPassion-iP2970-support.patch

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-6.6.y&id=c00e8fd749502c02085534c60b1edca4fc479c91
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.33&id=99bbbd9aea059f8a206736dc601be2ae61d366fb
3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.33&id=8f6f82d6a205ceb3aba8d279f9ff6eeea0b1689b

Build system: x86/64
Build-tested: x86/64/AMD Cezanne, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3
Run-tested: x86/64/AMD Cezanne, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3

Tested-by: Stijn Segers <foss@volatilesystems.org>
Signed-off-by: John Audia <therealgraysky@proton.me>
5 months agokernel: bump 6.1 to 6.1.93
Zxl hhyccc [Sat, 15 Jun 2024 06:39:10 +0000 (14:39 +0800)]
kernel: bump 6.1 to 6.1.93

Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.93

Removed upstreamed:
bcm27xx/patches-6.1/950-0081-smsx95xx-fix-crimes-against-truesize.patch
reference: https://github.com/gregkh/linux/commit/517e64bcc9634bb46f8fc6421e272b8da3d7d953

Manually rebased:
bcm27xx/patches-6.1/950-0712-drm-vc4-Use-phys-addresses-for-slave-DMA-config.patch

All other patches automatically rebased.

Build system: bcm53xx ath79

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
5 months agofirmware: intel-microcode: update to 20240531
Christian Lamparter [Sun, 2 Jun 2024 13:54:14 +0000 (15:54 +0200)]
firmware: intel-microcode: update to 20240531

Debian changelog:

intel-microcode (3.20240531.1) unstable; urgency=medium

  * New upstream microcode datafile 20240531
    * Fix unspecified functional issues on Pentium Silver N/J5xxx,
      Celeron N/J4xxx
    * Updated Microcodes:
      sig 0x000706a1, pf_mask 0x01, 2024-04-19, rev 0x0042, size 76800
  * source: update symlinks to reflect id of the latest release, 20240531

 -- Henrique de Moraes Holschuh <hmh@debian.org>  Sat, 01 Jun 2024 11:49:47 -0300

intel-microcode (3.20240514.1) unstable; urgency=medium

  * New upstream microcode datafile 20240514
    * Mitigations for INTEL-SA-01051 (CVE-2023-45733)
      Hardware logic contains race conditions in some Intel Processors may
      allow an authenticated user to potentially enable partial information
      disclosure via local access.
    * Mitigations for INTEL-SA-01052 (CVE-2023-46103)
      Sequence of processor instructions leads to unexpected behavior in
      Intel Core Ultra Processors may allow an authenticated user to
      potentially enable denial of service via local access.
    * Mitigations for INTEL-SA-01036 (CVE-2023-45745,  CVE-2023-47855)
      Improper input validation in some Intel TDX module software before
      version 1.5.05.46.698 may allow a privileged user to potentially enable
      escalation of privilege via local access.
    * Fix for unspecified functional issues on 4th gen and 5th gen Xeon
      Scalable, 12th, 13th and 14th gen Intel Core processors, as well as for
      Core i3 N-series processors.
    * Updated microcodes:
      sig 0x000806f8, pf_mask 0x87, 2024-02-05, rev 0x2b0005c0, size 581632
      sig 0x000806f7, pf_mask 0x87, 2024-02-05, rev 0x2b0005c0
      sig 0x000806f6, pf_mask 0x87, 2024-02-05, rev 0x2b0005c0
      sig 0x000806f5, pf_mask 0x87, 2024-02-05, rev 0x2b0005c0
      sig 0x000806f4, pf_mask 0x87, 2024-02-05, rev 0x2b0005c0
      sig 0x000806f8, pf_mask 0x10, 2024-02-05, rev 0x2c000390, size 614400
      sig 0x000806f6, pf_mask 0x10, 2024-02-05, rev 0x2c000390
      sig 0x000806f5, pf_mask 0x10, 2024-02-05, rev 0x2c000390
      sig 0x000806f4, pf_mask 0x10, 2024-02-05, rev 0x2c000390
      sig 0x00090672, pf_mask 0x07, 2023-12-05, rev 0x0035, size 224256
      sig 0x00090675, pf_mask 0x07, 2023-12-05, rev 0x0035
      sig 0x000b06f2, pf_mask 0x07, 2023-12-05, rev 0x0035
      sig 0x000b06f5, pf_mask 0x07, 2023-12-05, rev 0x0035
      sig 0x000906a3, pf_mask 0x80, 2023-12-05, rev 0x0433, size 222208
      sig 0x000906a4, pf_mask 0x80, 2023-12-05, rev 0x0433
      sig 0x000906a4, pf_mask 0x40, 2023-12-07, rev 0x0007, size 119808
      sig 0x000b0671, pf_mask 0x32, 2024-01-25, rev 0x0123, size 215040
      sig 0x000b06e0, pf_mask 0x11, 2023-12-07, rev 0x0017, size 138240
      sig 0x000c06f2, pf_mask 0x87, 2024-02-05, rev 0x21000230, size 552960
      sig 0x000c06f1, pf_mask 0x87, 2024-02-05, rev 0x21000230
  * source: update symlinks to reflect id of the latest release, 20240514

 -- Henrique de Moraes Holschuh <hmh@debian.org>  Thu, 16 May 2024 21:40:52 -0300

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
5 months agompc85xx: fix Enterasys WS-AP3710i eth mac-address
David Bauer [Fri, 14 Jun 2024 20:50:26 +0000 (22:50 +0200)]
mpc85xx: fix Enterasys WS-AP3710i eth mac-address

With the introduction of the simpleImage loader, the MAC address is not
set by the bootloader anymore.

Fix this by reading the MAC address from the U-Boot environment
partition.

Signed-off-by: David Bauer <mail@david-bauer.net>
5 months agoath79: fix MAC address for senao loader devices
Shiji Yang [Fri, 14 Jun 2024 12:28:52 +0000 (12:28 +0000)]
ath79: fix MAC address for senao loader devices

The "mac-base" nvmem-cell-cells size is 1.

Fixes: b2f1c6ed52af ("ath79: qca: remove mac-address-increment")
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
5 months agoath79: switch default kernel to 6.6
Shiji Yang [Tue, 11 Jun 2024 08:28:39 +0000 (08:28 +0000)]
ath79: switch default kernel to 6.6

We haven't received any bug reports in the past few weeks. So it's
time to set kernel 6.6 as the default and remove kernel 6.1 support.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
5 months agoath79: refresh 6.6 kernel config
Shiji Yang [Mon, 10 Jun 2024 03:06:33 +0000 (03:06 +0000)]
ath79: refresh 6.6 kernel config

Add the missing kernel symbols by
`make kernel_oldconfig CONFIG_TARGET={target,subtarget}`.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
5 months agotools/pkgconf: update to 2.2.0
Nick Hainke [Tue, 11 Jun 2024 06:16:44 +0000 (08:16 +0200)]
tools/pkgconf: update to 2.2.0

Changelog:
https://github.com/pkgconf/pkgconf/blob/06120a8769aed87d50e914f87a6f9f67110cf16e/NEWS

Signed-off-by: Nick Hainke <vincent@systemli.org>
5 months agobcm47xx: Remove profiles for broadcom-wl
Hauke Mehrtens [Sun, 9 Jun 2024 15:00:45 +0000 (17:00 +0200)]
bcm47xx: Remove profiles for broadcom-wl

The broadcom-wl driver was removed from OpenWrt, remove also the
profiles using it.

Fixes: e772b75d5d50 ("broadcom-wl: remove package")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 months agobcm47xx: Remove exports for braodcom-wl driver
Hauke Mehrtens [Sun, 9 Jun 2024 14:59:10 +0000 (16:59 +0200)]
bcm47xx: Remove exports for braodcom-wl driver

The braodcom-wl driver was removed from OpenWrt, remove the special
exports it needed.

Fixes: e772b75d5d50 ("broadcom-wl: remove package")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 months agoramips: fix wrong dts file permission
Mikhail Zhilkin [Thu, 13 Jun 2024 15:36:25 +0000 (15:36 +0000)]
ramips: fix wrong dts file permission

This file is executable:
   target/linux/ramips/dts/mt7621_dlink_dir-2150-a1.dts
Has to be fixed.

Fixes: 30e8fd73ec54 ("ramips: Add support for D-Link DIR-2150-A1")
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
5 months agoramips: fix random LAN MAC for sercomm dxx devices
Mikhail Zhilkin [Thu, 13 Jun 2024 15:34:31 +0000 (15:34 +0000)]
ramips: fix random LAN MAC for sercomm dxx devices

This commit fixes random lan mac for sercomm dxx devices.

Fixes: 339518482578 ("ramips: mt7621: nix mac-address-increment")
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
5 months agoramips: fix wrong eeprom data for sercomm dxx devices
Mikhail Zhilkin [Thu, 13 Jun 2024 15:33:20 +0000 (15:33 +0000)]
ramips: fix wrong eeprom data for sercomm dxx devices

This commit fixes wrong WiFi eeprom data:
   /sys/kernel/debug/ieee80211/phy0/mt76/eeprom
   /sys/kernel/debug/ieee80211/phy1/mt76/eeprom

Fixes: fb4cea45ec55 ("ramips: convert MT7603 EEPROM to NVMEM format")
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
5 months agokernel: ltq-adsl: fix compilation warning on 6.6
Aleksander Jan Bajkowski [Thu, 13 Jun 2024 21:15:39 +0000 (23:15 +0200)]
kernel: ltq-adsl: fix compilation warning on 6.6

Fix compilation warning:
./include/linux/export.h:29:22: error: passing argument 1 of 'class_create' from incompatible pointer type [-Werror=incompatible-pointer-types]
   29 | #define THIS_MODULE (&__this_module)
      |                     ~^~~~~~~~~~~~~~~
      |                      |
      |                      struct module *
/home/aleksander/workspace/openwrt/build_dir/target-mips_24kc_musl/linux-lantiq_xway/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:1105:29: note: in expansion of macro 'THIS_MODULE'
 1105 |    dsl_class = class_create(THIS_MODULE, "dsl_cpe_api");
      |                             ^~~~~~~~~~~
In file included from ./include/linux/device.h:31,
                 from ./include/linux/platform_device.h:13,
                 from ./include/linux/of_device.h:5,
                 from ./include/linux/of_platform.h:10,
                 from /home/aleksander/workspace/openwrt/build_dir/target-mips_24kc_musl/linux-lantiq_xway/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:15:
./include/linux/device/class.h:230:54: note: expected 'const char *' but argument is of type 'struct module *'
  230 | struct class * __must_check class_create(const char *name);
      |                                          ~~~~~~~~~~~~^~~~
/home/aleksander/workspace/openwrt/build_dir/target-mips_24kc_musl/linux-lantiq_xway/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:1105:16: error: too many arguments to function 'class_>
 1105 |    dsl_class = class_create(THIS_MODULE, "dsl_cpe_api");
      |                ^~~~~~~~~~~~
./include/linux/device/class.h:230:29: note: declared here
  230 | struct class * __must_check class_create(const char *name);
      |                             ^~~~~~~~~~~~
cc1: all warnings being treated as errors

Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
5 months agokernel: ltq-adsl-mei: fix compilation warning on 6.6
Aleksander Jan Bajkowski [Thu, 13 Jun 2024 21:00:40 +0000 (23:00 +0200)]
kernel: ltq-adsl-mei: fix compilation warning on 6.6

Fix compilation warning:
./include/linux/export.h:29:22: error: passing argument 1 of 'class_create' from incompatible pointer type [-Werror=incompatible-pointer-types]
   29 | #define THIS_MODULE (&__this_module)
      |                     ~^~~~~~~~~~~~~~~
      |                      |
      |                      struct module *
/home/aleksander/workspace/openwrt/build_dir/target-mips_24kc_musl/linux-lantiq_xway/ltq-adsl-mei-ar9/ltq-adsl-mei/drv_mei_cpe.c:2774:34: note: in expansion of macro 'THIS_MODULE'
 2774 |         dsl_class = class_create(THIS_MODULE, "ifx_mei");
      |                                  ^~~~~~~~~~~
In file included from ./include/linux/device.h:31,
                 from ./include/linux/dma-mapping.h:8,
                 from ./include/linux/skbuff.h:28,
                 from ./include/net/net_namespace.h:43,
                 from ./include/linux/netdevice.h:38,
                 from /home/aleksander/workspace/openwrt/build_dir/target-mips_24kc_musl/linux-lantiq_xway/ltq-adsl-mei-ar9/ltq-adsl-mei/drv_mei_cpe.c:39:
./include/linux/device/class.h:230:54: note: expected 'const char *' but argument is of type 'struct module *'
  230 | struct class * __must_check class_create(const char *name);
      |                                          ~~~~~~~~~~~~^~~~
/home/aleksander/workspace/openwrt/build_dir/target-mips_24kc_musl/linux-lantiq_xway/ltq-adsl-mei-ar9/ltq-adsl-mei/drv_mei_cpe.c:2774:21: error: too many arguments to function 'class_create'
 2774 |         dsl_class = class_create(THIS_MODULE, "ifx_mei");
      |                     ^~~~~~~~~~~~
./include/linux/device/class.h:230:29: note: declared here
  230 | struct class * __must_check class_create(const char *name);
      |                             ^~~~~~~~~~~~
cc1: all warnings being treated as errors

Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
5 months agoath79: fix wrong mac address for ecb1xx0
Rosen Penev [Thu, 13 Jun 2024 23:49:02 +0000 (16:49 -0700)]
ath79: fix wrong mac address for ecb1xx0

0db4f9785ca30f79fa1abbffb0fab5a6053f68f5 changed the variable name from
athaddr to ethaddr. Restore.

Fixes: 0db4f9785ca3 ("ath79: convert ath10k calibration data to NVMEM (ASCII MAC)")
Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 months agomac80211: remove mtd-cal-data
Rosen Penev [Sun, 9 Jun 2024 23:04:58 +0000 (16:04 -0700)]
mac80211: remove mtd-cal-data

All usages of mtd-cal-data have been removed. To avoid submissions that
rely on this deprecated behavior, remove it.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15671
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 months agoqualcommax: ipq807x: fix sysupgrade for ZBT-Z800AX
Chukun Pan [Mon, 10 Jun 2024 15:18:19 +0000 (23:18 +0800)]
qualcommax: ipq807x: fix sysupgrade for ZBT-Z800AX

This router has two rootfs partitions and dualboot is used.
Vendor firmware may swap the rootfs partition location, u-boot append
'ubi.mtd=rootfs' in the end of cmdline. Since we use fixed-partitions,
force boot from the first rootfs partition to avoid boot failure.

Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Link: https://github.com/openwrt/openwrt/pull/15700
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 months agokernel: 6.6: prevent garbage-cleanup of BPF kfuncs
Tony Ambardar [Mon, 10 Jun 2024 09:17:40 +0000 (02:17 -0700)]
kernel: 6.6: prevent garbage-cleanup of BPF kfuncs

Backport an upstream Linux fix to prevent BPF kfunc functions from being
removed during linker optimization when building BTF-enabled vmlinux.

The telltale sign of this occurring is build log warnings (e.g. mips64el):

      BTFIDS  vmlinux
    WARN: resolve_btfids: unresolved symbol bpf_verify_pkcs7_signature
    WARN: resolve_btfids: unresolved symbol bpf_lookup_user_key
    WARN: resolve_btfids: unresolved symbol bpf_lookup_system_key
    WARN: resolve_btfids: unresolved symbol bpf_key_put
    WARN: resolve_btfids: unresolved symbol bpf_iter_task_next
    WARN: resolve_btfids: unresolved symbol bpf_iter_css_task_new
    WARN: resolve_btfids: unresolved symbol bpf_get_file_xattr
    WARN: resolve_btfids: unresolved symbol bpf_ct_insert_entry
      NM      System.map
      SORTTAB vmlinux

Link: https://lore.kernel.org/bpf/ZlkoM6%2FPSxVcGM6X@kodidev-ubuntu/
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15697
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotools/dwarves: update to v1.27
Tony Ambardar [Wed, 28 Feb 2024 23:04:57 +0000 (15:04 -0800)]
tools/dwarves: update to v1.27

Update to the latest upstream version and add a patch that enables pahole
reproducible builds if SOURCE_DATE_EPOCH is defined in the environment.

This patch helps avoid BTF-related module loading problems with packages
built separately from the kernel such as mac80211 or kselftests-bpf, e.g.:

    [   16.858856] BPF:      type_id=1185 bits_offset=0
    [   16.859099] BPF:
    [   16.859199] BPF: Invalid name
    [   16.859352] BPF:
    [   16.859612] failed to validate module [cfg80211] BTF: -22
    [   17.015178] PPP generic driver version 2.4.2
    [   17.052703] NET: Registered PF_PPPOX protocol family
    [   17.348722] BPF:      type_id=1185 bits_offset=0
    [   17.348912] BPF:
    [   17.348996] BPF: Invalid name
    [   17.349106] BPF:
    [   17.349220] failed to validate module [cfg80211] BTF: -22
    [   17.472070] kmodloader: 3 modules could not be probed
    [   17.473133] kmodloader: - cfg80211 - 0
    [   17.473762] kmodloader: dependency not loaded cfg80211
    [   17.474421] kmodloader: - mac80211 - 1
    [   17.474988] kmodloader: dependency not loaded mac80211
    [   17.475632] kmodloader: dependency not loaded cfg80211
    [   17.476263] kmodloader: - mac80211_hwsim - 2

    root@OpenWrt:/usr/libexec/kselftests-bpf# insmod bpf_testmod.ko
    [ 4735.776792] missing module BTF, cannot register kfuncs
    [ 4735.777371] missing module BTF, cannot register kfuncs
    [ 4735.777955] missing module BTF, cannot register kfuncs
    [ 4735.778452] missing module BTF, cannot register kfuncs

Release Notes: https://lore.kernel.org/bpf/ZmjBHWw-Q5hKBiwA@x1/

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15697
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotools/elfutils: add missing MIPS reloc support
Tony Ambardar [Mon, 10 Jun 2024 06:59:12 +0000 (23:59 -0700)]
tools/elfutils: add missing MIPS reloc support

Backport an upstream patch series that adds backend elfutils support for
DWARF relocations in MIPS debug info. This support is needed by pahole to
generate BTF for modules in BTF-enabled kernel builds.

The problem first manifests as pahole warnings during build:

    BTF [M] lib/libcrc32c.ko
    die__process_unit: DW_TAG_compile_unit (0x11) @ <0x932d> not handled!
    die__process_unit: tag not supported 0x11 (compile_unit)!
    die__process: got compile_unit unexpected tag after DW_TAG_compile_unit!
    die__process_unit: DW_TAG_compile_unit (0x11) @ <0x99a3> not handled!
    die__process_unit: tag not supported 0x11 (compile_unit)!
    die__process: got compile_unit unexpected tag after DW_TAG_compile_unit!

During system boot the problem then causes module loading failures, which
may result in many other runtime issues:

    [   13.169785] kmodloader: loading kernel modules from /etc/modules.d/*
    [ ... ]
    [   17.422840] mac80211_hwsim: initializing netlink
    [   17.526518] PPP generic driver version 2.4.2
    [   17.550346] NET: Registered PF_PPPOX protocol family
    [   17.795353] kmodloader: 26 modules could not be probed
    [   17.796084] kmodloader: dependency not loaded nf_conntrack
    [   17.796737] kmodloader: - act_connmark - 1
    [   17.797402] kmodloader: dependency not loaded nf_conntrack
    [   17.798056] kmodloader: - act_ctinfo - 1
    [ ... ]

Link: https://lore.kernel.org/bpf/ZlkoM6%2FPSxVcGM6X@kodidev-ubuntu/
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15697
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotoolchain/musl: add support for renameat2()
Tony Ambardar [Wed, 12 Jun 2024 05:30:48 +0000 (22:30 -0700)]
toolchain/musl: add support for renameat2()

Backport an upstream patch to support the renameat2 syscall, added in Linux
3.15 and supported by glibc since 2.28. It is commonly used in filesystem
or security contexts, and needed building upstream kernel bpf selftests.

Link:
https://inbox.vuxu.org/musl/20240421153640.379015-1-Tony.Ambardar@gmail.com/

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15697
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoqualcommax: ipq807x: wax620 and wax630: fix wifi mac address
Kristian Skramstad [Fri, 31 May 2024 04:15:10 +0000 (06:15 +0200)]
qualcommax: ipq807x: wax620 and wax630: fix wifi mac address

The wifi radios on wax620 and wax630 got a random mac
address on boot. So fix this by using ath11k_patch_mac
and give a static mac address from label-mac-device.

Tested and working on wax620 and wax630.

Signed-off-by: Kristian Skramstad <kristian+github@83.no>
Link: https://github.com/openwrt/openwrt/pull/15597
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 months agoocteontx: drop target
Robert Marko [Tue, 11 Jun 2024 12:31:43 +0000 (14:31 +0200)]
octeontx: drop target

octeontx is currently stuck on kernel 5.15 since using 6.1 breaks booting,
and unfortunately nobody has stepped up to fix this issue.

Gateworks who were primary users have supported the removal.

Link: https://github.com/openwrt/openwrt/pull/15686
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 months agotoplevel.mk: make sure tmp exist for .packagedynamicdefault
Christian Marangi [Wed, 12 Jun 2024 13:55:17 +0000 (15:55 +0200)]
toplevel.mk: make sure tmp exist for .packagedynamicdefault

With some big corner case, tmp directory might not exist when
check-dynamic-def-pkg is called. To handle this, make sure tmp exist
before creating the .packagedynamicdefault file.

Fixes: 9a52ec4fa092 ("toplevel.mk: implement logic to invalidate targetinfo with some config")
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotools: tar: backport patch for paxlib shipped in tar
Christian Marangi [Wed, 12 Jun 2024 13:11:48 +0000 (15:11 +0200)]
tools: tar: backport patch for paxlib shipped in tar

Tar 1.34 ship an old version of paxlib with rtapelib.c that produce some
compilation warning. This library got updated in 1.35 but we still can't
use the new Tar version.

GCC 14 then made these compilarion warning errors.

Manually backport the fixes to rtapelib.c and patch the version shipped
in 1.34 to fix these compilation warning.

Fixes: #15692
Fixes: 2951e0a80e9f ("tools: tar: backport patches fixing broken --delete")
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoipq40xx: fix invalid GPIO numbers since kernel 6.6
Koen Vandeputte [Wed, 12 Jun 2024 12:15:45 +0000 (14:15 +0200)]
ipq40xx: fix invalid GPIO numbers since kernel 6.6

The bump to kernel 6.6 increased the GPIO base from
412 to 512 on this target.

We need to compensate for that in the GPIO numbers being passed
to uci to fix following kernel report:

[   24.176183] export_store: invalid GPIO 423

Tested on a Wallys DR40x9 board.

Please note that:

Boards "rtl30vw" and "wpj428" are not being altered here.
They define GPIO numbers which are even below the previous
base of 412 which looks wrong.
Actual testing on these boards should be conducted to validate
and optionally fix GPIO numbering.

Suggested-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Koen Vandeputte <koen.vandeputte@citymesh.com>
5 months agobase-files: Reapply fixed "Ignore exit code of uci.sh inclusion"
Paul Spooren [Mon, 10 Jun 2024 14:59:41 +0000 (16:59 +0200)]
base-files: Reapply fixed "Ignore exit code of uci.sh inclusion"

This reverts commit 80d1c353b79e6c216dcb2534420470e3e6ed5d60 with the
fix which won't break running systems. A logic error on how shell
handles && and || more the init process.

Signed-off-by: Paul Spooren <mail@aparcar.org>
5 months agoapk: host: make the help available
Petr Štetiar [Mon, 10 Jun 2024 09:43:23 +0000 (09:43 +0000)]
apk: host: make the help available

Currently, the apk utility lacks accessible help documentation, making
it cumbersome for human users:

 apk-tools 3.0.0_pre20240519, compiled for x86_64.

 ERROR: This apk-tools has been built without help

This absence of help forces users to delve into the apk's build
directory to understand its functionality. To enhance usability, we will
enable the help feature for the host build. The host environment can
accommodate the 3% increase in binary size for the added convenience.

On Ubuntu 22.04, x86_64 platform, the apk size increases by 17,816 bytes
(from 594,144 to 611,960 bytes), a 2.99% increase. This is a reasonable
trade-off for improved ergonomics.

Additionally fix the Lua host build dependency as apk-tools uses during
the build Lua to convert SCDOC manpages to apk-tools help messages.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoconfig: imply apk-mbedtls with USE_APK
Christian Marangi [Thu, 6 Jun 2024 17:16:55 +0000 (19:16 +0200)]
config: imply apk-mbedtls with USE_APK

On top of the fixup to select apk-mbedtls when USE_APK is enabled from a
new config, also imply the package when enabling the config to catch
.config that are already init.

(Having both opkg and apk installed in a system is not a problem but if
USE_APK is used, APK presence in the system is mandatory)

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoapk: limit CONFIG_IPK_FILES_CHECKSUMS config to OPKG
Christian Marangi [Sun, 26 May 2024 17:54:29 +0000 (19:54 +0200)]
apk: limit CONFIG_IPK_FILES_CHECKSUMS config to OPKG

Limit CONFIG_IPK_FILES_CHECKSUMS config to OPKG as APK have different
way to validate package integrity (apk audit)

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agobase-files: skip fix-group-user uci-default for APK installation
Christian Marangi [Sun, 26 May 2024 17:30:32 +0000 (19:30 +0200)]
base-files: skip fix-group-user uci-default for APK installation

For APK installation we don't have /usr/lib/opkg/info and user fixup are
handled dirrectly. Skip the script in such case.

Also remove this uci-defaults if we have CONFIG_USE_APK enabled.

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agodropbear: don't install /usr/lib/opkg/info in package install
Christian Marangi [Sun, 26 May 2024 17:28:46 +0000 (19:28 +0200)]
dropbear: don't install /usr/lib/opkg/info in package install

Don't install /usr/lib/opkg/info in package install as it doesn't make
sense and conflicts with APK installations.

Fixes: a377aa9ab534 ("add dropkey ssh keys and config files to the conffiles section (#2014)")
Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoapk: provide csum for static conffiles
Christian Marangi [Sat, 25 May 2024 14:00:27 +0000 (16:00 +0200)]
apk: provide csum for static conffiles

For non-overlay configuration we need checksum for config file that
weren't modified by the user. For OPKG in sysupgrade we check the status
file for the Conffiles: entry of every package. this entry contains
checksum for every static file that the package contains.

Provide the same info for APK by creating a conffiles_static file and
parse this file on sysupgrade for non-overlay configurations.

This is also used by the sysupgrade -u option to exclude non-changed
files from the final backup.

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotoplevel.mk: implement logic to invalidate targetinfo with some config
Christian Marangi [Fri, 24 May 2024 18:13:49 +0000 (20:13 +0200)]
toplevel.mk: implement logic to invalidate targetinfo with some config

Implement some logic to invalidate targetinfo files in tmp with the
changing of some config.

Some config might affect DEFAULT_PACKAGES list but DEFAULT_PACKAGES is
only evaluated once. This cause the interesting scenario where someone
install feeds packages, targetinfo is evaluated in tmp and then add some
config like CONFIG_USE_APK. Using make defconfig will still select OPKG
as default package as DEFAULT_PACKAGES in targetinfo has been already
evaluated in the feeds install and is never updated.

To handle this add some logic in toplevel.mk to cache the current state
of these special config and wipe targetinfo when these change.

This cause the targetinfo to be reevaluated and handle this REALLY
corner case.

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotarget.mk: add support to early scan of default package configuration
Christian Marangi [Fri, 24 May 2024 10:49:15 +0000 (12:49 +0200)]
target.mk: add support to early scan of default package configuration

There is currently a problem with how some option that modify default
package configuration are parsed.

When the DEFAULT_PACKAGES list is composed, DUMP is used. Using DUMP
disable the loading of .config to remove and modification done by the
user to prevent any kind of conflict or strange thing one creating all
the info for each target. Because of this, .config is never parsed and
any check to CONFIG doesn't work (for the first creation of .config).

Later image build will check what is set in .config and the default
package list won't be parsed anymore.

This is problematic for some config that are OK to parse, for example
SELINUX or USE_APK.

To better handle them add some logic when DUMP is used to selectively
parse these option if present in a to-be-init .config so that option are
correctly parsed and DEFAULT_PACKAGES is correctly set.

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotarget: install apk-mbedtls by default
Paul Spooren [Thu, 23 May 2024 22:08:56 +0000 (00:08 +0200)]
target: install apk-mbedtls by default

since the split of APK in mbedtls and openssl version, installing `apk`
as default package doesn't do the trick anymore. Instead specify
`apk-mbedtls` directly.

Signed-off-by: Paul Spooren <mail@aparcar.org>
Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agotools: tar: backport patches fixing broken --delete
Christian Marangi [Thu, 23 May 2024 17:02:41 +0000 (19:02 +0200)]
tools: tar: backport patches fixing broken --delete

In experimenting with --delete for APK handling, it was discovered that
--delete is broken and corrupts the TAR in some case.

This is fixed in version 1.35 but 1.35 introduce some problem with MacOS
making it difficult to bump. Backport the 2 required patches to fix this
problem so --delete is usable again.

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agobuild: package: fix missing host apk dependency
Petr Štetiar [Thu, 23 May 2024 10:24:11 +0000 (10:24 +0000)]
build: package: fix missing host apk dependency

Currently the build with USE_APK=y fails in package/libs/toolchain:

 staging_dir/host/bin/fakeroot: line 182: staging_dir/host/bin/apk: No such file or directory
 make[2]: *** [Makefile:758: bin/targets/mediatek/filogic/packages/libgcc1-13.2.0-r4.apk] Error 127

as commit d788ab376f ("build: add APK package build capabilities") added
dependency on apk in packaging step, but there is no host build
dependency defined, thus apk binary is missing when libgcc1 apk package is being
created. So lets fix it by adding explicit apk/host dependency to all
targets in the subdirectories.

Fixes: d788ab376f ("build: add APK package build capabilities")
Signed-off-by: Petr Štetiar <ynezz@true.cz>
[ rework logic to be more self contained ]
Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
5 months agoinclude/package-pack: add special handling for CONTROL conffiles
Christian Marangi [Wed, 22 May 2024 17:35:35 +0000 (19:35 +0200)]
include/package-pack: add special handling for CONTROL conffiles

Add special handling for CONTROL conffiles. Some packages (base-files)
manually append stuff to the CONTROL directory.

The CONTROL directory is something for OPKG that is added in the root of
the ipkg directory and usually contains postinst, list, and conffiles
file. For APK the implementation is different, to keep compatibility
with this and maybe other packages, apply manual fixup and check for
these corner case.

Also check if the CONTROL directory is present and is empty to make sure
we don't drop other special file while removing any pending CONTROL
directory in the ipkg directory.

Link: https://github.com/openwrt/openwrt/pull/15543
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>