openwrt/staging/nbd.git
6 months agoimage: add missing DTC include-prefixes directory
Álvaro Fernández Rojas [Fri, 10 May 2024 11:39:07 +0000 (13:39 +0200)]
image: add missing DTC include-prefixes directory

include-prefixes were moved to a common directory in linux v4.12, see
https://github.com/torvalds/linux/commit/d5d332d3f7e8435e264a71b90178dee69428d630

This is needed for bcm27xx kernel v6.6 support.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
6 months agorealtek: Trap LLDP packets to the CPU
Kevin Jilissen [Sat, 4 May 2024 14:12:20 +0000 (16:12 +0200)]
realtek: Trap LLDP packets to the CPU

We should setup the registers for trapping LLDP packets to the CPU.
Currently, these packets are forwarded to all ports which is not desired
behaviour.

Signed-off-by: Kevin Jilissen <info@kevinjilissen.nl>
6 months agorealtek: Change LLTP register to LLDP
Kevin Jilissen [Sat, 4 May 2024 14:11:00 +0000 (16:11 +0200)]
realtek: Change LLTP register to LLDP

These registers control the handling of Link Layer Discovery Protocol
(LLDP) packets. This seems to be a typo in the naming.

Signed-off-by: Kevin Jilissen <info@kevinjilissen.nl>
6 months agobcm27xx-utils: update to latest version
Álvaro Fernández Rojas [Fri, 10 May 2024 07:17:52 +0000 (09:17 +0200)]
bcm27xx-utils: update to latest version

Full changelog:
https://github.com/raspberrypi/utils/compare/e65f5ec102e74218cda7da9fdc8b1caa0fd1127d...451b9881b72cb994c102724b5a7d9b93f97dc315

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
6 months agobcm27xx-gpu-fw: update to v1.20240424
Álvaro Fernández Rojas [Fri, 10 May 2024 07:15:15 +0000 (09:15 +0200)]
bcm27xx-gpu-fw: update to v1.20240424

This includes multiple updates for BCM2711 and BCM2712.

Full changelog:
https://github.com/raspberrypi/firmware/compare/0968de28716a9b1f106b8492646d0ed0a2800152...1.20240424

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
6 months agogperf: build as C++11
Rosen Penev [Sat, 27 Apr 2024 21:57:50 +0000 (14:57 -0700)]
gperf: build as C++11

Newer compilers default to building with C++17 as default, which has the
register keyword removed and thus errors.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
6 months agoramips: add support for Wavlink WL-WN531G3
Eros Brigmann [Mon, 8 Apr 2024 19:36:57 +0000 (21:36 +0200)]
ramips: add support for Wavlink WL-WN531G3

This device is similiar to the Wavlink WL-WN531A3.
Hardware
--------
SoC:   Mediatek MT7620A
RAM:   64MB
FLASH: 8MB NOR (GigaDevice GD25Q64CS)
ETH:
  - 2x 10/100/1000 Mbps Ethernet (RTL8211F)
  - 3x 10/100 Mbps Ethernet (integrated in SOC)
WIFI:
  - 2.4GHz: 1x (integrated in SOC) (2x2:2)
  - 5GHz:   1x MT7612E (2x2:2)
  - 4 external antennas
BTN:
  - 1x Reset button
  - 1x Touchlink button
  - 1x Turbo button
  - 1x Wps button
  - 1x ON/OFF switch
LEDS:
  - 1x Red led (system status)
  - 1x Blue led (system status)
  - 5x Blue leds (ethernet ports)
  - 1x Power led
  - 1x Wifi led
UART:
  - 57600-8-N-1
Everything works correctly.

Installation
------------
Flash the initramfs image in the OEM firmware interface
When Openwrt boots, flash the sysupgrade image otherwise you won't be
able to keep configuration between reboots.
In my case the whole device was locked and there was no way
to flash the image, except for flashing directly to the flash
via an spi-flasher. You need to put the sysupgrade image file at
the beginning of 0x60000.

Notes
-----
1) Router mac addresses:
   LAN XX:XX:XX:XX:XX:F0 (factory @ 0x28)
   WAN XX:XX:XX:XX:XX:F1 (factory @ 0x2e)
   WIFI 2G XX:XX:XX:XX:XX:F2 (factory @ 0x04)
   WIFI 5G XX:XX:XX:XX:XX:F3 (factory @ 0x8004)

   LABEL XX:XX:XX:XX:XX:F2

Signed-off-by: Eros Brigmann <erosbrigmann@gmail.com>
6 months agoath79: enable 6.6 testing kernel
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: enable 6.6 testing kernel

The ath79 target now supports the vanilla 6.6 kernel. Enjoy it!

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: skip reset control for syscon devices
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: skip reset control for syscon devices

Fix the issue of exclusive reset controller acquisition failure on
kernel 6.6.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: refresh 6.6 kernel config files
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: refresh 6.6 kernel config files

All kernel config files are refreshed by
`make kernel_oldconfig CONFIG_TARGET={subtarget_target,subtarget}`

"CONFIG_SQUASHFS_DECOMP_SINGLE=y" is manually selected as all ath79
SoCs are single core processors.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: refresh 6.6 kernel patches
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: refresh 6.6 kernel patches

Some APIs have been changed. Porting them to the new kernel 6.6
version to fix the compile error.

Removed upstreamed:
010-v6.4-gpio-ath79-Convert-to-immutable-irq_chip.patch[1]

Manually rebased:
700-phy-add-ath79-usb-phys.patch
721-phy-mdio-bitbang-prevent-rescheduling-during-command.patch. ref:[2]

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-6.6.y&id=b11ce7e48121a02ceedec9f4dfcab4f2bee8f35f
[2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-6.6.y&id=002dd3de097c778a74ae9e47e598bea6ad055af0

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: restore kernel 6.1 config files and patches
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: restore kernel 6.1 config files and patches

Copy patches and kernel configs from kernel 6.6 to restore the
default 6.1 kernel support files.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: rename patches directory and kernel config from 6.1 to 6.6
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: rename patches directory and kernel config from 6.1 to 6.6

This is preparation for 6.6 kernel support. Renaming files allows
us to better track their git history.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: add MikroTik suffix to the local GPIO latch driver
Shiji Yang [Sat, 16 Mar 2024 00:39:16 +0000 (08:39 +0800)]
ath79: add MikroTik suffix to the local GPIO latch driver

The upcoming 6.6 kernel will introduce a new upstream generic
"gpio-latch" driver. It will conflict with the downstream MikroTik
GPIO latch driver. Let's rename it to avoid any potential issues.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agoath79: fix build error for downstream gpio drivers
Shiji Yang [Mon, 29 Apr 2024 20:26:17 +0000 (20:26 +0000)]
ath79: fix build error for downstream gpio drivers

Initialize fwnode instead of the deprecated of_node.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
6 months agomediatek: add support for Cudy TR3000 v1
Luis Mita [Tue, 7 May 2024 15:48:37 +0000 (11:48 -0400)]
mediatek: add support for Cudy TR3000 v1

Hardware:
 - SoC: MediaTek MT7981B
 - CPU: 2x 1.3 GHz Cortex-A53
 - Flash: 128 MiB SPI NAND
 - RAM: 512 MiB
 - WLAN: 2.4 GHz, 5 GHz (MediaTek MT7976CN, 802.11ax)
 - Ethernet: 1x 10/100/1000/2500 Mbps RTL8221B WAN, 1x10/100/1000 Mbps MT7981 LAN
 - USB 3.0 port
 - Buttons: 1 Reset button, 1 slider button
 - LEDs: 1x Red, 1x White
 - Serial console: internal test points, 115200 8n1
 - Power: 5 VDC, 3 A

MAC addresses:
+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| WAN     | 80:af:ca:xx:xx:x1 | label+1   |
| LAN     | 80:af:ca:xx:xx:x0 | label     |
| WLAN 2g | 80:af:ca:xx:xx:x0 | label     |
| WLAN 5g | 82:af:ca:xx:xx:x0 |           |
+---------+-------------------+-----------+

Installation:
The installation must be done via TFTP by disassembling the router. On other occasions Cudy has distributed intermediate firmware to make installation easier, and so I recommend checking the Wiki for this device if there is a more convenient solution than the one below.

To install using TFTP:
1. Connect to UART.
2. With the router off, press the RESET button. While the router is turning on, the button should continue to be pressed for at least 5 seconds.
3. A u-boot shell will automatically open.
4. Connect to LAN and set your IP to 192.168.1.88/24. Configure a TFTP server and an OpenWrt initramfs-kernel.bin firmware file.
5. Run these steps in u-boot using the name of your file.

setenv bootfile initramfs-kernel.bin
tftpboot
bootm

6. If you can reach LuCI or SSH now, just use the sysupgrade image with the 'Keep settings' option turned off.

Signed-off-by: Luis Mita <luis@luismita.com>
6 months agoramips: Add support for D-Link DIR-2150-A1
Alan Luck [Sat, 27 Apr 2024 09:25:49 +0000 (19:25 +1000)]
ramips: Add support for D-Link DIR-2150-A1

Hardware Specification:
SoC: Mediatek MT7621DAT (MIPS1004Kc 880 MHz, dual core)
RAM: 128 MB
Storage: 128 MB NAND flash
Ethernet: 5x 10/100/1000 Mbps LAN1,LAN2,LAN3,LAN4 & WAN
Wireless: 2.4GHz: Mediatek MT7603EN up to 300Mbps (802.11b/g/n MIMO 2x2)
Wireless: 5GHz: Mediatek MT7615N up to 1733Mbps (802.11n/ac MU-MIMO 4x4)
LEDs: Power (white & amber), Internet (white & amber)
LEDs: 2.4G (White), 5Ghz (White)
Buttons: WPS, Reset

MAC Table
Label xx:xx:xx:xx:xx:EB
LAN xx:xx:xx:xx:xx:EB
2.4Ghz xx:xx:xx:xx:xx:EC
5Ghz xx:xx:xx:xx:xx:ED
WAN xx:xx:xx:xx:xx:EE

Flash instructions:
D-Link normal OEM firmware update page
1. upload OpenWRT factory.bin like any D-Link upgrade image

D-Link Recovery GUI:
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 the recovery.bin to the device

Firefox on Windows in a Private Window (incognito) works me
Internet Explorer mode in Microsoft Edge works for others
seems to not work in Linux or virtual machine on Linux for most
some see success using 'curl -v -i -F "firmware=@file.bin" 192.168.0.1'

Thanks to @frkca and @rodneyrod for testing and pushing for its creation

Signed-off-by: Alan Luck <luckyhome2008@gmail.com>
6 months agoramips: use led, function/color syntax for some tp-link archer routers
Mieczyslaw Nalewaj [Mon, 29 Apr 2024 17:10:59 +0000 (19:10 +0200)]
ramips: use led, function/color syntax for some tp-link archer routers

Setting the LED name and abandoning the label and using the
function/color syntax for some TP-Link Archer series routers:
Archer C2 v1, Archer C20 v1, Archer C20i and Archer C50 v1

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
6 months agoramips: use function/color syntax for some dlink dir routers
Mieczyslaw Nalewaj [Wed, 8 May 2024 18:32:03 +0000 (20:32 +0200)]
ramips: use function/color syntax for some dlink dir routers

Abandoning the label and using the function/color syntax for some dlink
dir series routers: dir-1960-a1, dir-2660-a1, dir-2640-a1, dir-3040-a1
and dir-3060-a1

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
6 months agoramips: rename include file to a more suitable name
Mieczyslaw Nalewaj [Sat, 27 Apr 2024 05:41:51 +0000 (07:41 +0200)]
ramips: rename include file to a more suitable name

Rename from mt7621_dlink_dir-xx60-a1.dtsi to mt7621_dlink_dir_nand_128m.dtsi
and associated group name when creating the mt7621.mk image

Co-authored-by: Alan Luck <luckyhome2008@gmail.com>
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
6 months agomediatek: correct address of MT753x switch IC
Mieczyslaw Nalewaj [Thu, 9 May 2024 11:11:16 +0000 (13:11 +0200)]
mediatek: correct address of MT753x switch IC

Continuation of commit 8b66f1a. Set the switch address on the MDIO bus to 31.
This is required for all boards currently working with the mt7530 DSA driver.

Fixes: #15419
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
6 months agodropbear: clarify DROPBEAR_MODERN_ONLY option
Konstantin Demin [Mon, 6 May 2024 13:20:16 +0000 (16:20 +0300)]
dropbear: clarify DROPBEAR_MODERN_ONLY option

don't mention SHA1 in order to not confuse users - SHA1 support is already disabled (except RSA-SHA1 signagures).

ref: https://github.com/openwrt/openwrt/issues/15281

Signed-off-by: Konstantin Demin <rockdrilla@gmail.com>
6 months agodropbear: bump to 2024.85
Konstantin Demin [Mon, 6 May 2024 13:20:16 +0000 (16:20 +0300)]
dropbear: bump to 2024.85

- update dropbear to latest stable 2024.85;
  for the changes see https://matt.ucc.asn.au/dropbear/CHANGES
- drop cherry-picked patches (merged in release 2024.84)
- refresh remaining patches

Tested-by: Stijn Segers <foss@volatilesystems.org>
Signed-off-by: Konstantin Demin <rockdrilla@gmail.com>
6 months agogeneric: 6.6: backport patch adding support for rgmii-id in stmmac-ipq806x
Christian Marangi [Thu, 9 May 2024 14:32:03 +0000 (16:32 +0200)]
generic: 6.6: backport patch adding support for rgmii-id in stmmac-ipq806x

Backport patch merged upstream for rgmii-id support in stmmac-ipq806x.

This is needed for some device that directly connets PHY to the gmac
port and require rgmii-id phy-modes.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agotools: mold: update to 2.31.0
Sean Khan [Mon, 6 May 2024 16:09:09 +0000 (12:09 -0400)]
tools: mold: update to 2.31.0

New:
- mold is now up to 10% faster when linking very large, debug
  info-enabled executables such as Blender (~1.8 GiB) or Clang (~3.8
  GiB), thanks to several improvements we've made to the string merging
  algorithm. (53ebcd8d71430140f6b17c9faf3d)
- -z start-stop-visibility=hidden is now supported so that
  linker-synthesized __start_<section-name> and __stop_<section-name>
  symbols can be completely hidden from other ELF modules. Previously,
  only -z start-stop-visibility=protected was supported. (99a5b15)
- -Bsymbolic-non-weak and -Bsymbolic-non-weak-functions options are now
  supported for compatibility with LLVM lld. Just like lld, these options
  control which symbols are exported as dynamic symbols.
  -Bsymbolic-non-weak makes the linker to export only weak symbols,
  whereas -Bsymbolic-non-weak-functions makes it to export only weak
  function symbols. (7d17aa8)

Bug fixes and compatibility improvements:

- Previously, if a linker script contains a newline character in the
  beginning four bytes of a file, it was not recognized as a linker
  script by mold. Now, mold allows newlines at the beginning of a file.
  (ea054cc)
- Under rare circumstances, the INPUT linker script command may have
  found a different file than GNU ld would. Now, mold's behavior aligns
  with GNU ld's. (163975d)
- Previously, the --repro option produced corrupted tar files. Now the
  bug has been fixed. (32c4a09)
- mold generally guarantees that its output is reproducible, meaning that
  if you run the linker with the exact same command line options and
  input files, the output is guaranteed to be bit-for-bit identical to
  the previous outputs. However, under rare circumstances, it might
  produce different output due to a bug. It's reported that this
  nondeterminism caused random crashes for some programs (#1247). This
  bug has been fixed. (6463a7c)
- mold no longer sets the address of the .text section as the entry point
  address if --entry option is not given, just like LLVM lld. (020b1a7)
- [RISC-V] __global_pointer$ symbol is now exported from executables as
  required by the processor-specific ABI. (3df7c8e)
- [ARM32] --long-plt option is now recognized as known option by mold.
  mold ignores the option, though, because the PLTs generated by our
  linker is always long. (d432e98)

Release Notes:
https://github.com/rui314/mold/releases/tag/v2.31.0

Signed-off-by: Sean Khan <datapronix@protonmail.com>
Link: https://github.com/openwrt/openwrt/pull/15403
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agorockchip: switch to kernel 6.6
Tianling Shen [Thu, 9 May 2024 08:03:08 +0000 (16:03 +0800)]
rockchip: switch to kernel 6.6

Switch to Linux kernel version 6.6 and drop configs, files and patches
for Linux 6.1.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
6 months agoipq40xx: wpj419: use existing label for SPI node
Robert Marko [Tue, 7 May 2024 12:26:03 +0000 (14:26 +0200)]
ipq40xx: wpj419: use existing label for SPI node

WPJ419 is still manually defining SPI node, so lets
convert it to use the existing upstream labels for SPI node.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: wpj419: use existing label for pinctrl node
Robert Marko [Tue, 7 May 2024 12:24:16 +0000 (14:24 +0200)]
ipq40xx: wpj419: use existing label for pinctrl node

WPJ419 is still manually defining pinctrl node, so lets
convert it to use the existing upstream labels for pinctrl node.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: wpj419: use existing label for PCIe node
Robert Marko [Tue, 7 May 2024 12:19:17 +0000 (14:19 +0200)]
ipq40xx: wpj419: use existing label for PCIe node

WPJ419 is still manually defining PCIe node, so lets
convert it to use the existing upstream labels for PCIe node and while we
are here use the -gpios suffix instead.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: use existing labels for MDIO node
Robert Marko [Tue, 7 May 2024 12:16:48 +0000 (14:16 +0200)]
ipq40xx: use existing labels for MDIO node

Some boards are still defining MDIO nodes under soc instead of using the
existing upstream labels to reference them so convert them.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: use existing labels for I2C nodes
Robert Marko [Tue, 7 May 2024 11:59:24 +0000 (13:59 +0200)]
ipq40xx: use existing labels for I2C nodes

Some boards are still defininig I2C nodes under soc instead of using the
existing upstream labels to reference them so convert them.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: use existing labels for UART nodes
Robert Marko [Tue, 7 May 2024 11:53:23 +0000 (13:53 +0200)]
ipq40xx: use existing labels for UART nodes

Some boards are still defininig UART nodes under soc instead of using the
existing upstream labels to reference them so convert them.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: ncp-hg100-cellular: drop QPIC BAM node
Robert Marko [Tue, 7 May 2024 11:46:06 +0000 (13:46 +0200)]
ipq40xx: ncp-hg100-cellular: drop QPIC BAM node

This device does not have NAND enabled at all and NAND is the only consumer
of QPIC BAM DMA, so drop the node.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: wpj419: use existing labels for DMA nodes
Robert Marko [Tue, 7 May 2024 11:45:05 +0000 (13:45 +0200)]
ipq40xx: wpj419: use existing labels for DMA nodes

WPJ419 is still manually defining dma nodes(And even some labels), so lets
convert it to use the existing upstream labels for DMA nodes.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: use existing labels for crypto node
Robert Marko [Tue, 7 May 2024 11:42:21 +0000 (13:42 +0200)]
ipq40xx: use existing labels for crypto node

Currently, a lot of boards are still not using the existing label to
reference the crypto node, so lets rectify this.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: use existing labels for prng node
Robert Marko [Tue, 7 May 2024 11:30:48 +0000 (13:30 +0200)]
ipq40xx: use existing labels for prng node

Currently, a lot of boards are still not using the existing label to
reference the prng node, so lets rectify this.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: use existing labels for watchdog node
Robert Marko [Tue, 7 May 2024 11:16:18 +0000 (13:16 +0200)]
ipq40xx: use existing labels for watchdog node

Currently, a lot of boards are still not using the existing label to
reference the watchdog node, so lets rectify this.

Link: https://github.com/openwrt/openwrt/pull/15415
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoucode: update to Git HEAD (2024-05-09)
Jo-Philipp Wich [Wed, 8 May 2024 22:16:11 +0000 (00:16 +0200)]
ucode: update to Git HEAD (2024-05-09)

cfe137be068a uci: remove incorrectly documentated reorder() parameter
e8d78a26da0c lib: introduce socket library
a0ad1d127ae6 build: fix symbol and library detection
674f65ee551d jsdoc: disable default module titles
a33d16a86493 socket: rework error handling
e2b81d869222 uloop: add documentation
953f36c96e8a socket: make socket.send() accept non-string data
f211d5ac666f ubus: fix uc_ubus_have_uloop for eloop+uloop combination
0662de64bd1f socket: add AF_PACKET socket type support
b594ff8a2841 socket: remove leftover debug code
0d823e702bfe socket: fix addrinfo() with omitted service argument

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 months agomtd-utils: nand-tuils: build and package 'nandbiterrs'
Daniel Golle [Wed, 8 May 2024 21:05:00 +0000 (22:05 +0100)]
mtd-utils: nand-tuils: build and package 'nandbiterrs'

The 'nandbiterrs' tool is useful to find out of bit error correction of
NAND is working as expected by deliberately introducing bit errors and
telling up to which number they can be corrected.

Enable build of the testing tools and package the 'nandbiterrs' tool as
part of the nand-utils package.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 months agomediatek: mt7988a.dtsi: add interrupts to GE switch PHYs
Daniel Golle [Wed, 8 May 2024 13:51:54 +0000 (14:51 +0100)]
mediatek: mt7988a.dtsi: add interrupts to GE switch PHYs

The way to register the switch MDIO bus and PHYs on the bus in upstream
Linux is more strict and requires each PHY to explicitely state the
interrupt instead of assuming it in case the 'interrupts' property in DT
is missing.

Add missing interrupts for the PHYs of the build-in 4x1GE switch of the
MT7988 SoC.

Fixes: 4354b34f6f ("generic: 6.6: sync mt7530 DSA driver with upstream")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 months agomediatek: ASUS TUF-AX6000: fix phy-handle numbering
Magnus Lindström [Wed, 1 May 2024 16:35:38 +0000 (18:35 +0200)]
mediatek: ASUS TUF-AX6000: fix phy-handle numbering

To fix issue #15304
Correct br-lan ports 1-4 so that phy-handle matches reg nr not port label.

Fixes: eb13076e77 ("mediatek: fix DTS defining mt7530 switch phys but not referencing them")
Signed-off-by: Magnus Lindström <magnus1089@hotmail.com>
6 months agogemini: Bump to kernel v6.6
Linus Walleij [Tue, 30 Apr 2024 22:00:14 +0000 (00:00 +0200)]
gemini: Bump to kernel v6.6

The Gemini works fine with kernel v6.6.

As per the example for ipq806x, drop support for anything
older than v6.6, there is no point in supporting it,
and the new DTS SoC directory just makes it hard to
maintain.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
6 months agogeneric: 6.1, 6.6: replace Airoha EN8811H PHY driver with upstream
Daniel Golle [Wed, 8 May 2024 00:48:14 +0000 (01:48 +0100)]
generic: 6.1, 6.6: replace Airoha EN8811H PHY driver with upstream

Backport driver from upcoming Linux 6.10 and put a pending fix on top
to make sure the netdev trigger offloading behaves as expected.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 months agouboot-mediatek: bpi-r2: fix root= default cmdline parameter
Daniel Golle [Tue, 7 May 2024 15:03:22 +0000 (16:03 +0100)]
uboot-mediatek: bpi-r2: fix root= default cmdline parameter

With the switch from the uImage.FIT partition parser to fitblk the
cmdline needs to be adjusted as well. Do this now as it has been
forgotten when the switch was done.

Fixes: 6368ed1ae5 ("mediatek: mt7623: phase out uImage.FIT partition parser")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 months agoodhcpd: update to Git HEAD (2024-05-08)
Christian Marangi [Tue, 7 May 2024 22:11:19 +0000 (00:11 +0200)]
odhcpd: update to Git HEAD (2024-05-08)

99dd990690bc treewide: refactor pref(erred) to preferred_lt (lifetime)
4c2b51eab368 treewide: refactor valid to valid_lt (lifetime)
3b4e06055900 router: inherit user-assigned preferred_lifetime
e164414aa184 router: limit prefix preferred_lt to valid_lt in accordance with RFC4861
a2176af7bdeb treewide: spell-fixes and new comments for extra clarification
4590efd3a2b3 treewide: normalize spaces to tabs
2edc60cb7c7a router: rename minvalid to lowest_found_lifetime
7ee72ee17bfa router: disambiguate and clarify 'no route' messages
a29882318a4c config: set RFC defaults for preferred lifetime

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agobuild: also generate the CycloneDX SBOM in imagebuilder
Florian Eckert [Wed, 24 Apr 2024 11:39:33 +0000 (13:39 +0200)]
build: also generate the CycloneDX SBOM in imagebuilder

The needed file '.packageinfo' for creating the CycloneDX SBOM in the
imagebuilder is available in the top directory of the imagebuilder and
not in the tmp directory.

For this reason, the creation of the CycloneDX SBOM file is not available
for the imagebuilder.

To fix this, it is now first checked whether the CycloneDX SBOM should be
built at all and then second decided by checking the IB variable where the
'.packageinfo' file is to be found.

With this change, it is now possible to create the CycloneDX SBOM also for
the imagebuilder as well.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
6 months agobuild: remove duplicate MAINTAINER from package-dumpinfo.mk
Florian Eckert [Wed, 17 Apr 2024 13:15:28 +0000 (15:15 +0200)]
build: remove duplicate MAINTAINER from package-dumpinfo.mk

This is an artifact and is not needed. We have already set the
information 'Maintainer:' in the '.packageinfo-*' files.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
6 months agoarm-trusted-firmware-mediatek: add ram-download bl2 images
Felix Fietkau [Tue, 7 May 2024 17:40:43 +0000 (19:40 +0200)]
arm-trusted-firmware-mediatek: add ram-download bl2 images

Support for MT7981-MT7988. Can be used for mtk_uartboot recovery

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agoinclude/trusted-firmware-a.mk: allow overriding package install template
Felix Fietkau [Tue, 7 May 2024 17:38:25 +0000 (19:38 +0200)]
include/trusted-firmware-a.mk: allow overriding package install template

Useful for special targets (e.g. RAM-only images)

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agoarmsr: armv8: enable serial console for Renesas platforms
Mathew McBride [Tue, 30 Apr 2024 02:34:37 +0000 (12:34 +1000)]
armsr: armv8: enable serial console for Renesas platforms

Support for Renesas Arm families was added in commit 1ff4f4df2301
("armsr: armv8: enable CONFIG_ARCH_RENESAS"), but this did not
enable the console/tty hardware for these SoCs, which is derived
from the SuperH family (CONFIG_SERIAL_SH_SCI).

Link: https://github.com/openwrt/openwrt/issues/15284
Signed-off-by: Mathew McBride <matt@traverse.com.au>
6 months agobase-files: armsr: add script to migrate GPIO switches on Ten64 board
Mathew McBride [Mon, 1 Apr 2024 03:44:47 +0000 (14:44 +1100)]
base-files: armsr: add script to migrate GPIO switches on Ten64 board

Due to a change in kernel 6.2, the GPIO numbers on certain
architectures (including arm64) have changed. This script
will update any defined GPIO switches to the new numbering.

See https://lists.openwrt.org/pipermail/openwrt-devel/2024-March/042448.html
for more information.

In the future, the GPIO switch mechanism will likely be
replaced with something using libgpiod.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
6 months agobase-files: armsr: number Ten64 GPIOs according to kernel version
Mathew McBride [Mon, 18 Mar 2024 02:03:55 +0000 (13:03 +1100)]
base-files: armsr: number Ten64 GPIOs according to kernel version

A change in kernel 6.2[1] caused the base numbers of GPIOs to
change significantly on some architectures like aarch64.

We have to number our GPIOs accordingly.
Ideally the board.d scripts should look through sysfs
to find the basenum (like cat "/sys/devices/platform/soc/2000000.i2c/
i2c-0/0-0076/gpio/gpiochip640/base"), but the problem is
that this occurs before modules are loaded, meaning I2C and other
runtime devices may be missing.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
[1] https://lore.kernel.org/lkml/cover.1662116601.git.christophe.leroy@csgroup.eu/T/

6 months agoarmsr: armv8: add new fsl-enetc-core module for kernel 6.6
Mathew McBride [Wed, 13 Mar 2024 01:26:12 +0000 (12:26 +1100)]
armsr: armv8: add new fsl-enetc-core module for kernel 6.6

From kernel 6.3 onwards, the fsl-enetc driver has restructured
it's common code into a 'core' module[1].

Signed-off-by: Mathew McBride <matt@traverse.com.au>
[1] https://patchwork.kernel.org/project/netdevbpf/patch/20230119160431.295833-2-vladimir.oltean@nxp.com/

6 months agoarmsr: add kernel 6.6 as a testing target
Mathew McBride [Wed, 13 Mar 2024 01:34:03 +0000 (12:34 +1100)]
armsr: add kernel 6.6 as a testing target

Add kernel 6.6 for testing.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
6 months agokernel/armsr: add config stubs and changes needed for 6.6
Mathew McBride [Sun, 17 Mar 2024 23:51:21 +0000 (10:51 +1100)]
kernel/armsr: add config stubs and changes needed for 6.6

Introduce new configuration options prompted by 6.6 (relative to 6.1).
The kernel arm64 defconfig is used as guide for 'core' options, while
video/camera/other media drivers are turned off by default.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
6 months agokernel/armsr: Restore kernel files for v6.1
Mathew McBride [Sun, 17 Mar 2024 23:48:13 +0000 (10:48 +1100)]
kernel/armsr: Restore kernel files for v6.1

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: Mathew McBride <matt@traverse.com.au>
6 months agokernel/armsr: Add configuration files and patches for v6.6
Mathew McBride [Sun, 17 Mar 2024 23:48:13 +0000 (10:48 +1100)]
kernel/armsr: Add configuration files and patches for v6.6

Based on the 6.1 files, but without any 6.6 additions.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
6 months agoipq806x: swap lan leds for Meraki MR52
Mieczyslaw Nalewaj [Tue, 7 May 2024 06:46:07 +0000 (08:46 +0200)]
ipq806x: swap lan leds for Meraki MR52

LAN Leds on Meraki MR52 are wrong and needs to be swapped to actually
reflect real ports (lan1<->lan2).

Fixes: #15388
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15410
[ wrap commit to 80 columns and improve commit title ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agogeneric: 6.1, 6.6: move accepted patches to backport folders
Daniel Golle [Tue, 7 May 2024 11:00:58 +0000 (12:00 +0100)]
generic: 6.1, 6.6: move accepted patches to backport folders

Move two accepted patches for the mt7530 DSA driver from pending to
accepted.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 months agokernel: fix tools build breakage on macos with x86
Felix Fietkau [Tue, 7 May 2024 10:22:15 +0000 (12:22 +0200)]
kernel: fix tools build breakage on macos with x86

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agotools: add more linux include files to fix x86 build on macos
Felix Fietkau [Tue, 7 May 2024 10:18:08 +0000 (12:18 +0200)]
tools: add more linux include files to fix x86 build on macos

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agomediatek: fix mt7988a pmu interrupt dts property
Felix Fietkau [Tue, 7 May 2024 10:13:00 +0000 (12:13 +0200)]
mediatek: fix mt7988a pmu interrupt dts property

Fixes profiling using perf

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agombedtls: export cmake files
Felix Fietkau [Thu, 18 Apr 2024 19:56:56 +0000 (21:56 +0200)]
mbedtls: export cmake files

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agorealtek: add RTL821X_CHIP_ID
Stijn Tintel [Fri, 26 Apr 2024 22:40:08 +0000 (01:40 +0300)]
realtek: add RTL821X_CHIP_ID

According to the Realtek SDK code, the RTL8214FC, RTL8218B and RTL8218FB
all have the same chip ID 0x6276. Let's add a constant for it, as we're
using it in more than one location.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
6 months agorealtek/rtl839x: respect phy-is-integrated property
Stijn Tintel [Fri, 26 Apr 2024 22:40:07 +0000 (01:40 +0300)]
realtek/rtl839x: respect phy-is-integrated property

Respect the phy-is-integrated property on ethernet-phy nodes.

There are RTL8393M switches where the PHYs at address 48 and 49 are
provided by an external RTL8214FC. Hardcoding them to use the internal
SerDes makes it impossible to use the ports connected to such an
external PHY. Respect the phy-is-integrated property on ethernet-phy
nodes as a first step to support such ports.

The potential impact for this should be limited to RTL8393 based
switches, and looking at the commit messages and device tree files of
the supported switches based on this SoC, the SFP and/or combo ports are
either not working (D-Link DGS-1210-52, Netgear GS750E, TP-Link
SG2452P/T1600G-52PS), use PHYs at a different address (Panasonic
SwitchM48EG PN28480K), or already have the phy-is-integrated property
set on the PHYs at address 48 and 49.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
Acked-by: Daniel Golle <daniel@makrotopia.org>
6 months agomediatek: bpi-r4: fix uci-default script for mac storage
Martin Schiller [Tue, 7 May 2024 06:32:42 +0000 (08:32 +0200)]
mediatek: bpi-r4: fix uci-default script for mac storage

There was a typo in commit 5709254690cb ("mediatek: bpi-r4: store random
MAC addresses for the BPi-R4"). Let's fix it and also add support for
the bpi-r4-poe variant.

Fixes: 5709254690cb ("mediatek: bpi-r4: store random MAC addresses for the BPi-R4")
Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agomediatek: bpi-r4: add rootwait to bootargs
Martin Schiller [Tue, 7 May 2024 06:31:24 +0000 (08:31 +0200)]
mediatek: bpi-r4: add rootwait to bootargs

In commit cd4de3251c1f ("mediatek: wait for fitblk rootfs"), the linux
6.6 files and patches has been forgotton to be fixed.

Fixes: cd4de3251c1f ("mediatek: wait for fitblk rootfs")
Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agomediatek: bpi-r2: add rootwait to bootargs
Martin Schiller [Tue, 7 May 2024 06:27:32 +0000 (08:27 +0200)]
mediatek: bpi-r2: add rootwait to bootargs

In commit cd4de3251c1f ("mediatek: wait for fitblk rootfs"), the linux
6.6 files and patches has been forgotton to be fixed.

Fixes: cd4de3251c1f ("mediatek: wait for fitblk rootfs")
Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agokernel: qca-nss-dp: update to 12.5.r2 for kernel 6.6
Kristian Skramstad [Sun, 5 May 2024 10:36:20 +0000 (12:36 +0200)]
kernel: qca-nss-dp: update to 12.5.r2 for kernel 6.6

There is a new branch 12.5.r2 for kernel 6.6, so refresh
and update patches.

Delete patch 0010-nss-dp-include-net-netdev_rx_queue.h.patch

Changes:
2024-04-04 -5bf8b91 [qca-nss-dp] Adding support for port ID 3 & 4 in MHT switch
2024-03-28 -ce1e4cf [qca-nss-dp] Use skb_queue_head_init instead of __skb_queue_head_init.
2024-03-11 -0d26366 [qca-nss-dp] Read MHT LAN port status for ErP phase2
2024-03-22 -8382f14 [qca-nss-dp] Fix compilation issues seen on ginger branch for Miami profile
2023-05-02 -09b0983 [qca-nss-dp] vp list processing for capwap
2024-02-22 -bc09a01 [qca-nss-dp] EDMA ring reset for PPE-DS
2024-03-12 -2fcb586 [qca-nss-dp] Fix the EDMA clock frequency for the mitigation timer configuration
2024-02-23 -44ba1be [qca-nss-dp] Add API to retrieve ethernet netdevs for ErP
2024-02-09 -a5979b7 [qca-nss-dp] send napi and ip checksum for VP handler
2024-01-12 -1b9cb5d qca-nss-dp: User netdev_alloc_skb_fast instead of dev_alloc_skb
2024-01-08 -a859b48 [qca-nss-dp] NAPI Budget and EDMA Rx size change for KPI improvement.
2024-01-06 -8935523 [qca-nss-dp] Offload L3, L4 checksum to hardware for ppe-vp.
2023-12-07 -bbd9547 [qca-nss-dp] Fix Compilation issues on kernel6.6
2023-10-12 -bc55f75 [qca-nss-dp]: Enable legacy SCS for PPE-VP.
2023-09-08 -6bd771f [qca-nss-dp] Invalidate secondary descriptor before use.
2023-12-19 -b143df8 [qca-nss-dp] Fixed nss_dp_hal_hw_reset functionality for ipq53xx.
2023-12-16 -7cfde1d [qca-nss-dp] Added nss_dp_hal_hw_reset functionality for ipq53xx.
2023-11-02 -70af6c2 [qca-nss-dp] Implement EDMA hang recovery support
2023-11-27 -2202b29 [qca-nss-dp] Add support for adding the link speed for the Miami's port connected to the internal Switch.
2023-12-06 -bef68a8 [qca-nss-dp] Resolve ring utilization reporting issue in EDMA driver
2023-12-06 -eaa7627 [qca-nss-dp] Add/Delete static fdb entries only for physical ports
2023-10-16 -4551d0f [qca-nss-dp]: Support HLOST_TID_override from PPE_VP path.
2023-11-09 -42ad3f3 [qca-nss-dp] Correct the NAPI poll implementation for DS Rx fill handling
2023-10-16 -dfeb7d3 [qca-nss-dp] Check for disabled ethernet port in ErP functions
2023-11-09 -42ad3f3 [qca-nss-dp] Correct the NAPI poll implementation for DS Rx fill handling
2023-10-16 -dfeb7d3 [qca-nss-dp] Check for disabled ethernet port in ErP functions
2023-09-22 -03f83d6 [qca-nss-dp] Correct the mht device flag
2023-08-18 -5efd7f4 [qca-nss-dp] Add EDMA Tx rings for MHT ports
2023-09-11 -7808ba2 [qca-nss-dp] Move DP standby code to new file and use new SSDK API
2023-09-28 -22ade1e [qca-nss-dp] : enable PPE-DS support in 6.x kernel
2023-08-28 -1943922 [qca-nss-dp] Support for bitmap based CPU selection.
2023-08-16 -dcb82a7 qca-nss-dp: 512M profile changes for Miami+Pebble
2023-09-01 -18e51f3 [qca-nss-dp] Fix tx descriptor completion error.
2023-08-28 -0bfde2d [qca-nss-dp] Changes to enable ErP mode
2023-09-05 -f1d635a [qca-nss-dp] Enable fast recycled changes in dp for kernel 6.1
2023-06-15 -55d35bd [qca-nss-dp] Tracking the full utilization of EDMA rings
2023-08-25 -89b9c19 [qca-nss-dp] Restricting the MTU as 9216 for all interfaces in DP
2023-01-03 -5098a4f [qca-nss-dp] Requeue Tx packet in case of Tx-failure.
2023-04-06 -3576dbb [qca-nss-dp] Adding tx napi with four queue per interface.
2023-08-10 -d2b6921 [qca-nss-dp] : changes to support ppe-qdisc for linux 6.x
2023-08-08 -a1941fb [qca-nss-dp] moving SET_NETDEV_DEV for all netdev to set.
2023-07-18 -74d3178 [qca-nss-dp] Reordering the CPU code and ACL index processing.
2023-06-30 -ab03139 [qca-nss-dp] Configure port level PPE offload flag in PPE
2023-06-06 -e9bb8c5 [qca-nss-dp] Rate limit the debug logs.
2023-07-18 -43afb9b [qca-nss-dp] Support Core selection for PPE mirrored packets.
2023-07-11 -92edcfd [qca-nss-dp] Add sysctl to invalidate RX secondary descriptor.

Tested and working on WAX620.

Signed-off-by: Kristian Skramstad <kristian+github@83.no>
Link: https://github.com/openwrt/openwrt/pull/15383
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agokernel: qca-ssdk: update to 12.5 for kernel 6.6
Sean Khan [Sat, 4 May 2024 21:09:08 +0000 (17:09 -0400)]
kernel: qca-ssdk: update to 12.5 for kernel 6.6

Qualcomm recently committed a new branch (12.5.r2) targeting kernel
6.6. This lets us clean up a few patches particularly the one for
"C22/C45" mdio.

A quick way to see what changed for IPQ807x/6018 was to list the files produced
during build (**/*.o), replace the extension with ".c", and doing a
`git log`.

Filtering from those commits, ones of particular interest are listed
below:

```
2024-04-16 - 0d8f30aa - fix compile issue on hk with linux style build
2024-01-29 - 636464f7 - update the check for port link notify
2024-01-24 - 30c10e7f - enable and disable loopback for xgmac to fix qm stuck issue
2024-01-15 - b6ea10aa - update the the APIs to access switch
2024-01-08 - a1687502 - Disable Tx bridge mac before power off the PHY
2024-01-07 - 3eafb613 - support led configure for malibu phy
2024-01-07 - 5c1af60d - remove phy type check from mac reset when mode switch
2023-12-17 - 79d0b1e8 - remove the PHY access APIs in ssdk_plat.c
2023-12-16 - b2953740 - Update mii read/write functions
2023-12-11 - 37f2eac3 - add port id check for fdb entry
2023-12-11 - d040ca4d - support mdio clause45 on kernel6.6
2023-12-07 - 11494fbc - use barrier mw() during access fdb entry table
2023-12-03 - 8e40a284 - fix build warnings on kernel6.6
2023-11-10 - 10aa0a02 - change speed value when call ssdk_port_link_notify
2023-11-06 - ee4c4a60 - Update mac bitmap value of L3 table on MAC delete
2023-11-03 - 7cd27d39 - support 10G phy common feature
2023-10-30 - 383cc0d2 - fix mactype and mux select issue
2023-10-24 - decf534a - support autoneg status query on force port
2023-10-11 - 111d574e - move ssdk_led_init to regi_init
2023-10-08 - 6b14c142 - the combo port also need to parse SFP pins
2023-10-03 - fb2e0401 - fix port5 interface mode switch issue in erp case
```

Verified with users on QNAP 301W, NBG7815, and myself on Dynalink
DL-WRX36 that everything is functional, including LEDS.

Signed-off-by: Sean Khan <datapronix@protonmail.com>
Link: https://github.com/openwrt/openwrt/pull/15379
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agorockchip: add kernel 6.6 as testing kernel
Antonio Flores [Fri, 19 Apr 2024 17:44:18 +0000 (13:44 -0400)]
rockchip: add kernel 6.6 as testing kernel

Add kernel 6.6 as testing kernel

Signed-off-by: Antonio Flores <antflores627@gmail.com>
6 months agokernel: add missing kernel 6.6 symbols
Antonio Flores [Fri, 19 Apr 2024 17:41:26 +0000 (13:41 -0400)]
kernel: add missing kernel 6.6 symbols

Add missing kernel 6.6 symbols

Signed-off-by: Antonio Flores <antflores627@gmail.com>
6 months agorockchip: refresh config 6.6
Antonio Flores [Fri, 19 Apr 2024 17:38:57 +0000 (13:38 -0400)]
rockchip: refresh config 6.6

Refresh config 6.6 (make kernel_oldconfig).

Signed-off-by: Antonio Flores <antflores627@gmail.com>
6 months agorockchip: refresh 6.6 patches
Antonio Flores [Fri, 19 Apr 2024 17:12:01 +0000 (13:12 -0400)]
rockchip: refresh 6.6 patches

Refresh kernel 6.6 patches.
Removed backpored patches.

Signed-off-by: Antonio Flores <antflores627@gmail.com>
6 months agokernel/rockchip: Restore kernel files for v6.1
Antonio Flores [Fri, 19 Apr 2024 16:49:23 +0000 (12:49 -0400)]
kernel/rockchip: Restore kernel files for v6.1

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: Antonio Flores <antflores627@gmail.com>
6 months agokernel/rockchip: Create kernel files for v6.6 (from v6.1)
Antonio Flores [Fri, 19 Apr 2024 16:49:23 +0000 (12:49 -0400)]
kernel/rockchip: Create kernel files for v6.6 (from v6.1)

This is an automatically generated commit.

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

Signed-off-by: Antonio Flores <antflores627@gmail.com>
6 months agolibbpf: Update to v1.4.1
Tony Ambardar [Wed, 3 Apr 2024 22:31:29 +0000 (15:31 -0700)]
libbpf: Update to v1.4.1

Update to the latest upstream release to include recent improvements and
bugfixes.

Link: https://github.com/libbpf/libbpf/releases/tag/v1.4.1
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
6 months agokselftests-bpf: update for kernel 6.6
Tony Ambardar [Sun, 5 May 2024 23:11:02 +0000 (16:11 -0700)]
kselftests-bpf: update for kernel 6.6

Enable building multiple test programs and related kernel modules, with
initial support for the bpf_testmod.ko module required since kernel 6.4.
Explicitly disable LTO and clean up makefile variables and formatting.

Fix a musl-related build failure by adding a kernel 6.6 patch:

     360-selftests-bpf-portability-of-unprivileged-tests.patch

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
6 months agomediatek: bpi-r4: add ethernet aliases to DT
Daniel Golle [Mon, 6 May 2024 15:37:24 +0000 (16:37 +0100)]
mediatek: bpi-r4: add ethernet aliases to DT

Adding the aliases also for Linux 6.6 was forgotten and is required for
U-Boot to hand down persistent MAC addresses to Linux.

Fixes: 5709254690 ("mediatek: bpi-r4: store random MAC addresses for the BPi-R4")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 months agouboot-envtools: add env settings for ubnt,unifi-6-lr-v2
Joel Low [Tue, 7 Nov 2023 14:05:14 +0000 (22:05 +0800)]
uboot-envtools: add env settings for ubnt,unifi-6-lr-v2

This has been tested on two of my Unifi 6 LR v2s:

```bash
$ fw_printenv # before
Cannot parse config file '/etc/fw_env.config': No such file or directory
$ cat /etc/fw_env.config
/dev/mtd3 0x0000 0x1000 0x1000 1
$ fw_printenv
arch=arm
baudrate=115200
board=mt7622_evb
board_name=mt7622_evb
bootcmd=bootubnt
bootdelay=3
bootfile=uImage
cpu=armv7
device_model=U6-LR
ethact=mtk_eth
ethaddr=<redacted>
ethcard=AQR112C
ipaddr=<redacted>
is_default=true
loadaddr=0x5007FF28
macaddr=<redacted>
serverip=<redacted>
soc=mt7622
stderr=serial
stdin=serial
stdout=serial
vendor=mediatek
is_ble_stp=true
```

I had to reverse-engineer the working settings above to the UCI script.

Signed-off-by: Joel Low <joel@joelsplace.sg>
Link: https://github.com/openwrt/openwrt/pull/13897
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agodropbear: use ssh-keygen as an alias for dropbearkey
Sergey Ponomarev [Sun, 3 Dec 2023 16:11:38 +0000 (18:11 +0200)]
dropbear: use ssh-keygen  as an alias for dropbearkey

The DropBear's dropbearkey supports limited set of arguments of
OpenSSH ssh-keygen:  -t, -q -N -Y
After the change you can generate a key with the same command.
Still many features of the original OpenSSH ssh-keygen are absent in
the dropbearkey.
If it's needed then users should install openssh-keygen package that
will replace the /usr/bin/ssh-keygen with the full version.

Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/14174
[ wrap commit description to 80 columns ]
Link: https://github.com/openwrt/openwrt/pull/14174
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agoipq40xx: Enable the Engenius EAP1300
Corey Minyard [Fri, 3 May 2024 13:14:31 +0000 (08:14 -0500)]
ipq40xx: Enable the Engenius EAP1300

Now that DSA is enabled and the MAC addresses are set properly, we can
use it.

Signed-off-by: Corey Minyard <minyard@acm.org>
Link: https://github.com/openwrt/openwrt/pull/15358
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agoipq40xx: Properly set MAC addresses for the EAP1300
Corey Minyard [Fri, 3 May 2024 13:12:38 +0000 (08:12 -0500)]
ipq40xx: Properly set MAC addresses for the EAP1300

The code that was there was just taking whatever was left in the
registers, which was just wrong.  Set the addresses using the value from
the u-boot environment, the same way the OEM firmware does.

Signed-off-by: Corey Minyard <minyard@acm.org>
Link: https://github.com/openwrt/openwrt/pull/15358
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agoipq40xx: convert Engenius EAP1300 to DSA
Corey Minyard [Wed, 1 May 2024 20:43:16 +0000 (15:43 -0500)]
ipq40xx: convert Engenius EAP1300 to DSA

This commit converts the EAP1300 to DSA setup.

Signed-off-by: Corey Minyard <minyard@acm.org>
Link: https://github.com/openwrt/openwrt/pull/15358
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agoipq40xx: Enable NVMEM_U_BOOT_ENV config
Corey Minyard [Thu, 2 May 2024 19:11:04 +0000 (14:11 -0500)]
ipq40xx: Enable NVMEM_U_BOOT_ENV config

It's needed to get the MAC addresses for the Engenius EAP1300.

Signed-off-by: Corey Minyard <minyard@acm.org>
Link: https://github.com/openwrt/openwrt/pull/15358
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agoipq4019: fix even more wrong reference to USB node
Christian Marangi [Sun, 5 May 2024 17:42:52 +0000 (19:42 +0200)]
ipq4019: fix even more wrong reference to USB node

Commit 6136ebabc5cb ("ipq40xx: 6.6: fix DTS to use reference for usb
node") fixed only some of the reference to USB node but many others were
still using the old broken usb3/usb2. Fix every reference to those node
and move them on using the tag name.

Fixes: 6136ebabc5cb ("ipq40xx: 6.6: fix DTS to use reference for usb node")
Link: https://github.com/openwrt/openwrt/pull/15392
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agomediatek: fix broken PCIe caused by update to 6.6.30
Rany Hany [Sun, 5 May 2024 22:39:58 +0000 (01:39 +0300)]
mediatek: fix broken PCIe caused by update to 6.6.30

The patch "710-pci-pcie-mediatek-add-support-for-coherent-DMA.patch"
makes use of "syscon_regmap_lookup_by_phandle" which requires that
"syscon" be in the compatible list.

Without this patch, PCIe probe will fail with the following error:

[    1.287467] mtk-pcie 1a143000.pcie: host bridge /pcie@1a143000 ranges:
[    1.294019] mtk-pcie 1a143000.pcie: Parsing ranges property...
[    1.299901] mtk-pcie 1a143000.pcie:      MEM 0x0020000000..0x0027ffffff -> 0x0020000000
[    1.307954] mtk-pcie 1a143000.pcie: missing hifsys node
[    1.313185] mtk-pcie: probe of 1a143000.pcie failed with error -22

Fixes: 4c6e9a9943 ("kernel: bump 6.6 to 6.6.30")
Signed-off-by: Rany Hany <rany_hany@riseup.net>
6 months agouboot-envtools: filogic: add support for BananaPi R4 PoE
Martin Schiller [Thu, 2 May 2024 07:00:58 +0000 (09:00 +0200)]
uboot-envtools: filogic: add support for BananaPi R4 PoE

This adds support for the bpi-r4 variant with internal 2.5G PHY and
additional ethernet port instead of second sfp.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agouboot-mediatek: bpi-r4: add support for 2.5GE PoE variant
Martin Schiller [Tue, 30 Apr 2024 12:55:28 +0000 (14:55 +0200)]
uboot-mediatek: bpi-r4: add support for 2.5GE PoE variant

This adds support for the bpi-r4 variant with internal 2.5G PHY and
additional ethernet port instead of second sfp.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agomediatek: bpi-r4: add support for 2.5GE PoE variant
Martin Schiller [Tue, 30 Apr 2024 08:50:51 +0000 (10:50 +0200)]
mediatek: bpi-r4: add support for 2.5GE PoE variant

This adds support for the bpi-r4 variant with internal 2.5G PHY and
additional ethernet port instead of second sfp.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agomediatek: bpi-r4: dts: move common parts to dtsi file
Martin Schiller [Tue, 30 Apr 2024 08:16:21 +0000 (10:16 +0200)]
mediatek: bpi-r4: dts: move common parts to dtsi file

Move the common parts of the mt7988a-bananapi-bpi-r4.dts to a dtsi file.
This is done to prepare support for the 2.5G Ethernet Variant.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
6 months agolibxml2: update to 2.12.6
Pascal Ernster [Wed, 1 May 2024 19:04:18 +0000 (21:04 +0200)]
libxml2: update to 2.12.6

Release Notes:
https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.12.6

Changelog (taken from the release notes):
- Regressions
  - parser: Fix detection of duplicate attributes in XML namespace
  - xmlreader: Fix xmlTextReaderConstEncoding
  - html: Fix htmlCreatePushParserCtxt with encoding
  - xmllint: Return error code if XPath returns empty nodeset

Compile-tested: x86_x64, Q35 VM, OpenWRT SNAPSHOT r26135-a8bfdf2ed4d9
Run-tested: x86_x64, Q35 VM, OpenWRT SNAPSHOT r26135-a8bfdf2ed4d9
Signed-off-by: Pascal Ernster <git@hardfalcon.net>
6 months agox86: generic: config-6.6: add/remove default syms
John Audia [Thu, 2 May 2024 20:05:41 +0000 (16:05 -0400)]
x86: generic: config-6.6: add/remove default syms

Add new default and remove deprecated symbol introduced by 6.6.30[1]

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

Signed-off-by: John Audia <therealgraysky@proton.me>
6 months agokernel: bump 6.6 to 6.6.30
John Audia [Thu, 2 May 2024 19:40:57 +0000 (15:40 -0400)]
kernel: bump 6.6 to 6.6.30

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

Removed upstreamed:
ipq806x/patches-6.6/130-mtd-rawnand-qcom-Fix-broken-misc_cmd_type-in-exec_op.patch[1]

Manually rebased:
generic/pending-6.6/760-net-core-add-optional-threading-for-backlog-processi.patch
mediatek/patches-6.6/941-arm64-dts-mt7986-move-cpuboot-in-a-dedicated-node.patch

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.30&id=87fc30db0a2bb300de289dae7c5579cc27a3cbbd

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>
6 months agokernel: fix corrupted ethernet header on bridge multicast-to-unicast
Felix Fietkau [Sun, 5 May 2024 18:48:23 +0000 (20:48 +0200)]
kernel: fix corrupted ethernet header on bridge multicast-to-unicast

Fixes: 45a8e962a591 ("kernel: fix crash with multicast-to-unicast and fraglist GRO")
Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 months agotools: pkgconf: provide prefix for host and hostpkg stagind directory
Christian Marangi [Thu, 11 Apr 2024 15:02:45 +0000 (17:02 +0200)]
tools: pkgconf: provide prefix for host and hostpkg stagind directory

Some package might require to fix their pkg-config file to point to host
or hostpkg file. This is the case for glib2 library that provides with
pkg-config variables, tools to generates files from xml. Those tools
should use the host binary instead of the targets one to correctly build
packages that makes use of such tools.

Link: https://github.com/openwrt/openwrt/pull/15134
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
6 months agoath79: refresh patches
Robert Marko [Sun, 5 May 2024 08:38:37 +0000 (10:38 +0200)]
ath79: refresh patches

CI is telling us that we need to refresh the patches, so lets do so.

Link: https://github.com/openwrt/openwrt/pull/15382
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: merge DTS for Linksys WHW03 V1 and V2
Rodrigo Balerdi [Fri, 3 May 2024 05:34:53 +0000 (02:34 -0300)]
ipq40xx: merge DTS for Linksys WHW03 V1 and V2

No changes other than the merging itself are intended in this commit.

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15345
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: clean up Linksys WHW03 V2 DTS
Rodrigo Balerdi [Tue, 30 Apr 2024 23:47:10 +0000 (20:47 -0300)]
ipq40xx: clean up Linksys WHW03 V2 DTS

Apply stylistic changes to facilitate DTS merging with WHW03 V1.

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15345
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 months agoipq40xx: add support for Linksys WHW03 V1
Rodrigo Balerdi [Thu, 11 Apr 2024 15:14:19 +0000 (12:14 -0300)]
ipq40xx: add support for Linksys WHW03 V1

Hardware:
=========
SOC:             Qualcomm IPQ4019
WiFi 1:          QCA4019 IEEE 802.11b/g/n
WiFi 2:          QCA4019 IEEE 802.11a/n/ac
WiFi 3:          QCA9886 IEEE 802.11a/n/ac
Bluetooth:       Qualcomm CSR8510 (A10)
Zigbee:          Silicon Labs EM3581 NCP + Skyworks SE2432L
Ethernet:        Qualcomm Atheros QCA8072 (2-port)
Flash:           Samsung KLM4G1FEPD (4GB eMMC)
RAM (NAND):      512MB
LED Controller:  NXP PCA9633 (I2C)
Buttons:         Single reset button (GPIO).

Ethernet:
=========
The device has 2 ethernet ports, configured as follows by default:
- left port: WAN
- right port: LAN

Wifi:
=====
The Wifi radios are turned off by default. To configure the router,
you will need to connect your computer to the LAN port of the device.

Bluetooth and Zigbee:
=====================
Configuration included but not tested.

Storage:
========
For compatibility with stock firmware, all of OpenWrt runs in a 136 MiB
eMMC partition (of which there are two copies, see below). You can also
use partition /dev/mmcblk0p19 "syscfg" (3.4 GiB) any way you see fit.
During very limited tests, stock firmware did not mount this partition.
However, backing up its stock content before use is recommended anyway.

Firmware:
=========
The device uses a dual firmware mechanism: it automatically reverts to
the previous firmware after 3 failed boot attempts.

You can switch to the inactive firmware copy by changing the "boot_part"
U-Boot environment variable. You can also do it by turning on the device
for a couple of seconds and then back off, 3 times in a row.

Installation:
=============
OpenWrt's "factory" image can be installed via the stock web UI:
1. Login to the UI. (The default password is printed on the label.)
2. Enter support mode by clicking on the "CA" link at the bottom.
3. Click "Connectivity", "Choose file", "Start", and ignore warnings.

This port is based on work done by flipy (https://github.com/flipy).

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15345
Signed-off-by: Robert Marko <robimarko@gmail.com>