openwrt/staging/stintel.git
7 months agoqca-nss-dp: add patch fixing rmmod and insmod
Christian Marangi [Tue, 16 Apr 2024 14:44:41 +0000 (16:44 +0200)]
qca-nss-dp: add patch fixing rmmod and insmod

Add patch fixing rmmod and insmod. Lots of flawed logic fixed that
permits the module to correctly rmmod and insmod later.

Just to quote some change, use phy_detach instead of phy_disconnect, fix
exclusive reset_control that could only be used once, fix kernel panic
on second edma_cleanup, stop traffic before module exit...

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
7 months agoqoriq: add kernel 6.1 support
Stijn Tintel [Wed, 17 Apr 2024 21:29:00 +0000 (00:29 +0300)]
qoriq: add kernel 6.1 support

Add support for kernel 6.1 as testing kernel for qoriq. Refresh config
using `make kernel_oldconfig`.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
7 months agokernel/qoriq: Restore kernel files for v5.15
Stijn Tintel [Wed, 17 Apr 2024 21:23:36 +0000 (00:23 +0300)]
kernel/qoriq: Restore kernel files for v5.15

This is an automatically generated commit which aids following Kernel patch history,
as git will see the move and copy as a rename thus defeating the purpose.

See: https://lists.openwrt.org/pipermail/openwrt-devel/2023-October/041673.html
for the original discussion.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
7 months agokernel/qoriq: Create kernel files for v6.1 (from v5.15)
Stijn Tintel [Wed, 17 Apr 2024 21:23:36 +0000 (00:23 +0300)]
kernel/qoriq: Create kernel files for v6.1 (from v5.15)

This is an automatically generated commit.

When doing `git bisect`, consider `git bisect --skip`.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
7 months agoqoriq: refresh kernel 5.15 config
Stijn Tintel [Wed, 17 Apr 2024 21:23:10 +0000 (00:23 +0300)]
qoriq: refresh kernel 5.15 config

Done with `make kernel_oldconfig`.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
7 months agoipq807x: add support for Zbtlink ZBT-Z800AX
Chukun Pan [Tue, 26 Mar 2024 15:16:05 +0000 (23:16 +0800)]
ipq807x: add support for Zbtlink ZBT-Z800AX

Hardware specifications:
  SoC: Qualcomm IPQ8072A
  RAM: 1GB of DDR4 600MHz
  Flash1: Winbond W25Q64DW 8MB
  Flash2: MX30UF2G28AD 256MB
  WiFi1: QCN5024 2.4GHz AX 4x4
  WiFi2: QCN5054 5GHz AX 4x4
  Ethernet: 5x 1G RJ45 port
  USB: 2x USB 3.0 (1x M.2)
  Button: Reset, WPS

Flash instructions:
  Upload factory.bin in stock firmware's
  upgrade page, do not preserve settings.

Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
7 months agoipq-wifi: update to version 2024-04-16
Chukun Pan [Tue, 16 Apr 2024 15:10:02 +0000 (23:10 +0800)]
ipq-wifi: update to version 2024-04-16

Contains following updates:

 * ipq8074: add Spectrum SAX1V1K BDF
 * ipq8074: add Zbtlink ZBT-Z800AX BDF
 * ipq8074: update regdb in Spectrum SAX1V1K BDF
 * ipq6018: add Linksys MR7350 BDF

Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
7 months agotools: zstd: update patch with upstream version
Christian Marangi [Wed, 17 Apr 2024 09:28:58 +0000 (11:28 +0200)]
tools: zstd: update patch with upstream version

Proposed fixup has been replaced and merged with an advanced version.

install-pc-mt has been dropped and replaced for intall-pc MT=1 to
generate a .pc file with multithread libs.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
7 months agoqmi: add sourcefilter option support
Chen Minqiang [Mon, 22 Jan 2024 15:00:03 +0000 (23:00 +0800)]
qmi: add sourcefilter option support

This make source based IPv6 routing option available for qmi

Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
7 months agombim: add sourcefilter option support
Chen Minqiang [Mon, 22 Jan 2024 14:59:44 +0000 (22:59 +0800)]
mbim: add sourcefilter option support

This make source based IPv6 routing option available for mbim

Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
7 months agoncm: add sourcefilter option support
Chen Minqiang [Mon, 22 Jan 2024 14:59:18 +0000 (22:59 +0800)]
ncm: add sourcefilter option support

This make source based IPv6 routing option available for ncm

Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
7 months agoipset: update to 7.21
Chuanhong Guo [Wed, 17 Apr 2024 04:09:07 +0000 (12:09 +0800)]
ipset: update to 7.21

release notes:
7.21: https://www.spinics.net/lists/netfilter-devel/msg85299.html
7.20: https://www.spinics.net/lists/netfilter-devel/msg85120.html
7.19: https://www.spinics.net/lists/netfilter-devel/msg82985.html

Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
7 months agoipset: include libgen.h for basename
Chuanhong Guo [Wed, 17 Apr 2024 04:12:25 +0000 (12:12 +0800)]
ipset: include libgen.h for basename

musl dropped the GNU version of basename prototype from string.h
in 1.2.5.

Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
7 months agosunxi: fix network bringup on Olinuxino Micro boards
Zoltan HERPAI [Tue, 16 Apr 2024 22:42:56 +0000 (00:42 +0200)]
sunxi: fix network bringup on Olinuxino Micro boards

It's the A13-based Olinuxino Micro which has only wireless interfaces. The
A20-based board is a fully-fledged one which has an ethernet interface.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
7 months agokernel: bump 5.15 to 5.15.155
Hauke Mehrtens [Sat, 13 Apr 2024 17:22:41 +0000 (19:22 +0200)]
kernel: bump 5.15 to 5.15.155

Manual adapted the following patches:
   generic/hack-5.15/221-module_exports.patch
   octeontx/patches-5.15/0004-PCI-add-quirk-for-Gateworks-PLX-PEX860x-switch-with-.patch

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agotools: mold: update to 2.30.0
Robert Marko [Mon, 15 Apr 2024 08:59:46 +0000 (10:59 +0200)]
tools: mold: update to 2.30.0

Release Notes:
https://github.com/rui314/mold/releases/tag/v2.3.3
https://github.com/rui314/mold/releases/tag/v2.4.0
https://github.com/rui314/mold/releases/tag/v2.4.1
https://github.com/rui314/mold/releases/tag/v2.30.0

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agoipq40xx: whw03v2: enable additional 5 GHz channels
Rodrigo Balerdi [Wed, 3 Apr 2024 03:30:46 +0000 (00:30 -0300)]
ipq40xx: whw03v2: enable additional 5 GHz channels

This device supports channel ranges 36-64 and 100-165, just like
others based on the same reference design, but its current DTS is
unnecessarily restricting these ranges to 36-48 and 149-165.

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
7 months agosunxi: update a13-olimex-som DTS path
Zoltan HERPAI [Tue, 16 Apr 2024 16:56:59 +0000 (16:56 +0000)]
sunxi: update a13-olimex-som DTS path

In preparation for supporting kernel 6.6, where the DTS files are grouped into
vendors - similarly to what arm64 has been doing all along -, update the
SUNXI_DTS var of this board to prepend it with SUNXI_DTS_DIR.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
7 months agopistachio: remove 5.15 support
Zoltan HERPAI [Tue, 16 Apr 2024 10:21:42 +0000 (12:21 +0200)]
pistachio: remove 5.15 support

Now that 6.1 is default, remove 5.15 support.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
7 months agopistachio: default to kernel 6.1
Zoltan HERPAI [Tue, 16 Apr 2024 10:20:59 +0000 (12:20 +0200)]
pistachio: default to kernel 6.1

6.1 has been present as testing for some time now, so switch the
default to it.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
7 months agokernel: Add missing config option
Hauke Mehrtens [Mon, 15 Apr 2024 20:50:34 +0000 (22:50 +0200)]
kernel: Add missing config option

Kernel 6.1.83 allows to select CONFIG_GPIO_VF610, deactivate it by
default.

This fixes compilation of the armsr/armv8 target.

Fixes: 2ad898e091cb ("kernel: bump 6.1 to 6.1.83")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agoRevert "elfutils: fix a missing typedef in the last update"
Felix Fietkau [Mon, 15 Apr 2024 20:05:06 +0000 (22:05 +0200)]
Revert "elfutils: fix a missing typedef in the last update"

This reverts commit a9e22ffa5028e303dc32d15f1ce5e1be4c20e125.
After doing a clean rebuild, it turns out that this change is not necessary

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agotools: libdeflate: backport fix for AVX-VNNI
Robert Marko [Mon, 15 Apr 2024 09:03:08 +0000 (11:03 +0200)]
tools: libdeflate: backport fix for AVX-VNNI

Trying to compile with new new enough GCC but older binutils that dont
support AVX-VNNI will error out on the assembler, so backport an upstream
fix for it.

Fixes: 338b463e1e97 ("tools: libdeflate: update to 1.20")
Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agonetifd: add missing error checks to packet steering script
Felix Fietkau [Mon, 15 Apr 2024 10:32:35 +0000 (12:32 +0200)]
netifd: add missing error checks to packet steering script

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agoelfutils: fix a missing typedef in the last update
Felix Fietkau [Mon, 15 Apr 2024 10:55:37 +0000 (12:55 +0200)]
elfutils: fix a missing typedef in the last update

Fixes perf

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agotools/dwarves: add myself as PKG_MAINTAINER
Tony Ambardar [Tue, 5 Mar 2024 08:28:48 +0000 (00:28 -0800)]
tools/dwarves: add myself as PKG_MAINTAINER

Missed setting this when first adding package.

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
7 months agobridger: update to Git HEAD (2024-04-15)
Felix Fietkau [Mon, 15 Apr 2024 09:19:44 +0000 (11:19 +0200)]
bridger: update to Git HEAD (2024-04-15)

3159bbe0a2eb improve isolation when selecting a fixed output port
c77a7a1ff74d nl: fix getting flow offload stats
a08e51e679dd add support for disabling bridge-local flows via config

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agoramips: Add support for D-Link DIR-3040 A1
Vince McKinsey [Sun, 31 Mar 2024 18:29:05 +0000 (14:29 -0400)]
ramips: Add support for D-Link DIR-3040 A1

This adds support for the A1 hardware revision of the DIR-3040.
It is an exact copy of the DIR-3060 save for some cosmetic changes to the housing.
Even going so far as having the same FCC ID.

Hardware specification:
SoC: MediaTek MT7621AT
Flash: Winbond W29N01HVSINA 128MB
RAM: Micron MT41K128M16JT-125 256MB
Ethernet: 5x 10/100/1000 Mbps
WiFi1: MT7615DN 2.4GHz N 2x2:2
WiFi2: MT7615DN 5GHz AC 2x2:2
WiFi3: MT7615N 5GHz AC 4x4:4
Button: WPS, Reset

Flash instructions:
OpenWrt can be installed via D-Link Recovery GUI:
NOTE: Seems to only work in Firefox on Windows.
Tried with Chrome on Windows, Firefox in Linux, and Chromium in Linux.
None of these other browsers worked.

    1. Push and hold reset button (on the bottom of the device) until power led
starts flashing (about 10 secs or so) while plugging in the power cable.
    2. Give it ~30 seconds, to boot the recovery mode GUI
    3. Connect your client computer to LAN1 of the device
    4. Set your client IP address manually to 192.168.0.2 / 255.255.255.0.
    5. Call the recovery page for the device at http://192.168.0.1/
    6. Use the provided emergency web GUI to upload and flash a new firmware to the device

Thanks to @Lucky1openwrt and @iivailo for creating the DIR-3060 DTS file and related changes,
so it was possible for me to adapt them to the DIR-3040, build images,
test and fix minor issues.

MAC Addresses:

| use | address | example |
| --- | --- | --- |
| LAN | label | f4:*:61 |
| WAN | label + 4 | f4:*:65 |
| WI1/2g | label + 2 | f4:*:63 |
| WI1/5g | label + 1 | f4:*:62 |
| WI2/5g | label + 3 | f4:*:64 |

The label MAC address was found in Factory, 0xe000

Checklist:

✓ nand
✓ ethernet
✓ button
✓ wifi2g
✓ wifi5g
✓ wifi5g
✓ mac
✓ led

Signed-off-by: Vince McKinsey <vincemckinsey@gmail.com>
7 months agotools: libdeflate: update to 1.20
Robert Marko [Sat, 13 Apr 2024 18:15:45 +0000 (20:15 +0200)]
tools: libdeflate: update to 1.20

Changes:
* Improved CRC-32 performance on recent x86 CPUs by adding
VPCLMULQDQ-accelerated implementations using 256-bit and 512-bit vectors.

* Improved Adler-32 performance on recent x86 CPUs by adding
VNNI-accelerated implementations using 256-bit and 512-bit vectors.

* Improved CRC-32 and Adler-32 performance on short inputs.

* Optimized the portable implementation of Adler-32.

* Added some basic optimizations for RISC-V.

* Dropped support for gcc versions older than v4.9 (released in 2014) and
clang versions older than v3.9 (released in 2016).

* Dropped support for CRC-32 acceleration on 32-bit ARM using the ARMv8 pmull or crc32 instructions.
This code only worked on CPUs that also have a 64-bit mode, and it was
already disabled on many compiler versions due to compiler limitations.
CRC-32 acceleration remains fully supported on 64-bit ARM.

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agomvebu: fix LEDs on IIJ SA-W2
INAGAKI Hiroshi [Sun, 18 Feb 2024 06:01:51 +0000 (15:01 +0900)]
mvebu: fix LEDs on IIJ SA-W2

On IIJ SA-W2, some multiple LEDs have no "function" property and only
"color" property is available for the newer binding of LED on Linux
Kernel.
9d93b6d091 ("mvebu: drop redundant label with new LED color/function
format") removes "label" property from LEDs, then, multiple "<color>:"
(ex.: "green:"/"red:") will be appeared and renamed to "<color>:_<num>"
(ex.: "green:_1", "green:_2", ...) by kernel.

log:

[    1.911118] leds-gpio leds: Led green: renamed to green:_1 due to name collision
[    1.918600] leds-gpio leds: Led red: renamed to red:_1 due to name collision
[    1.925727] leds-gpio leds: Led green: renamed to green:_2 due to name collision
[    1.933202] leds-gpio leds: Led red: renamed to red:_2 due to name collision
[    1.940321] leds-gpio leds: Led green: renamed to green:_3 due to name collision
[    1.947797] leds-gpio leds: Led red: renamed to red:_3 due to name collision
[    1.954939] leds-gpio leds: Led green: renamed to green:_4 due to name collision
[    1.962456] leds-gpio leds: Led green: renamed to green:_5 due to name collision

/sys/class/leds:

root@OpenWrt:/# ls /sys/class/leds/
green:        green:_3      green:status  red:_2
green:_1      green:_4      red:          red:_3
green:_2      green:_5      red:_1        red:status

Fix this issue by adding missing "function" (and "function-enumerator")
property to those LEDs on IIJ SA-W2.

Fixes: 9d93b6d091 ("mvebu: drop redundant label with new LED color/function format")
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
7 months agomvebu: fix LEDs on Fortinet FortiGate devices
INAGAKI Hiroshi [Sat, 17 Feb 2024 10:27:42 +0000 (19:27 +0900)]
mvebu: fix LEDs on Fortinet FortiGate devices

On Fortinet FortiGate 30E/50E, some multiple LEDs have no "function"
property and only "color" property is available for the new binding of
LED on Linux Kernel.
9d93b6d091 ("mvebu: drop redundant label with new LED color/function
format") removes "label" property from LEDs, then, multiple "<color>:"
(ex.: "green:"/"red:"/"amber:") will be appeared as LED names and
renamed to "<color>:_<num>" (ex.: "green:_1", "green:_2", ...) by
kernel.

log:

[   12.425170] leds-gpio gpio-leds: Led green: renamed to green:_1 due to name collision
[   12.520390] leds-gpio gpio-leds: Led amber: renamed to amber:_1 due to name collision
[   12.614931] leds-gpio gpio-leds: Led green: renamed to green:_2 due to name collision
[   12.709895] leds-gpio gpio-leds: Led green: renamed to green:_3 due to name collision
[   12.804439] leds-gpio gpio-leds: Led amber: renamed to amber:_2 due to name collision
[   12.898969] leds-gpio gpio-leds: Led green: renamed to green:_4 due to name collision
[   12.993504] leds-gpio gpio-leds: Led amber: renamed to amber:_3 due to name collision
[   13.088033] leds-gpio gpio-leds: Led green: renamed to green:_5 due to name collision
[   13.182570] leds-gpio gpio-leds: Led green: renamed to green:_6 due to name collision
[   13.277103] leds-gpio gpio-leds: Led amber: renamed to amber:_4 due to name collision
[   13.371636] leds-gpio gpio-leds: Led green: renamed to green:_7 due to name collision

/sys/class/leds:

root@OpenWrt:/# ls /sys/class/leds/
amber:        amber:_4      green:_2      green:_6      red:alarm
amber:_1      amber:alarm   green:_3      green:_7      red:status
amber:_2      green:        green:_4      green:status
amber:_3      green:_1      green:_5      red:

Fix this issue by adding missing "function" (and "function-enumerator")
property those to LEDs on Fortinet FortiGate devices.
Note: there is no appropriate function for "ha" LEDs in
dt-bindings/leds/common.h, so use the hardcoded string for them instead.

Fixes: 9d93b6d091 ("mvebu: drop redundant label with new LED color/function format")
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
7 months agokernel: add pending patches for new LED_FUNCTION_* definitions
INAGAKI Hiroshi [Wed, 20 Mar 2024 11:14:36 +0000 (20:14 +0900)]
kernel: add pending patches for new LED_FUNCTION_* definitions

Add pending patches to add LED_FUNCTION_MOBILE and LED_FUNCTION_SPEED_*
definitions for Fortinet FortiGate devices and IIJ SA-W2.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
7 months agoath79: add support for Comfast CF-EW71 v2
Felix Golatofski [Tue, 9 Jan 2024 23:44:35 +0000 (00:44 +0100)]
ath79: add support for Comfast CF-EW71 v2

Specifications:
Qualcomm/Atheros QCA9531
2x 10/100 Mbps Ethernet, with 48v PoE
2T2R 2.4 GHz, 802.11b/g/n
128MB RAM
16MB SPI Flash
4x LED (Always On Power, LAN, WAN, WLAN)

Flashing instructions:
The original firmware is based on OpenWrt, so flashing the sysupgrade image over the factory firmware is sufficient.
The bootloader has a built-in recovery web-ui. This is the method I used to flash OpenWrt. You can get to the recovery web-ui by holding down the reset button for a few seconds (~5s) while pluggin in the router. The LEDs should start blinking fast and the router should be available on 192.168.1.1 for the recovery.

Tested: Reset button, WAN LED, LAN LED, Power LED (always on, not much to test), WLAN LED, MAC addresses (same as factory firmware).

Signed-off-by: Felix Golatofski <git@xdfr.de>
7 months agouboot-rockchip: Update to 2024.04
Tianling Shen [Wed, 10 Apr 2024 06:39:43 +0000 (14:39 +0800)]
uboot-rockchip: Update to 2024.04

Removed upstreamed patch.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
7 months agorkbin: bump to latest git HEAD
Tianling Shen [Wed, 10 Apr 2024 06:35:38 +0000 (14:35 +0800)]
rkbin: bump to latest git HEAD

Fixed bugs for memory initialization/training,
improved memory compatibility/stability.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
7 months agokernel: bump 6.1 to 6.1.86
Hauke Mehrtens [Sat, 13 Apr 2024 15:48:42 +0000 (17:48 +0200)]
kernel: bump 6.1 to 6.1.86

Removed upstreamed:
   bcm27xx/patches-6.1/950-1235-drm-vc4-don-t-check-if-plane-state-fb-state-fb.patch  [1]

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.86&id=48bfb4b03c5ff6e1fa1dc73fb915e150b0968c40

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agokernel: bump 6.1 to 6.1.84
Hauke Mehrtens [Sat, 13 Apr 2024 11:49:12 +0000 (13:49 +0200)]
kernel: bump 6.1 to 6.1.84

Removed upstreamed:
   pistachio/patches-6.1/110-pwm-img-fix-clock-lookup.patch [1]

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.84&id=44b6fb6cdedb2c391a2da355521d4610b2645fcc

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agokernel: bump 6.1 to 6.1.83
Hauke Mehrtens [Fri, 29 Mar 2024 22:15:26 +0000 (23:15 +0100)]
kernel: bump 6.1 to 6.1.83

Removed upstreamed:
   generic/backport-6.1/789-STABLE-01-net-dsa-mt7530-prevent-possible-incorrect-XTAL-frequ.patch [1]
   generic/backport-6.1/789-STABLE-02-net-dsa-mt7530-fix-link-local-frames-that-ingress-vl.patch [2]
   generic/backport-6.1/789-STABLE-03-net-dsa-mt7530-fix-handling-of-all-link-local-frames.patch [3]
   generic/pending-6.1/735-net-mediatek-mtk_eth_soc-release-MAC_MCR_FORCE_LINK-.patch [4]
   generic/pending-6.1/736-net-ethernet-mtk_eth_soc-fix-PPE-hanging-issue.patch [5]

Manual adjusted the following patches:
  mediatek/patches-6.1/100-dts-update-mt7622-rfb1.patch

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.83&id=be4512b9ac6fc53e1ca8daccbda84f643215c547
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.83&id=f1fa919ea59655f73cb3972264e157b8831ba546
3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.83&id=86c0c154a759f2af9612a04bdf29110f02dce956
4. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.83&id=6b62bad2da1b338f452a9380639fc9b093d75a25
5. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.83&id=f78807362828ad01db2a9ed005bf79501b620f27

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agokernel: Reorder generic kernel 6.1 config
Hauke Mehrtens [Sat, 13 Apr 2024 16:25:16 +0000 (18:25 +0200)]
kernel: Reorder generic kernel 6.1 config

This reordering was done using these commands:
./scripts/kconfig.pl '+' target/linux/generic/config-6.1 /dev/null > target/linux/generic/config-6.1-new
mv target/linux/generic/config-6.1-new target/linux/generic/config-6.1

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agokernel: bump 6.6 to 6.6.27
John Audia [Sat, 13 Apr 2024 12:19:04 +0000 (08:19 -0400)]
kernel: bump 6.6 to 6.6.27

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

Removed upstreamed:
pending-6.6/981-gcc-plugins-stackleak-Avoid-.head.txt.section.patch[1]

All patches automatically rebased.

1. https://github.com/gregkh/linux/commit/9dff96b8b3a404d3b3581af46450f2efeb7d290a

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

Signed-off-by: John Audia <therealgraysky@proton.me>
7 months agox86: generic: config-6.6: refresh
John Audia [Wed, 10 Apr 2024 20:24:49 +0000 (16:24 -0400)]
x86: generic: config-6.6: refresh

Ran `make kernel_menuconfig`

Reference to CONFIG_SPECTRE_BHI_ON=y[1]

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/diff/arch/x86/Kconfig?id=v6.6.26&id2=v6.6.25

Signed-off-by: John Audia <therealgraysky@proton.me>
7 months agokernel: bump 6.6 to 6.6.26
John Audia [Wed, 10 Apr 2024 19:16:18 +0000 (15:16 -0400)]
kernel: bump 6.6 to 6.6.26

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

Manually rebased:
generic/hack-6.6/210-darwin_scripts_include.patch

Added pending:
generic/pending-6.6/981-gcc-plugins-stackleak-Avoid-.head.txt.section.patch

All other patches automatically rebased.

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

Signed-off-by: John Audia <therealgraysky@proton.me>
7 months agotoolchain/musl: Update to 1.2.5
Hannu Nyman [Fri, 1 Mar 2024 20:51:25 +0000 (22:51 +0200)]
toolchain/musl: Update to 1.2.5

Update musl C library to 1.2.5

This release adds extension functions statx and preadv2/pwritev2,
with fallback implementations for older kernels, and adds two new
ports: loongarch64 and riscv32. Minor changes to the printf family
of functions have been made for conformance to new standards
interpretations/requirements. TLSDESC support for riscv64 has also
been added.

Bugs fixed include some DNS issues related to new TCP fallback
functionality, several rare race conditions, potentially incorrect
return value when glob aborts, and several signifiant arch-specific
bugs affecting TLSDESC on arm, riscv64 icache flushing, and
sh sigsetjmp and dlsym RTLD_NEXT.

1.2.5 release notes:

new features:
- statx function (linux extension; via syscall and fallback using fstatat)
- clone function is now usable and gives _Fork-like consistency in child
- statvfs now provides f_type result
- preadv2 and pwritev2 (linux extension) syscall wrappers
- riscv64 TLSDESC support

new ports:
- loongarch64
- riscv32

compatibility:
- DNS resolver can now handle answers with long CNAME chains
- string.h no longer provides (C23-incompat) non-prototype decl of basename
- fstatat statx backend now matches stat syscall non-automounting behavior
- mntent interfaces now handle escaped whitespace in paths/options

standards updates:
- printf %lc of nul wchar now produces output
- snprintf and swprintf no longer fail on n > INT_MAX
- ppoll is now exposed in default feature profile

bugs fixed:
- some long DNS answers were wrongly rejected despite new TCP support
- glob could wrongly return GLOB_NOMATCH if aborted before any matches
- multithreaded set*id could malfunction from thread sequencing logic bug
- certain use of threads after fork could deadlock thread-list lock
- posix_spawn child could deadlock in race with async parent death
- mbrtowc return value was wrong if argument n exceeded UINT_MAX
- 80-bit extended acoshl and powl got some corner cases wrong
- syslog incorrectly generated localized timestamps

arch-specific bugs fixed:
- arm (32-bit) TLSDESC malfunctioned due to addends being processed wrong
- riscv64 icache flush operation was non-functional
- sh sigsetjmp failed to properly restore call-saved register r8 on return
- sh dlsym RTLD_NEXT did not identify calling module correctly

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
[Removed patch adding basename hack again]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 months agoelfutils: update to 1.91
Tony Ambardar [Tue, 5 Mar 2024 11:20:07 +0000 (03:20 -0800)]
elfutils: update to 1.91

Release Notes:
https://sourceware.org/pipermail/elfutils-devel/2024q1/006876.html

Refresh patch:
- 005-build_only_libs.patch

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
7 months agonetifd: rewrite packet steering script
Felix Fietkau [Fri, 12 Apr 2024 19:51:50 +0000 (21:51 +0200)]
netifd: rewrite packet steering script

The new script uses a different strategy compared to the previous one.
Instead of trying to split flows by hash and spread them to all CPUs,
use RPS to redirect packets to a single core only.
Try to spread NAPI thread and RPS target CPUs across available CPUs
and try to ensure that the NAPI thread is on a different CPU than the
RPS target. This significantly reduces cycles wasted on the scheduler.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agoipq40xx: whw03v2: change LED color for 'running' state to blue
Rodrigo Balerdi [Sat, 13 Apr 2024 19:36:31 +0000 (16:36 -0300)]
ipq40xx: whw03v2: change LED color for 'running' state to blue

Change the RGB indicator LED color for the running state from green to
blue. There are various reasons for this change:

- In stock firmware, green means internet connection is up, red means it
  is down, and blue means indeterminate. To track stock behavior as
  closely as possible, OpenWrt should indicate blue by default.

- In the current 23.x OpenWrt releases for this router, the led glows
  blue all the time -not green- because the bootloader sets it blue
  and there is an OpenWrt bug that makes it unable to control the LED.
  The bug is fixed in master, so without this commit there would be an
  unexpected change of behavior for this device in the next release.

- The ports other closely related Linksys devices (such as EA8300 and
  MR8300) get this right and use blue for the running state.

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
7 months agoipq40xx: whw03v2: fix handling of RGB LED
Rodrigo Balerdi [Thu, 11 Apr 2024 18:44:10 +0000 (15:44 -0300)]
ipq40xx: whw03v2: fix handling of RGB LED

The RGB LED should glow green in the 'running' state, but it
was glowing cyan because the blue component defaulted to 'on'.

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
7 months agomac80211: ath11k: support DT property to limit channels
Robert Marko [Thu, 11 Apr 2024 19:08:44 +0000 (21:08 +0200)]
mac80211: ath11k: support DT property to limit channels

Limiting allowed channels per device may be required and is commonly
supported on other drivers, so include a pending patch to add support for
the same.

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agomediatek: fix DTS defining mt7530 switch phys but not referencing them
Daniel Golle [Fri, 12 Apr 2024 12:24:38 +0000 (13:24 +0100)]
mediatek: fix DTS defining mt7530 switch phys but not referencing them

The upstream solution to define the MDIO bus in DT is a bit
more strict than our previous downstream solution doing the same thing
and now requires switch PHYs to be referenced in DT as well.

Arınç Ünal told us in #15141:
"With [the now upstream patch written by him which we backported], the
switch MDIO bus won't be assigned to ds->user_mii_bus when the switch
MDIO bus is defined on the device tree anymore. This was not the case
with the downstream patch.

When ds->user_mii_bus is populated, DSA will 1:1 map the port with
PHY. Meaning port with address 1 will be mapped to PHY with address 1.
Because that ds->user_mii_bus is not populated when the switch MDIO
bus is defined on the device tree, on every port node, the PHY address
must be supplied by the phy-handle property."

Add those phy-handles to affected devices' DT.

Fixes: 4354b34f6f ("generic: 6.6: sync mt7530 DSA driver with upstream")
Fixes: 401a6ccfaf ("generic: 6.1: sync mt7530 DSA driver with upstream")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agoramips: add support for TP-Link EC220-G5 v2
Mieczyslaw Nalewaj [Fri, 12 Apr 2024 14:44:23 +0000 (16:44 +0200)]
ramips: add support for TP-Link EC220-G5 v2

TP-Link EC220-G5 v2 is a dual band router with 4 GbE ports
Advertised as AC1200 for its 867Mbps (2x2) 5GHz band
and 300 Mbps (2x2) 2.4GHz band.

Specs:
- SoC: MediaTek MT7620A
- Ethernet: 4x GbE ports (Realtek RTL8367S)
- Wireless 2.4GHz: MediaTek MT7620A
- Wireless 5GHz: MediaTek MT7612E
- RAM: 64MiB
- ROM: 8MiB (W25Q64BV)
- 2 Buttons (WPS and reset)
- 7 LEDs

Flash instructions via serial console:
1. Rename the factory.bin to to test.bin
2. start a TFTP server from IP address 192.168.0.225 and serve the image named test.bin
3. connect your device to the LAN port
4. power up the router and press 4 on the console to stop the boot process.
5. enter the following commands on the router console
tftp 0x80060000 test.bin
erase tplink 0x20000 0x7a0000
cp.b 0x80060000 0x20000 0x7a0000
reset

Flash instructions via TFTP:
1. Update orginal firmware of the router to the latest one.
2. Rename openwrt-ramips-mt7620-tplink_ec220-g5-v2-squashfs-tftp-recovery.bin to tp_recovery.bin
3. Change computer IP to 192.168.0.66
4. Run TFTP serwer
5. Start the router with the reset button pressed, the file will be automatically downloaded and after a while the router will restart.
6. After updating, set your computer's IP to DHCP

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
7 months agoramips: mt7620a_tplink_archer.dtsi rename to mt7620a_tplink_8m.dtsi
Mieczyslaw Nalewaj [Fri, 12 Apr 2024 14:14:18 +0000 (16:14 +0200)]
ramips: mt7620a_tplink_archer.dtsi rename to mt7620a_tplink_8m.dtsi

Change the name mt7620a_tplink_archer.dtsi to mt7620a_tplink_8m.dtsi because it will also be a base for TP-Link non-Archer routers.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
7 months agoramips: TP-Link Archer C2 v1: simplification of the dts definition
Mieczyslaw Nalewaj [Fri, 12 Apr 2024 11:57:26 +0000 (13:57 +0200)]
ramips: TP-Link Archer C2 v1: simplification of the dts definition

Import from the mt7620a_tplink_archer.dtsi file and thus simplify the rest of the definition.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
7 months agoramips: mt7620a_tplink_archer.dtsi - remove unnecessary nvmem-cells definitions
Mieczyslaw Nalewaj [Fri, 12 Apr 2024 11:44:39 +0000 (13:44 +0200)]
ramips: mt7620a_tplink_archer.dtsi - remove unnecessary nvmem-cells definitions

Remove unnecessary nvmem-cells definitions that are being redefined anyway.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
7 months agomac80211: improve mesh fast tx patch
Felix Fietkau [Sat, 13 Apr 2024 14:05:07 +0000 (16:05 +0200)]
mac80211: improve mesh fast tx patch

Change hash key struct size for faster lookup.
Fix clearing cache entries for forwarding

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agohostapd: fix a crash corner case
Felix Fietkau [Wed, 10 Apr 2024 11:46:40 +0000 (13:46 +0200)]
hostapd: fix a crash corner case

On some setup failures, iface->bss can be NULL

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agouboot-d1: define default BUILD_SUBTARGET
Tianling Shen [Sat, 13 Apr 2024 05:04:58 +0000 (13:04 +0800)]
uboot-d1: define default BUILD_SUBTARGET

As commit 3ce1e4c3d3da ("d1: define subtarget specifically") added the
'generic' subtarget, without 'BUILD_SUBTARGET' the correspond U-Boot
package will be no longer selected automatically.

Fixes: 3ce1e4c3d3da ("d1: define subtarget specifically")
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
7 months agorealtek: fix filter_port_list_reverse calls
Stijn Tintel [Sat, 13 Apr 2024 10:15:59 +0000 (13:15 +0300)]
realtek: fix filter_port_list_reverse calls

The function introduced in commit 7cbfe5654d6e is named
filter_port_list_reverse, not filter_port_list_reversed.

Fixes the following error on hpe,1920-8g-poe-65w and
hpe,1920-8g-poe-180w.

  /bin/board_detect: /etc/board.d/02_network: line 84: filter_port_list_reversed: not found

Fixes: 7cbfe5654d6e ("realtek: move port filtering out of uci_set_poe()")
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
Acked-by: Sander Vanheule <sander@svanheule.net>
7 months agoCI: labeler: add d1 target
Robert Marko [Sat, 13 Apr 2024 09:25:52 +0000 (11:25 +0200)]
CI: labeler: add d1 target

Add support for 'd1' target and its specific packages in labeler.

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agobpftool: Update to v7.4.0
Tony Ambardar [Wed, 3 Apr 2024 22:31:22 +0000 (15:31 -0700)]
bpftool: Update to v7.4.0

Update to the latest upstream release to include recent improvements and
bugfixes. Update copyright, fix typo in PKG_NAME, and remove unneeded use
of MAKE_VARS definition in Makefile. Drop 001-cflags.patch and simplify
002-includes.patch after refreshing. Also simplify LTO/DCE build flags.

Link: https://github.com/libbpf/bpftool/releases/tag/v7.4.0
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
7 months agolibbpf: Update to v1.4.0
Tony Ambardar [Wed, 3 Apr 2024 22:31:29 +0000 (15:31 -0700)]
libbpf: Update to v1.4.0

Update to the latest upstream release to include recent improvements and
bugfixes, and update copyright. Remove MAKE_VARS usage in Makefile and drop
001-cflags.patch which are no longer needed. Also add flags to disable LTO,
mistakenly dropped earlier.

Link: https://github.com/libbpf/libbpf/releases/tag/v1.4.0
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
7 months agobuild: use zstd for IB, toolchain, SDK and LLVM compression
Paul Spooren [Tue, 13 Feb 2024 00:03:44 +0000 (01:03 +0100)]
build: use zstd for IB, toolchain, SDK and LLVM compression

Use similar efficient but faster compression algorithm.

Signed-off-by: Paul Spooren <mail@aparcar.org>
7 months agoscripts/kernel_bump: Delete merge commit
Olliver Schinagl [Mon, 18 Mar 2024 13:03:59 +0000 (14:03 +0100)]
scripts/kernel_bump: Delete merge commit

While we have included the needed changes via a merge commit, there is
no need to keep it. Lets drop the merge commit, which we can do as we
haven't pushed anything.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Allow bumping sub-targets
Olliver Schinagl [Mon, 18 Mar 2024 12:40:50 +0000 (13:40 +0100)]
scripts/kernel_bump: Allow bumping sub-targets

Some targets may need to bump specific sub-targets only. So lets offer
this as an option.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Use the git index to find the needed config files
Olliver Schinagl [Mon, 18 Mar 2024 12:28:11 +0000 (13:28 +0100)]
scripts/kernel_bump: Use the git index to find the needed config files

The current solution using `find` introduces a racecondition, where `find`
and `git mv` get in each others way. While this could be fixed with
more-utils sponge command (or even sort -u) to buffer the output of
find.

However, a much better approach, is to query the git index directly,
which will not change, and is far more accurate.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Use git to obtain the list of files
Olliver Schinagl [Mon, 18 Mar 2024 12:24:12 +0000 (13:24 +0100)]
scripts/kernel_bump: Use git to obtain the list of files

Instead of looping of a directory to find directories related to kernel
changes, use the git index instead.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Allow for migrating only configuration files
Olliver Schinagl [Mon, 18 Mar 2024 12:10:31 +0000 (13:10 +0100)]
scripts/kernel_bump: Allow for migrating only configuration files

In some cases, we want to only migrate configuration files, e.g. if the
kernel was bumped already. Lets add a flag for this case to offer
flexibility. By default we will migrate configuration flags as before.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Run script relative to the script dir
Olliver Schinagl [Thu, 21 Mar 2024 09:27:44 +0000 (10:27 +0100)]
scripts/kernel_bump: Run script relative to the script dir

Determine the target directory based on the script location, which might
work better in some cases, but at least also allows the script to be ran
from with any location in the OpenWRT repository.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Do no run on dirty repositories
Olliver Schinagl [Mon, 18 Mar 2024 12:09:23 +0000 (13:09 +0100)]
scripts/kernel_bump: Do no run on dirty repositories

We want to avoid starting a process when we know it will fail later.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Improve omitted version error
Olliver Schinagl [Thu, 21 Mar 2024 08:41:54 +0000 (09:41 +0100)]
scripts/kernel_bump: Improve omitted version error

If a version string was not supplied, we currently print an empty
string. We can do better here. Also by popular demand, print the usage
information in case of error.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Always drop v prefix
Olliver Schinagl [Fri, 22 Mar 2024 07:38:02 +0000 (08:38 +0100)]
scripts/kernel_bump: Always drop v prefix

Naivly and lazyly the leading v was only dropped from optarg, not from any
environment variable.

Lets do this properly and ensure a leading 'v' is always dropped.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Drop unused function
Olliver Schinagl [Mon, 18 Mar 2024 12:08:44 +0000 (13:08 +0100)]
scripts/kernel_bump: Drop unused function

No need to keep unused empty functions. A left over from early development.

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agoscripts/kernel_bump: Avoid potential copyright claim
Olliver Schinagl [Sun, 17 Mar 2024 07:46:08 +0000 (08:46 +0100)]
scripts/kernel_bump: Avoid potential copyright claim

Due to potential fears of copyright infringement noted by Elliott
Mitchell [0], rewrite our message to belong to OpenWRT.

Note, AI was used to aid in construction of this sentence.

[0]: https://lists.openwrt.org/pipermail/openwrt-devel/2024-March/042422.html

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
7 months agomediatek: mt7622: rtl8367c: source code spell fixes
Paul Donald [Wed, 3 Apr 2024 15:07:06 +0000 (17:07 +0200)]
mediatek: mt7622: rtl8367c: source code spell fixes

Improves indexing and searches

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agomediatek: mt7622: rtl8367c: source comment fixes
Paul Donald [Wed, 3 Apr 2024 16:04:40 +0000 (18:04 +0200)]
mediatek: mt7622: rtl8367c: source comment fixes

Fix also some Chinese -> UTF8 encoding problems

Improves indexing and searches

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agomediatek: mt7622: rtl8367c: source comment fixes
Paul Donald [Wed, 3 Apr 2024 15:55:15 +0000 (17:55 +0200)]
mediatek: mt7622: rtl8367c: source comment fixes

Fix also some Chinese GB18030 -> UTF-8 encoding problems

(translated the Chinese strings to English):
修改 -> modification
port8~port10的设置在另外一个register ->
 port8~port10 setup is done in a separate register

You are in the correct (UTF-8) encoding when you see:
 * $Date: 2017-03-08 15:13:58 +0800 (週三, 08 三月 2017) $
e.g. week 3, 08 third month, 2017
But not if you see:
 * $Date: 2017-03-08 15:13:58 +0800 (閫变笁, 08 涓夋湀 2017) $

rtl8367c/rtl8367c_asicdrv_lut.c should be read as UTF-8, despite having
some earlier Chinese text lost to GB18030 encoding.

Improves indexing and searches

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agomediatek: mt7622: rtl8367c: source comment fixes
Paul Donald [Wed, 3 Apr 2024 15:23:16 +0000 (17:23 +0200)]
mediatek: mt7622: rtl8367c: source comment fixes

Fix also some Chinese -> UTF8 encoding problems

Improves indexing and searches

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agomediatek: mt7622: rtl8367c: source comment fixes
Paul Donald [Wed, 3 Apr 2024 14:10:55 +0000 (16:10 +0200)]
mediatek: mt7622: rtl8367c: source comment fixes

Improves indexing and searches

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agolldpd: make management address advertisement controllable
Paul Donald [Tue, 2 Apr 2024 11:43:03 +0000 (13:43 +0200)]
lldpd: make management address advertisement controllable

Defaults to off.

Available from >= 0.7.15

These are sent in TLV

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agolldpd: make capabilities advertisement controllable
Paul Donald [Wed, 3 Apr 2024 12:06:29 +0000 (14:06 +0200)]
lldpd: make capabilities advertisement controllable

Defaults to off.

Only available from >= 1.0.15

These capabilities are sent in TLV.

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agoqualcommax: enhance smp_affinity (log, uci, syntax)
Sean Khan [Tue, 9 Apr 2024 03:11:37 +0000 (23:11 -0400)]
qualcommax: enhance smp_affinity (log, uci, syntax)

1.) Changed logic of `set_affinity` to now use physical cores rather than
    knowing the bitmask. Rather than having to know a bitmask, users can
    provide a numerical instance of one or more CPU cores
    (numbered 0-63).

    This is done via function `cpus_to_bitmask`.

    Functions Added:

    a.) bitmask_to_cpus - Takes a bitmask of CPUs and returns a
         list of CPU numbers. (i.e. `bitmask_to_cpus "f"` -> 0,1,2,3)

    b.) cpus_to_bitmask - Takes a comma/space or range list of CPUs and returns
         a bitmask.

         Example:
         `cpus_to_bitmask "2,3"`     -> c
         `cpus_to_bitmask "0,1,2,3"` -> f
         `cpus_to_bitmask "1,3"`     -> a

         With or without quotes
         `cpus_to_bitmask "1 3"`     -> a
         `cpus_to_bitmask  1 3`      -> a

2.) Added UCI options:

    enable     - to enable/disable the script from running.   [default 1 (on)]
    enable_log - to enable/disable logging output to `logger`.[default 1 (on)]

    Log output:
```
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(87) reo2host-destination-ring1    to CPU 0
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(88) reo2host-destination-ring2    to CPU 1
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(89) reo2host-destination-ring3    to CPU 2
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(90) reo2host-destination-ring4    to CPU 3
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(79) wbm2host-tx-completions-ring1 to CPU 1
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(83) wbm2host-tx-completions-ring2 to CPU 2
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(85) wbm2host-tx-completions-ring3 to CPU 3
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(73) ppdu-end-interrupts-mac1      to CPU 1
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(77) ppdu-end-interrupts-mac2      to CPU 2
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(75) ppdu-end-interrupts-mac3      to CPU 3
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(32) edma_txcmpl                   to CPU 3
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(33) edma_rxfill                   to CPU 3
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(35) edma_rxdesc                   to CPU 3
    Mon Apr  8 23:00:01 2024 user.notice smp_affinity: Pinning IRQ(36) edma_misc                     to CPU 3
```

    Output of `/proc/interrupts`:
```
 69:          0          0          0          0 GIC-0 209 Edge      rxdma2host-destination-ring-mac1
 70:          0          0          0          0 GIC-0 211 Edge      rxdma2host-destination-ring-mac3
 71:          0          0          0          0 GIC-0 210 Edge      rxdma2host-destination-ring-mac2
 72:       2435          0          0          0 GIC-0 321 Edge      reo2host-status
 73:     268427       8011          0          0 GIC-0 261 Edge      ppdu-end-interrupts-mac1
 74:          2          0          0          0 GIC-0 255 Edge      rxdma2host-monitor-status-ring-mac1
 75:     176169          0          4      10035 GIC-0 263 Edge      ppdu-end-interrupts-mac3
 76:          2          0          0          0 GIC-0 260 Edge      rxdma2host-monitor-status-ring-mac3
 77:          0          0          0          0 GIC-0 262 Edge      ppdu-end-interrupts-mac2
 78:          0          0          0          0 GIC-0 256 Edge      rxdma2host-monitor-status-ring-mac2
 79:       3428       3123          0          0 GIC-0 189 Edge      wbm2host-tx-completions-ring1
 80:          0          0          0          0 GIC-0 323 Edge      reo2ost-exception
 81:        178          0          0          0 GIC-0 322 Edge      wbm2host-rx-release
 82:          0          0          0          0 GIC-0 212 Edge      host2rxdma-host-buf-ring-mac1
 83:       6524          0      13712          0 GIC-0 190 Edge      wbm2host-tx-completions-ring2
 84:          4          0          0          0 GIC-0 235 Edge      host2rxdma-host-buf-ring-mac3
 85:        560          0          0       1979 GIC-0 191 Edge      wbm2host-tx-completions-ring3
 86:          0          0          0          0 GIC-0 215 Edge      host2rxdma-host-buf-ring-mac2
 87:       4520          0          0          0 GIC-0 267 Edge      reo2host-destination-ring1
 88:       2231       2811          0          0 GIC-0 268 Edge      reo2host-destination-ring2
 89:       2180          0       2512          0 GIC-0 271 Edge      reo2host-destination-ring3
 90:       1990          0          0       2321 GIC-0 320 Edge      reo2host-destination-ring4
```

3.) Added `uci-defaults` script `15_smp_affinity` to configure defaults
    options on first boot.

Signed-off-by: Sean Khan <datapronix@protonmail.com>
7 months agolldpd: note about capabilities
Paul Donald [Tue, 2 Apr 2024 11:42:35 +0000 (13:42 +0200)]
lldpd: note about capabilities

only available from >= 1.0.15

Comments are useful. Apparently this config parameter was committed when
openwrt used an older version of lldpd which did not yet support it.

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
7 months agolldpd: fix restart
Paul Donald [Tue, 2 Apr 2024 11:42:20 +0000 (13:42 +0200)]
lldpd: fix restart

Redirection broke in 5364fe0f01ca ("lldpd: shellcheck fixes")

redirects to /dev/null shall be handled correctly (i.e. last).

This fixes these errors on `/etc/init.d/lldpd reload`:

2024-03-16T20:39:00 [WARN/lldpctl] unknown command from argument 1: `/dev/null`
2024-03-16T20:39:00 [WARN/lldpctl] unknown command from argument 1: `/dev/null`
2024-03-16T20:39:00 [WARN/lldpctl] unknown command from argument 1: `/dev/null`
2024-03-16T20:39:00 [WARN/lldpctl] unknown command from argument 1: `/dev/null`

Tested-on: 22.03.6
Fixes: 5364fe0f01ca ("lldpd: shellcheck fixes")
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
[ improve commit description, add fixes tag ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
7 months agopackage: kernel: leds-gca230718: fix build with Linux 6.6
Daniel Golle [Fri, 12 Apr 2024 01:02:36 +0000 (02:02 +0100)]
package: kernel: leds-gca230718: fix build with Linux 6.6

Starting with Linux 6.3 the .probe call no longer got the id parameter,
see also commit torvalds/linux@03c835f498b5
("i2c: Switch .probe() to not take an id parameter").

As the parameter is anyway unused by the driver, drop it when
building the GCA230718 LED driver for newer kernels.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agoqualcommax: drop 6.1 support
Robert Marko [Thu, 11 Apr 2024 15:26:47 +0000 (17:26 +0200)]
qualcommax: drop 6.1 support

We have defaulted to 6.6 for a while so its time to completely drop 6.1
so new devices dont have to include patches for 6.1.

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agomediatek: filogic: add support for Edgecore EAP111
Robert Marko [Sat, 23 Mar 2024 19:03:34 +0000 (20:03 +0100)]
mediatek: filogic: add support for Edgecore EAP111

HW specifications:
* Mediatek MT7981A
* 256MB SPI-NAND
* 512MB DRAM
* Uplink: 1 x 10/100/1000Base-T Ethernet, Auto MDIX, RJ-45 with 802.3at
PoE (Built-in GBe PHY)
* LAN: 1 x 10/100/1000Base-T Ethernet, Auto MDIX, RJ-45 (Airoha EN8801SC)
* 1 Tricolor LED
* Reset button
* 12V/2.0A DC input

Installation:
Board comes with OpenWifi/TIP which is OpenWrt based, so sysupgrade can
be used directly over SSH.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
7 months agomediatek: add Airoha EN8801SC PHY driver
Robert Marko [Thu, 11 Apr 2024 11:09:56 +0000 (13:09 +0200)]
mediatek: add Airoha EN8801SC PHY driver

Airoha EN8801SC PHY is a gigabit PHY used on Edgecore EAP111 so, include
the MTK driver with some cleanups.

Unfortunatelly, there is no specification sheet nor datasheet available
in order to demistify the magic PBUS writes and work on upstreaming
this driver.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
7 months agogeneric: 6.1, 6.6: import two pending patches for mt7530 DSA driver
Daniel Golle [Wed, 10 Apr 2024 14:53:11 +0000 (15:53 +0100)]
generic: 6.1, 6.6: import two pending patches for mt7530 DSA driver

First patch allows to inquire and modify Energy-Efficient-Ethernet
(EEE) settings via ethtool and thereby override the default setting of
a board done via bootstrap pins.

The second patch fixes a long-standing issue with STP (and similar
protocols) when using boards (or SoCs) governed by the mt7530 DSA
driver.

Both patches could also be (dirty-)applied to Linux 5.15, but I'd
rather just wait for that to happen via linux-stable to avoid the
mess.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agogeneric: 6.6: sync mt7530 DSA driver with upstream
Daniel Golle [Wed, 10 Apr 2024 14:14:32 +0000 (15:14 +0100)]
generic: 6.6: sync mt7530 DSA driver with upstream

Backport lots upstream changes, many of them fixes, for the mt7530 DSA
driver, similar to how it was done for Linux 6.1 in the previous commit.

The remaining differences compared to the upstream driver are only
the 'slave' -> 'user', 'master' -> 'conduit' language change in DSA
and the rename of 'struct ethtool_eee' to 'struct ethtool_keee' as
well as tree-wide replacement of ethtool_sprintf with ethtool_puts,
all of them do not have any functional impact.

Apart from some minor bug fixes and style improvements the switch
should now behave more conformant when it comes to link-local frames,
and we will again be able to cleanly pick patches from upstream.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agogeneric: 6.1: sync mt7530 DSA driver with upstream
Daniel Golle [Tue, 9 Apr 2024 22:33:05 +0000 (23:33 +0100)]
generic: 6.1: sync mt7530 DSA driver with upstream

Backport lots upstream changes, many of them fixes, for the mt7530 DSA
driver. Some of them may or may not find they way into Linux 6.1
stable, some certainly won't because they are fixes for backported
commits which aren't even present in Linux 6.1 upstream.

Apart from adding new patches, also remove mutated patch
723-net-mt7531-ensure-all-MACs-are-powered-down-before-r.patch
which should never have been added for Linux 6.1 -- it was applied
already upstream but coincidentally would fuzzy-apply in the wrong
place as well (for MT7530 instead of MT7531). While that didn't really
hurt anyone it is just unneeded.

The other deleted patch
795-mt7530-register-OF-node-for-internal-MDIO-bus.patch
has been replaced by an equivalent commit with a more complete patch
description by upstream maintainer Arınç Ünal.

The remaining differences compared to the upstream driver are:
 * C22/C45 MDIO ops aren't split
   Upstream did that, backporting it would require making changes to
   *all* DSA drivers
 * 'slave' -> 'user', 'master' -> 'conduit' language change in DSA
 * support for selecting preferred CPU port on MT7531
   Also this would require too many DSA framework changes potentially
   affecting other devices. If we ever really use Linux 6.1 in a
   release (I hope not) we can still reconsider to make the effort to
   backport that.

In addition to some minor bug fixes and style improvements the switch
should now behave more conformant when it comes to link-local frames,
and we will again be able to cleanly pick patches from upstream.

MAINTAIERS NOTE:
Three patches are already part of Linux stable and should be removed with
the next minor kernel version bump:
789-STABLE-01-net-dsa-mt7530-prevent-possible-incorrect-XTAL-frequ.patch
789-STABLE-02-net-dsa-mt7530-fix-link-local-frames-that-ingress-vl.patch
789-STABLE-03-net-dsa-mt7530-fix-handling-of-all-link-local-frames.patch

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agokernel: add kmod-hwmon-emc2305 support
Oleg S [Sun, 24 Mar 2024 18:26:08 +0000 (21:26 +0300)]
kernel: add kmod-hwmon-emc2305 support

This module supports the Microchip Technology Inc (SMSC)
EMC2301/EMC2302/EMC2303/EMC2305 fan speed PWM controller chips.

Signed-off-by: Oleg S <remittor@gmail.com>
7 months agoucode: update to Git HEAD (2024-04-07)
Felix Fietkau [Tue, 9 Apr 2024 09:21:39 +0000 (11:21 +0200)]
ucode: update to Git HEAD (2024-04-07)

1220992631d5 ubus: automatically clear error information
d6fd94014eea uci: automatically clear error information
99837f280b61 uloop: automatically clear error information
be767ae197ba vm: rework `in` operator semantics
4ade84e8fb81 ubus: add explicit support for deferring incoming requests

Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 months agoconfig: fix CONFIG_GDB appearing in main menuconfig menu
Robert Marko [Mon, 8 Apr 2024 20:05:19 +0000 (22:05 +0200)]
config: fix CONFIG_GDB appearing in main menuconfig menu

I noticed that CONFIG_GDB was suddenly appearing in the main menuconfig
menu despite the fact that it should be visible only when TOOLCHAINOPTS
is selected and under a dedicated menu.

After some trial and error, it seems that this was caused by the recent
addition of GCC_USE_DEFAULT_VERSION, and after even more trial and error
it gets fixed as soon GCC_USE_DEFAULT_VERSION is placed after GCC_VERSION.

So, lets simply put GCC_USE_DEFAULT_VERSION after GCC_VERSION.

Fixes: 501ef81040ba ("config: select KERNEL_WERROR if building with default GCC version")
Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agogeneric: add missing patch headers
Daniel Golle [Tue, 9 Apr 2024 16:39:46 +0000 (17:39 +0100)]
generic: add missing patch headers

Make sure all patches can be applied to a git tree using 'git am'
by adding missing patch headers where needed.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agotools: zstd: dont override CLI max level
Robert Marko [Mon, 8 Apr 2024 16:35:45 +0000 (18:35 +0200)]
tools: zstd: dont override CLI max level

Now that instead of relying on env variables for the GH download script
invoking ZSTD tarball compression it passes the full arguments via tar -I
we can drop the CLI max compression level override.

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agoscripts/dl_github_archive: use tar -I for ZSTD
Robert Marko [Mon, 8 Apr 2024 16:38:51 +0000 (18:38 +0200)]
scripts/dl_github_archive: use tar -I for ZSTD

Instead of relying on env variables for setting the ZSTD compression
configuration we can simply do what we do for IB, SDK and the rest and
use tar -I to pass "zstd -T0 --ultra -20" directly.

This makes it rather clear what is being done and allows to drop the
zstd CLI max level override as its usually capped at level 19.

Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agomediatek: filogic: switch TP-LINK XDR series to fitblk
Daniel Golle [Fri, 23 Feb 2024 16:03:00 +0000 (16:03 +0000)]
mediatek: filogic: switch TP-LINK XDR series to fitblk

Instead of using the deprecated FIT partition parser, use the new
fitblk driver instead.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agomvebu: puzzle-m90x: wipe rootfs_data on sysupgrade
Daniel Golle [Tue, 9 Jan 2024 19:54:51 +0000 (19:54 +0000)]
mvebu: puzzle-m90x: wipe rootfs_data on sysupgrade

The sysupgrade formware of the Puzzle series is a slightly strange
dual-boot approach while remaining compatible with Marvell's SDK
firmware upgrade binary format -- which happens to be a full-disk
image with GPT partition table. Hence that /lib/upgrade/emmc-puzzle.sh
script is like an exotic disease which results from those decisions,
and as we also want to somehow stay compatible with the IEI-World
stock firmware we got to use it in that same way (we are not
compatible with the QNAP-branded identical hardware device anyway).

Currently, on sysupgrade the result is that one ends up with the old
content of rootfs_data (a GPT partition on those devices) as nothing
ever wipes or in any way re-creates the filesystem there. As a simple
work-around, let's kill the filesystem on rootfs_data so fstools
re-formats it on the next boot.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
7 months agosdk: include lib/crtsavres.o for powerpc
Robert Marko [Mon, 8 Apr 2024 15:52:22 +0000 (17:52 +0200)]
sdk: include lib/crtsavres.o for powerpc

Trying to link certain kernel modules like dahdi-linux when building with
the OpenWrt SDK will fail with:
openwrt-sdk-apm821xx-sata_gcc-13.2.0_musl.Linux-x86_64/staging_dir/toolchain-powerpc_464fp_gcc-13.2.0_musl/bin/powerpc-openwrt-linux-musl-ld: cannot find arch/powerpc/lib/crtsavres.o: No such file or directory

Previously this worked with the PowerPC SDK since we carried a hack that
was passing --save-restore-funcs to module LDFLAGS so the linker provided
the required functions automatically as without --save-restore-funcs it
doesnt do so automatically on relocatable links and as a sideffect did not
require the kernel provided crtsaves.o to link against.

Now that hack has been removed as upstream kernel now compiles crtsaves.o
by default so it can be linked against but its not included in the SDK.

So, lets include lib/crtsavres.o when SDK is generated for PowerPC.

Fixes: 99c9d8abd677 ("kernel: bump 5.15 to 5.15.148")
Signed-off-by: Robert Marko <robimarko@gmail.com>
7 months agoqualcommax: Skip compiling unnecessary dtbs
Sean Khan [Mon, 8 Apr 2024 20:24:12 +0000 (16:24 -0400)]
qualcommax: Skip compiling unnecessary dtbs

Currently the compile phase of the kernel builds `Image dtbs modules`.
However, none of the dtbs that get built are used for the final image.

This ends up unnecessarily taking CPU cycles and produces a lot of
`WARNINGS` that can lead users to believe there's cause for concern. I
believe the same principle can be applied to other targets.

```
DTC     arch/arm64/boot/dts/qcom/msm8996-mtp.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])

DTC     arch/arm64/boot/dts/qcom/msm8996-sony-xperia-tone-dora.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])

DTC     arch/arm64/boot/dts/qcom/msm8996-sony-xperia-tone-kagura.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])

DTC     arch/arm64/boot/dts/qcom/msm8996-sony-xperia-tone-keyaki.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])

DTC     arch/arm64/boot/dts/qcom/msm8996-xiaomi-gemini.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])

DTC     arch/arm64/boot/dts/qcom/msm8996-xiaomi-natrium.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])

DTC     arch/arm64/boot/dts/qcom/msm8996-xiaomi-scorpio.dtb
arch/arm64/boot/dts/qcom/msm8996.dtsi:2954.36-2962.5: Warning (clocks_property):
/soc/clock-controller@6400000: Missing property '#clock-cells' in node
/soc/mailbox@9820000 or bad phandle (referred from clocks[2])
```

Signed-off-by: Sean Khan <datapronix@protonmail.com>
7 months agotreewide: remove implicit SUBTARGET
Paul Spooren [Mon, 8 Apr 2024 06:05:29 +0000 (08:05 +0200)]
treewide: remove implicit SUBTARGET

Historically it's possible to leave the `SUBTARGETS` undefined and
automatically fallback to a "generic" subtarget. This however breaks
various downstream scripts which may have expectations around filenames:

While some targets with an explicit generic subtarget contain `generic`
in the filenames of artifacts, implicit "subtargets" don't.

Right now this breaks the CI[1], possibly also scripts using the ImageBuilders.

This commit removes all code that support implicit handling of
subtargets and instead requires every target to define "SUBTARGETS".

[1]: https://github.com/openwrt/openwrt/actions/runs/8592821105/job/23548273630

Signed-off-by: Paul Spooren <mail@aparcar.org>