openwrt/staging/dangole.git
9 months agokernel: kmod-crypto-gf128: Fix build with kernel 6.6
Hauke Mehrtens [Wed, 13 Mar 2024 19:24:23 +0000 (20:24 +0100)]
kernel: kmod-crypto-gf128: Fix build with kernel 6.6

The gf128mul.ko module was moved in kernel 6.2:
https://git.kernel.org/linus/61c581a46a9668747d355436bd4b2505594539bd

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
9 months agokernel: kmod-crypto-user: Add missing dependency
Hauke Mehrtens [Wed, 13 Mar 2024 17:09:22 +0000 (18:09 +0100)]
kernel: kmod-crypto-user: Add missing dependency

The algif_rng.ko kernel module depends on the rng.ko kernel module with
kernel 6.6 when compiling for MIPS malta.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
9 months agofirmware: intel-microcode: update to 20240312
Christian Lamparter [Thu, 14 Mar 2024 06:13:37 +0000 (07:13 +0100)]
firmware: intel-microcode: update to 20240312

Debian changelog:

intel-microcode (3.20240312.1) unstable; urgency=medium

  * New upstream microcode datafile 20240312 (closes: #1066108)
    - Mitigations for INTEL-SA-INTEL-SA-00972 (CVE-2023-39368):
      Protection mechanism failure of bus lock regulator for some Intel
      Processors may allow an unauthenticated user to potentially enable
      denial of service via network access.
    - Mitigations for INTEL-SA-INTEL-SA-00982 (CVE-2023-38575):
      Non-transparent sharing of return predictor targets between contexts in
      some Intel Processors may allow an authorized user to potentially
      enable information disclosure via local access.  Affects SGX as well.
    - Mitigations for INTEL-SA-INTEL-SA-00898 (CVE-2023-28746), aka RFDS:
      Information exposure through microarchitectural state after transient
      execution from some register files for some Intel Atom Processors and
      E-cores of Intel Core Processors may allow an authenticated user to
      potentially enable information disclosure via local access.  Enhances
      VERW instruction to clear stale register buffers.  Affects SGX as well.
      Requires kernel update to be effective.
    - Mitigations for INTEL-SA-INTEL-SA-00960 (CVE-2023-22655), aka TECRA:
      Protection mechanism failure in some 3rd and 4th Generation Intel Xeon
      Processors when using Intel SGX or Intel TDX may allow a privileged
      user to potentially enable escalation of privilege via local access.
      NOTE: effective only when loaded by firmware.  Allows SMM firmware to
      attack SGX/TDX.
    - Mitigations for INTEL-SA-INTEL-SA-01045 (CVE-2023-43490):
      Incorrect calculation in microcode keying mechanism for some Intel
      Xeon D Processors with Intel SGX may allow a privileged user to
      potentially enable information disclosure via local access.
  * Fixes for other unspecified functional issues on many processors
  * Updated microcodes:
    sig 0x00050653, pf_mask 0x97, 2023-07-28, rev 0x1000191, size 36864
    sig 0x00050656, pf_mask 0xbf, 2023-07-28, rev 0x4003605, size 38912
    sig 0x00050657, pf_mask 0xbf, 2023-07-28, rev 0x5003605, size 37888
    sig 0x0005065b, pf_mask 0xbf, 2023-08-03, rev 0x7002802, size 30720
    sig 0x00050665, pf_mask 0x10, 2023-08-03, rev 0xe000015, size 23552
    sig 0x000506f1, pf_mask 0x01, 2023-10-05, rev 0x003e, size 11264
    sig 0x000606a6, pf_mask 0x87, 2023-09-14, rev 0xd0003d1, size 307200
    sig 0x000606c1, pf_mask 0x10, 2023-12-05, rev 0x1000290, size 299008
    sig 0x000706a1, pf_mask 0x01, 2023-08-25, rev 0x0040, size 76800
    sig 0x000706a8, pf_mask 0x01, 2023-08-25, rev 0x0024, size 76800
    sig 0x000706e5, pf_mask 0x80, 2023-09-14, rev 0x00c4, size 114688
    sig 0x000806c1, pf_mask 0x80, 2023-09-13, rev 0x00b6, size 111616
    sig 0x000806c2, pf_mask 0xc2, 2023-09-13, rev 0x0036, size 98304
    sig 0x000806d1, pf_mask 0xc2, 2023-09-13, rev 0x0050, size 104448
    sig 0x000806ec, pf_mask 0x94, 2023-07-16, rev 0x00fa, size 106496
    sig 0x000806f8, pf_mask 0x87, 2024-01-03, rev 0x2b000590, size 579584
    sig 0x000806f7, pf_mask 0x87, 2024-01-03, rev 0x2b000590
    sig 0x000806f6, pf_mask 0x87, 2024-01-03, rev 0x2b000590
    sig 0x000806f5, pf_mask 0x87, 2024-01-03, rev 0x2b000590
    sig 0x000806f4, pf_mask 0x87, 2024-01-03, rev 0x2b000590
    sig 0x00090661, pf_mask 0x01, 2023-09-26, rev 0x0019, size 20480
    sig 0x00090672, pf_mask 0x07, 2023-09-19, rev 0x0034, size 224256
    sig 0x00090675, pf_mask 0x07, 2023-09-19, rev 0x0034
    sig 0x000b06f2, pf_mask 0x07, 2023-09-19, rev 0x0034
    sig 0x000b06f5, pf_mask 0x07, 2023-09-19, rev 0x0034
    sig 0x000906a3, pf_mask 0x80, 2023-09-19, rev 0x0432, size 222208
    sig 0x000906a4, pf_mask 0x80, 2023-09-19, rev 0x0432
    sig 0x000906c0, pf_mask 0x01, 2023-09-26, rev 0x24000026, size 20480
    sig 0x000906e9, pf_mask 0x2a, 2023-09-28, rev 0x00f8, size 108544
    sig 0x000906ea, pf_mask 0x22, 2023-07-26, rev 0x00f6, size 105472
    sig 0x000906ec, pf_mask 0x22, 2023-07-26, rev 0x00f6, size 106496
    sig 0x000906ed, pf_mask 0x22, 2023-07-27, rev 0x00fc, size 106496
    sig 0x000a0652, pf_mask 0x20, 2023-07-16, rev 0x00fa, size 97280
    sig 0x000a0653, pf_mask 0x22, 2023-07-16, rev 0x00fa, size 97280
    sig 0x000a0655, pf_mask 0x22, 2023-07-16, rev 0x00fa, size 97280
    sig 0x000a0660, pf_mask 0x80, 2023-07-16, rev 0x00fa, size 97280
    sig 0x000a0661, pf_mask 0x80, 2023-07-16, rev 0x00fa, size 96256
    sig 0x000a0671, pf_mask 0x02, 2023-09-14, rev 0x005e, size 108544
    sig 0x000b0671, pf_mask 0x32, 2023-12-14, rev 0x0122, size 215040
    sig 0x000b06a2, pf_mask 0xe0, 2023-12-07, rev 0x4121, size 220160
    sig 0x000b06a3, pf_mask 0xe0, 2023-12-07, rev 0x4121
    sig 0x000b06e0, pf_mask 0x11, 2023-09-25, rev 0x0015, size 138240
  * New microcodes:
    sig 0x000a06a4, pf_mask 0xe6, 2024-01-03, rev 0x001c, size 136192
    sig 0x000b06a8, pf_mask 0xe0, 2023-12-07, rev 0x4121, size 220160
    sig 0x000c06f2, pf_mask 0x87, 2023-11-20, rev 0x21000200, size 549888
    sig 0x000c06f1, pf_mask 0x87, 2023-11-20, rev 0x21000200
  * source: update symlinks to reflect id of the latest release, 20240312
  * changelog, debian/changelog: fix typos

 -- Henrique de Moraes Holschuh <hmh@debian.org>  Tue, 12 Mar 2024 20:28:17 -0300

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
9 months agomxs: switch default kernel to 6.1
Zoltan HERPAI [Thu, 14 Mar 2024 13:21:17 +0000 (14:21 +0100)]
mxs: switch default kernel to 6.1

The testing kernel has been available since Jul/2023, let's switch
to it by default.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
9 months agoramips: 5.15: delete remaining files
Nick Hainke [Wed, 13 Mar 2024 22:49:32 +0000 (23:49 +0100)]
ramips: 5.15: delete remaining files

Remove the remaining configuration entries that were omitted in the
previous commit.

Fixes: 1576474f55e9 ("ramips: switch to 6.1 kernel")
Signed-off-by: Nick Hainke <vincent@systemli.org>
9 months agomediatek: Add support for GL.iNet X3000 (Spitz AX) and XE3000 (Puli AX)
Jean Thomas [Thu, 9 Nov 2023 10:28:45 +0000 (11:28 +0100)]
mediatek: Add support for GL.iNet X3000 (Spitz AX) and XE3000 (Puli AX)

The GL.iNet X3000 and XE3000 are Wi-Fi 6 5G cellular routers, based on
MediaTek MT7981A SoC. The XE3000 is the same device as the X3000,
except for an additional battery.

Specifications:
 - SoC: Filogic 820 MT7981A (1.3GHz)
 - RAM: DDR4 512M
 - Flash: eMMC 8G, MicroSD card slot
 - WiFi: 2.4GHz and 5GHz with 6 antennas
 - Ethernet:
   - 1x LAN (10/100/1000M)
   - 1x WAN (10/100/1000/2500M)
 - 5G: Quectel RM520N-GL with two nano-SIM card slots
 - USB: 1x USB 2.0 port
 - UART:
   - 3.3V, TX, RX, GND / 115200 8N1

MAC addresses as verified by OEM firmware:
vendor   OpenWrt    address     source
WAN      eth0       label       factory 0x0a (label)
LAN      eth1       label + 1
2g       phy0-ap0   label + 2   factory 0x04
5g       phy1-ap0   label + 3

Installation via U-Boot rescue:
1. Press and hold reset button while booting the device
2. Wait for the Internet led to blink 5 times
3. Release reset button
4. The rescue page is accessible via http://192.168.1.1
5. Select the OpenWrt sysupgrade image and start upgrade
6. Wait for the router to flash new firmware and reboot

Revert to stock firmware:
1. Download the stock firmware from GL.iNet website
2. Use the method explained above to flash the stock firmware

Switch the modem network port between PCIe and USB interfaces:
1. Connect to the AT commands (/dev/ttyUSB2) port using
e.g. minicom: minicom -D /dev/ttyUSB2
2. Check the current modem mode with 'AT+QCFG="data_interface"':
  - 0,0 indicates that the network port uses the USB interface
  - 1,0 indicates that the network port uses the PCIe interface
3. Switch the active interface with:
  - 'AT+QCFG="data_interface",0,0' to use the USB interface
  - 'AT+QCFG="data_interface",1,0' to use the PCIe interface
4. Reboot

Signed-off-by: Jean Thomas <jean.thomas@wifirst.fr>
9 months agomediatek: mt7981: pinctrl: add additional emmc groups
Jean Thomas [Thu, 7 Dec 2023 15:18:02 +0000 (16:18 +0100)]
mediatek: mt7981: pinctrl: add additional emmc groups

Add new emmc groups in the pinctrl driver for the
MediaTek MT7981 SoC:
* emmc reset, with pin 15.
* emmc 4-bit bus-width, with pins 16 to 19, and 24 to 25.
* emmc 8-bit bus-width, with pins 16 to 25.

The existing emmc_45 group is kept for legacy reasons, even
if this is the union of emmc_reset and emmc_8 groups.

Signed-off-by: Jean Thomas <jean.thomas@wifirst.fr>
9 months agomediatek: mt7981: pinctrl: add additional uart group
Jean Thomas [Thu, 7 Dec 2023 15:16:30 +0000 (16:16 +0100)]
mediatek: mt7981: pinctrl: add additional uart group

Add uart1_3 (pins 26, 27) group to the pinctrl driver for the
MediaTek MT7981 SoC.

Signed-off-by: Jean Thomas <jean.thomas@wifirst.fr>
9 months agogeneric: mtk_eth_soc: fix PPE hanging issue
Daniel Golle [Wed, 13 Mar 2024 18:44:52 +0000 (18:44 +0000)]
generic: mtk_eth_soc: fix PPE hanging issue

A patch to resolve an issue was found in MediaTek's GPL-licensed SDK:
In the mtk_ppe_stop() function, the PPE scan mode is not disabled before
disabling the PPE. This can potentially lead to a hang during the process
of disabling the PPE.

Without this patch, the PPE may experience a hang during the reboot test.

Reference: https://git01.mediatek.com/plugins/gitiles/openwrt/feeds/mtk-openwrt-feeds/+/b40da332dfe763932a82f9f62a4709457a15dd6c

Suggested-by: Bc-bocun Chen <bc-bocun.chen@mediatek.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agogeneric: 5.15: mtk_eth_soc: backport fix for hang on link up
Daniel Golle [Wed, 13 Mar 2024 18:43:28 +0000 (18:43 +0000)]
generic: 5.15: mtk_eth_soc: backport fix for hang on link up

Backport commit faa5f17fe2 ("kernel: mtk_eth_soc: release
MAC_MCR_FORCE_LINK only when MAC is up") to Linux 5.15 as well.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agodnsmasq: reset PKG_RELEASE
Robert Marko [Wed, 13 Mar 2024 11:47:31 +0000 (12:47 +0100)]
dnsmasq: reset PKG_RELEASE

dnsmasq was recently updated to 2.90, but PKG_RELEASE was not reset to 1.

Fixes: 838a27f64f56 ("dnsmasq: version 2.90")
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agoath79: add missing kernel config symbols
Shiji Yang [Wed, 13 Mar 2024 06:27:08 +0000 (14:27 +0800)]
ath79: add missing kernel config symbols

Refresh kernel configs to add the missing symbols.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
9 months agoath79: remove obsolete 5.15 kernel support
Shiji Yang [Wed, 13 Mar 2024 06:27:08 +0000 (14:27 +0800)]
ath79: remove obsolete 5.15 kernel support

The 5.15 kenel config file, patches and version switches will be
removed in this patch. We will introduce kernel 6.6 support soon.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
9 months agoath79: switch default kernel to 6.1
Shiji Yang [Wed, 13 Mar 2024 06:27:08 +0000 (14:27 +0800)]
ath79: switch default kernel to 6.1

The 6.1 kernel has been tested for over half a year.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
9 months agolibevent2: make cmake use relative imported path
Liu Dongmiao [Tue, 12 Mar 2024 06:48:08 +0000 (06:48 +0000)]
libevent2: make cmake use relative imported path

libevent2's cmake use absolute path, then cmake cannot find it when cross compiling:

```
-- Found libevent include directory: /builder/staging_dir/target-mips_24kc_musl/usr/include
-- Found libevent component: /builder/staging_dir/target-mips_24kc_musl/usr/lib/libevent_core.so
-- Found libevent component: /builder/staging_dir/target-mips_24kc_musl/usr/lib/libevent_extra.so
-- Found libevent component: /builder/staging_dir/target-mips_24kc_musl/usr/lib/libevent_openssl.so
-- Found libevent 2.1.12 in /builder/staging_dir/target-mips_24kc_musl/usr
CMake Error at /builder/staging_dir/target-mips_24kc_musl/usr/lib/cmake/libevent/LibeventTargets-shared.cmake:102 (message):
  The imported target "libevent::core" references the file

     "/usr/lib/libevent_core-2.1.so.7.0.1"

  but this file does not exist.  Possible reasons include:

  * The file was deleted, renamed, or moved to another location.

  * An install or uninstall procedure did not complete successfully.

  * The installation package was faulty and contained

     "/builder/staging_dir/target-mips_24kc_musl/usr/lib/cmake/libevent/LibeventTargets-shared.cmake"

  but not all the files it references.

Call Stack (most recent call first):
  /builder/staging_dir/target-mips_24kc_musl/usr/lib/cmake/libevent/LibeventConfig.cmake:168 (include)
  CMakeLists.txt:34 (find_package)
```

This patch make cmake use relative imported path, so it can find libevent.

Signed-off-by: Liu Dongmiao <liudongmiao@gmail.com>
9 months agoramips: add support for Z-ROUTER ZR-2660
Mikhail Zhilkin [Sat, 2 Mar 2024 19:58:40 +0000 (19:58 +0000)]
ramips: add support for Z-ROUTER ZR-2660

This commit adds support for Z-ROUTER ZR-2660 (also known as Routerich
AX1800) wireless WiFi 6 router.

Specification
-------------
- SoC       : MediaTek MT7621AT, MIPS, 880 MHz
- RAM       : 256 MiB
- Flash     : NAND 128 MiB (AMD/Spansion S34ML01G2)
- WLAN      :
  - 2.4 GHz : MediaTek MT7905D/MT7975 (14c3:7916), b/g/n/ax, MIMO 2x2
  - 5 GHz   : MediaTek MT7915E (14c3:7915), a/n/ac/ax, MIMO 2x2
- Ethernet  : 10/100/1000 Mbps x4 (1x WAN, 3x LAN)
- USB       : 1x 2.0
- UART      : 3.3V, 115200n8, pins are silkscreened on the pcb
- Buttons   : 1x Reset
- LEDs      : 1x WiFi 2.4 GHz (green)
              1x WiFi 5 GHz (green)
              1x LAN (green)
              1x WAN (green)
              1x WAN no-internet (red)
- Power     : 12 VDC, 1 A

Installation
------------
1. Run tftp server on your PC (IP: 192.168.2.2) and put OpenWrt initramfs
   image (initramfs.bin) to the tftp root dir
2. Open the following link in the browser to enable telnet:
http://192.168.2.1/cgi-bin/telnet_ssh
3. Connect to the router (default IP: 192.168.2.1) using telnet shell
   (credentials - user:admin)
4. Run the following commands in the telnet shell (this will install
   OpenWrt initramfs image on nand flash):
cd /tmp
tftp -g -r initramfs.bin 192.168.2.2
mtd write initramfs.bin firmware
mtd erase firmware_backup
reboot
5. Copy OpenWrt sysupgrade image (sysupgrade.bin) to the /tmp dir of the
   router
6. Connect to the router (IP: 192.168.1.1) using ssh shell and run
   sysupgrade command:
sysupgrade -n /tmp/sysupgrade.bin

Return to stock
---------------
1. Copy stock firmware (stock.bin) to the /tmp dir of the router using scp
2. Run following command in the router shell:
cd /tmp
mtd write stock.bin firmware
reboot

Recovery
--------
Connect uart (pins are silkscreened on the pcb), interrupt boot process by
pressing any key, use u-boot menu to flash stock firmware image or OpenWrt
initramfs image.

MAC addresses
-------------
+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| LAN     | 24:0f:5e:xx:xx:4c | label     |
| WAN     | 24:0f:5e:xx:xx:4d | label+1   |
| WLAN 2g | 24:0f:5e:xx:xx:4e | label+2   |
| WLAN 5g | 24:0f:5e:xx:xx:4f | label+3   |
+---------+-------------------+-----------+
The WLAN 2.4 MAC was found in 'factory', 0x4
The LAN MAC was found in 'factory', 0xfff4
The WAN MAC was found in 'factory', 0xfffa

Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
9 months agolldpd: update URL
Paul Donald [Mon, 11 Mar 2024 23:31:15 +0000 (00:31 +0100)]
lldpd: update URL

update Makefile URL

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: shellcheck fixes
Paul Donald [Mon, 11 Mar 2024 22:33:47 +0000 (23:33 +0100)]
lldpd: shellcheck fixes

No functionality/behaviour changes; code is synonymous

Tested on: 22.03.6

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: implement lldp_policy parameter
Paul Donald [Thu, 8 Feb 2024 19:35:31 +0000 (20:35 +0100)]
lldpd: implement lldp_policy parameter

For certain lldp_class scenarios (2 & 3) a policy must be set also.
Class 4 is default, although it's good to handle the policy eventuality.

Here, set a default lldp_policy for all lldp_class scenarios. Any
lldp_policy can now be set.

Depends on PR #14584 (which introduced an `if` block)

Tested on 22.03.5, 22.03.6

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agokernel: config: 6.6: disable ZSTD debug info compression by default
Robert Marko [Tue, 12 Mar 2024 04:06:14 +0000 (00:06 -0400)]
kernel: config: 6.6: disable ZSTD debug info compression by default

When kernel 6.6 is being compiled with GCC13 it will prompt for:
Compressed Debug information
> 1. Don't compress debug information (DEBUG_INFO_COMPRESSED_NONE)
  2. Compress debugging information with zlib (DEBUG_INFO_COMPRESSED_ZLIB)
  3. Compress debugging information with zstd (DEBUG_INFO_COMPRESSED_ZSTD) (NEW)

This is because kernel now also has support for compressing debug info
with ZSTD, so add the missing symbol and disable it by default.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agoramips: add support for YunCore G720
Daniel Golle [Fri, 8 Mar 2024 20:20:23 +0000 (20:20 +0000)]
ramips: add support for YunCore G720

The YunCore G720 is a dual band 802.11ax router with 5 GbE ports.

Specs:
- SoC: MediaTek MT7621
- Ethernet: 5x GbE ports (built-in MT7530)
- Wireless 2.4GHz / 5GHz: MediaTek MT7915E
- RAM: 256MiB
- ROM: 16MiB (W25Q128)
- 1 Button (reset)
- 8 LEDs (1x system, 2x wifi, 5x switch ports)

Flash instructions:
The vendor firmware is based on OpenWrt, the sysupgrade image can be
flashed using the '-F' (force) option on the CLI.
Make sure not to keep settings when doing so.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agoramips: switch to 6.1 kernel
Nick Hainke [Tue, 12 Mar 2024 11:12:41 +0000 (12:12 +0100)]
ramips: switch to 6.1 kernel

We have had the testing kernel for several weeks now. Let's switch to 6.1
to have more testers. Additionally, 6.6 is already in the pipeline.

Signed-off-by: Nick Hainke <vincent@systemli.org>
9 months agokernel: config: add missing symbol for kenrel 6.6
Weijie Gao [Tue, 12 Mar 2024 14:44:37 +0000 (22:44 +0800)]
kernel: config: add missing symbol for kenrel 6.6

CONFIG_HID_SUPPORT:
Set default value for kmod-hid

CONFIG_USB_CDNS3_IMX:
CONFIG_USB_CDNS3_PCI_WRAP:
CONFIG_USB_CDNSP_PCI:
Introduced by db0d7cf6a1 (usb: add cdns3 support)

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agoRevert "kernel: config: add symbol introduced with 6.2"
Robert Marko [Tue, 12 Mar 2024 12:00:03 +0000 (13:00 +0100)]
Revert "kernel: config: add symbol introduced with 6.2"

This reverts commit 7ea82bc17d1583f4d9d46397846b0eb63e6651eb.

This commit does not meet formal requirments, and has been merged due to
my error.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agostarfive: refresh patches
Robert Marko [Tue, 12 Mar 2024 09:11:00 +0000 (10:11 +0100)]
starfive: refresh patches

CI reported that patches need to be refreshed, so lets refresh.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agokernel: config: add symbol introduced with 6.2
CharlesMengCA [Tue, 12 Mar 2024 04:06:14 +0000 (00:06 -0400)]
kernel: config: add symbol introduced with 6.2

CONFIG_DEBUG_INFO_COMPRESSED_ZSTD, required by  GCC 13.0+

Compress the debug information using zstd. This may provide better compression than zlib, for about the same time costs, but requires newer toolchain support. Requires GCC 13.0+ or Clang 16.0+, binutils 2.40+, and zstd.

Signed-off-by: CharlesMengCA <58993776+CharlesMengCA@users.noreply.github.com>
9 months agokernel: modules: don't override NLS dependencies
Daniel Golle [Mon, 11 Mar 2024 23:23:23 +0000 (23:23 +0000)]
kernel: modules: don't override NLS dependencies

Recent changes for Linux 6.6 broke things when building with older
kernels:
Package kmod-fs-jfs is missing dependencies for the following libraries:
nls_base.ko

Fix this by adding NLS dependencies after the added dependency applying
on Linux 6.6.

Fixes: f9198480da ("kernel: modules: fs: adapt for kernel 6.6")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: add Linux 6.6 as testing kernel
Daniel Golle [Sat, 2 Mar 2024 04:25:43 +0000 (04:25 +0000)]
mediatek: add Linux 6.6 as testing kernel

Add KERNEL_TESTING_PATCHVER for Linux 6.6.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: add kernel configs for Linux 6.6
Daniel Golle [Sat, 2 Mar 2024 04:29:48 +0000 (04:29 +0000)]
mediatek: add kernel configs for Linux 6.6

Add config-6.6 for all mediatek subtargets.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: fix build of MT7988 clk drivers on Linux 6.6
Daniel Golle [Sat, 2 Mar 2024 04:24:15 +0000 (04:24 +0000)]
mediatek: fix build of MT7988 clk drivers on Linux 6.6

As shared remove functions now returns void instead of int we need to
use .remove_new instead of .remove.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: leds-smartrg-system: fix build on Linux 6.6
Daniel Golle [Sat, 2 Mar 2024 04:23:22 +0000 (04:23 +0000)]
mediatek: leds-smartrg-system: fix build on Linux 6.6

Adapt to changed function pointer prototypes.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: 6.6: refresh patches
Daniel Golle [Fri, 1 Mar 2024 02:22:25 +0000 (02:22 +0000)]
mediatek: 6.6: refresh patches

Refresh patches and fix changed path for 32-bit mediatek boards
'arch/arm/dts' -> 'arch/arm/dts/mediatek'

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: 6.6: drop patches backported as fixes
Daniel Golle [Fri, 1 Mar 2024 01:59:21 +0000 (01:59 +0000)]
mediatek: 6.6: drop patches backported as fixes

Drop patches backported as fixes in later kernel version.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: 6.6: drop backport patches
Daniel Golle [Fri, 1 Mar 2024 01:57:56 +0000 (01:57 +0000)]
mediatek: 6.6: drop backport patches

Drop all backport patches that are now included in kernel 6.6.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: copy patches-6.1 to patches-6.6
Daniel Golle [Fri, 1 Mar 2024 01:56:57 +0000 (01:56 +0000)]
mediatek: copy patches-6.1 to patches-6.6

Copy patches from patches-6.1 to patches-6.6. No changes.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: copy files-6.1 to files-6.6
Daniel Golle [Fri, 1 Mar 2024 01:56:31 +0000 (01:56 +0000)]
mediatek: copy files-6.1 to files-6.6

Copy files from files-6.1 to files-6.6. No changes.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agogeneric: 6.6: fix copy & refresh
Daniel Golle [Mon, 11 Mar 2024 19:10:49 +0000 (19:10 +0000)]
generic: 6.6: fix copy & refresh

A new patch was added meanwhile which will go as fix via netdev tree.
Copy & refresh it for Linux 6.6 as well.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agokernel: config: add symbol introduced with 6.1.81
John Audia [Wed, 6 Mar 2024 21:19:12 +0000 (16:19 -0500)]
kernel: config: add symbol introduced with 6.1.81

Add CONFIG_EFI_HANDOVER_PROTOCOL=y to the default config[1] and disable CONFIG_NFSD_V2

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

Signed-off-by: John Audia <therealgraysky@proton.me>
9 months agokernel: bump 6.1 to 6.1.81
John Audia [Wed, 6 Mar 2024 21:29:01 +0000 (16:29 -0500)]
kernel: bump 6.1 to 6.1.81

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

All patches automatically rebased.

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

Signed-off-by: John Audia <therealgraysky@proton.me>
9 months agofitblk: invert kernel version dependency
Daniel Golle [Sat, 2 Mar 2024 16:09:29 +0000 (16:09 +0000)]
fitblk: invert kernel version dependency

Allow building fitblk with Linux 6.6 by depending on !LINUX_5_15
instead of LINUX_6_1.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agoath10k-ct: fix build error on linux kernel 6.6
Weijie Gao [Thu, 29 Feb 2024 16:47:56 +0000 (00:47 +0800)]
ath10k-ct: fix build error on linux kernel 6.6

Fix a build error caused by fortify checking memcpy data range.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agortl8812au-ct: fix build failure on linux kernel 6.6
Weijie Gao [Thu, 29 Feb 2024 16:46:12 +0000 (00:46 +0800)]
rtl8812au-ct: fix build failure on linux kernel 6.6

Use the correct return status code to avoid incompatible type error

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agomt76: fix build failure on linux kernel 6.6
Weijie Gao [Fri, 1 Mar 2024 07:49:13 +0000 (15:49 +0800)]
mt76: fix build failure on linux kernel 6.6

A commit introduced in kernel 6.6 has splitted page_pool.h into
several headers. Thus the included header must be modified for a
successful build.

Ref: a9ca9f9ceff3 (page_pool: split types and declarations from
page_pool.h)

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agomac80211: fix build with linux kernel 6.6
Weijie Gao [Thu, 29 Feb 2024 15:56:40 +0000 (23:56 +0800)]
mac80211: fix build with linux kernel 6.6

Fix build failure with linux kernel 6.6

Related kernel commits:

20b0b53aca43 (genetlink: introduce split op representation)

bffcc6882a1b (genetlink: remove userhdr from struct genl_info)

e9a688bcb193 (random: use rejection sampling for uniform bounded
random integers)

3c202d14a9d7 (prandom: remove prandom_u32_max())

3d2f20ad46f8 (wifi: iwlwifi: Use generic thermal_zone_get_trip()
function)

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogpio-button-hotplug: fix 6.2 build failure
Weijie Gao [Sat, 6 Jan 2024 19:31:28 +0000 (03:31 +0800)]
gpio-button-hotplug: fix 6.2 build failure

devm_gpiod_get_from_of_node() was removed since linux 6.2.
devm_fwnode_gpiod_get() is the recommended replacement.

Link:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/drivers/gpio/gpiolib-devres.c?id=650f2dc970539b3344a98c4bd18efa309e66623b

Signed-off-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: crypto: add kmod-crypto-geniv as dependency to modules that use it
Robert Marko [Thu, 7 Mar 2024 14:08:27 +0000 (15:08 +0100)]
kernel: crypto: add kmod-crypto-geniv as dependency to modules that use it

Now that geniv is packaged separately for kernel 6.6, we need to add it
as a dependency to kmod-crypto-seqiv and kmod-crypto-echainiv that require
it under kernel 6.6.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agokernel: crypto: remove geniv from aead with kernel 6.6
Robert Marko [Thu, 7 Mar 2024 14:04:59 +0000 (15:04 +0100)]
kernel: crypto: remove geniv from aead with kernel 6.6

geniv was separated intentionally from aead in kernel 6.5, and since
we now have it packaged separately as well remove it from kmod-aead
in 6.6.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agokernel: crypto: package geniv as a separate module for 6.6
Robert Marko [Thu, 7 Mar 2024 13:47:13 +0000 (14:47 +0100)]
kernel: crypto: package geniv as a separate module for 6.6

In kernel 6.5 geniv was split from AEAD config symbol, in order to manage
its dependencies on other code.

So, lets do the same in OpenWrt and split it from aead module so others
can depend on geniv directly.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agokernel: modules: hwmon: adapt for kernel 6.6
Tan Zien [Sun, 3 Mar 2024 16:57:03 +0000 (00:57 +0800)]
kernel: modules: hwmon: adapt for kernel 6.6

Adapt hwmon kmods for building under kernel 6.6:
* ad7418 now requires regmap
* Invert criteria to allow adt7410 be built with Linux 6.1 as well
  as Linux 6.6.

Signed-off-by: Tan Zien <nabsdh9@gmail.com>
9 months agokernel: modules: crypto: adapt for kernel 6.6
Weijie Gao [Sun, 3 Mar 2024 14:07:29 +0000 (22:07 +0800)]
kernel: modules: crypto: adapt for kernel 6.6

Adapt crypto kmods for building under kernel 6.6:
* mpi.ko moved from lib/mpi/mpi.ko to lib/crypto/mpi/mpi.ko
* jitterentropy_rng requires SHA3 support for kernel 6.6

Signed-off-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Tan Zien <nabsdh9@gmail.com>
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: video: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 08:19:10 +0000 (16:19 +0800)]
kernel: modules: video: adapt for kernel 6.6

Adapt video kmods for building under kernel 6.6:
* Add drm_exec.ko and drm_suballoc_helper.ko for kmod-drm as they
are added since 6.6 and 6.4
* Add uvc.ko for kmod-video-uvc as related contents was split as a
new module since 6.3

Signed-off-by: Tan Zien <nabsdh9@gmail.com>
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: block: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 08:12:06 +0000 (16:12 +0800)]
kernel: modules: block: adapt for kernel 6.6

Adapt block kmods for building under kernel 6.6:
* To build scsi_transport_iscsi.ko, change CONFIG_SCSI_ISCSI_ATTRS
from =y to =m as this config is always tristate since 2.6.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: fs: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 07:56:26 +0000 (15:56 +0800)]
kernel: modules: fs: adapt for kernel 6.6

Adapt fs kmods for building under kernel 6.6:
* Add kmod-fs-netfs as dependency for kmod-fs-9p
* Add kmod-fs-netfs as dependency for fs-smbfs-common as netfs is
required for cifs since 6.3
* Add new kmod-nls-ucs2-utils as dependency for smbfs/jfs as UCS2
support was split as new module since 6.6.
* Add kmod-lib-zlib-deflate and kmod-lib-zlib-inflate as
dependencies for kmod-pstore due to crypto API compression was
replaced with zlib_deflate library calls since 6.6
* Remove nfs_ssc.ko from kmod-fs-nfs-common. The nfs_ssc was no
longer a kernel module described by NFS_V4_2_SSC_HELPER since 5.13 [1]

Link:
[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/fs/Kconfig?id=d9092b4bb2109502eb8972021a3f74febc931a63

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: usb: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 07:17:17 +0000 (15:17 +0800)]
kernel: modules: usb: adapt for kernel 6.6

Adapt usb kmods for building under kernel 6.6:
* Add kmod-phylink as dependency for usb-net-asix
* Add kmod-net-selftests as dependency for usb-net-smsc95xx
* Add kmod-iio-core as dependency for usb-hid-mcp2221 as ADC/DAC
support was added since 6.2 which requires IIO.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: netdevices: adapt for kernel 6.6
Daniel Golle [Sat, 2 Mar 2024 04:21:29 +0000 (04:21 +0000)]
kernel: modules: netdevices: adapt for kernel 6.6

Adapt netdevices kmods for building under kernel 6.6:
* Add missing module dependency for kmod-stmmac-core on kmod-of-mdio.
* Invert criteria to allow Airoha EN8811H PHY driver to build with
  Linux 6.1 as well as Linux 6.6.
* Mellanox mlx5 driver started exposing thermal sensors and now it requires
  hwmon

Signed-off-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agokernel: modules: netsupport: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 07:09:12 +0000 (15:09 +0800)]
kernel: modules: netsupport: adapt for kernel 6.6

Adapt netsupport kmods for building under kernel 6.6:
* common part of mqprio was split into a new Kconfig since 6.3.
Add new kmod-sched-mqprio-common as dependency for kmod-sched-mqprio.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: input: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 07:08:41 +0000 (15:08 +0800)]
kernel: modules: input: adapt for kernel 6.6

Adapt input kmods for building under kernel 6.6:
* kmod-input-touchscreen-edt-ft5x06 depends on kmod-regmap-i2c
from 6.3 as it starts to use regmap to access registers
* CONFIG_HID_SUPPORT needs to be set in addition to CONFIG_HID.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: modules: iio: adapt for kernel 6.6
Weijie Gao [Sat, 6 Jan 2024 05:15:41 +0000 (13:15 +0800)]
kernel: modules: iio: adapt for kernel 6.6

Adapt iio kmods for building under kernel 6.6:
* kmod-iio-lsm6dsx depends on kmod-kmod-industrialio-triggered-buffer
from 6.2

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: fix realtek PHY detection patch
Daniel Golle [Sat, 2 Mar 2024 04:48:08 +0000 (04:48 +0000)]
generic: 6.6: fix realtek PHY detection patch

Avoid crashing the kernel when trying to detect early versions of
RealTek RTL8221B 2.5G Ethernet PHY.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agogeneric: 6.6: fix uncompressed kallsyms
Robert Marko [Fri, 1 Mar 2024 13:15:15 +0000 (14:15 +0100)]
generic: 6.6: fix uncompressed kallsyms

Currently, the existing uncompressed kallsym support is causing qualcommax
boards to hang on boot, and only after earlycon and verbose BUG() prints
are enabled the trace is visible:
[    0.000000] ------------[ cut here ]------------
[    0.000000] kernel BUG at kernel/kallsyms.c:340!
[    0.000000] Internal error: Oops - BUG: 00000000f2000800 [#1] SMP

Felix has fixed up the uncompressed kallsyms support so modify the current
patch with the fix.
All credits for the code go to Felix.

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 months agogeneric: v6.6: update fitblk driver to work with Linux 6.6
Daniel Golle [Fri, 1 Mar 2024 00:08:35 +0000 (00:08 +0000)]
generic: v6.6: update fitblk driver to work with Linux 6.6

Update fitblk driver which has previously been backported to Linux 6.1
so it can build and work with Linux 6.6.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agogeneric: 6.6: refresh config symbols
Weijie Gao [Fri, 5 Jan 2024 08:49:18 +0000 (16:49 +0800)]
generic: 6.6: refresh config symbols

Sort generic config for 6.6.

The sort commands:
$ ./scripts/kconfig.pl '+' target/linux/generic/config-6.6 /dev/null > target/linux/generic/config-6.6-new
$ mv target/linux/generic/config-6.6-new target/linux/generic/config-6.6

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: add missing symbols
Weijie Gao [Fri, 5 Jan 2024 08:31:24 +0000 (16:31 +0800)]
generic: 6.6: add missing symbols

Add missing symbols to config for 6.6.

Signed-off-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: refresh hack patches
Weijie Gao [Fri, 8 Mar 2024 14:04:26 +0000 (22:04 +0800)]
generic: 6.6: refresh hack patches

Refresh hack patches with make target/linux/refresh.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: refresh pending patches
Weijie Gao [Fri, 8 Mar 2024 14:04:14 +0000 (22:04 +0800)]
generic: 6.6: refresh pending patches

Refresh pending patches with make target/linux/refresh.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: refresh backport patches
Weijie Gao [Fri, 8 Mar 2024 14:03:01 +0000 (22:03 +0800)]
generic: 6.6: refresh backport patches

Refresh backport patches with make target/linux/refresh.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: manually refresh hack patches
Weijie Gao [Wed, 3 Jan 2024 18:02:53 +0000 (02:02 +0800)]
generic: 6.6: manually refresh hack patches

Refresh hack patches for kernel 6.6.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: manually refresh pending patches
Weijie Gao [Wed, 3 Jan 2024 18:02:00 +0000 (02:02 +0800)]
generic: 6.6: manually refresh pending patches

Refresh pending patches for kernel 6.6.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: manually refresh backport patches
Weijie Gao [Wed, 3 Jan 2024 17:58:18 +0000 (01:58 +0800)]
generic: 6.6: manually refresh backport patches

Refresh backport patches that still needs to be merged for kernel 6.6.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: drop pending patch backported as fixes
Weijie Gao [Wed, 3 Jan 2024 17:49:26 +0000 (01:49 +0800)]
generic: 6.6: drop pending patch backported as fixes

Drop pending patch backported as fixes in later kernel version.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: 6.6: drop backport patches
Weijie Gao [Wed, 3 Jan 2024 17:47:10 +0000 (01:47 +0800)]
generic: 6.6: drop backport patches

Drop all backport patches that are now included in kernel 6.6.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agogeneric: copy backport, hack, pending patch and config from 6.1 to 6.6
Weijie Gao [Wed, 3 Jan 2024 11:57:28 +0000 (19:57 +0800)]
generic: copy backport, hack, pending patch and config from 6.1 to 6.6

Copy backport, hack, pending patch and config from 6.1 to 6.6.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agokernel: add define for kernel 6.6
Weijie Gao [Wed, 3 Jan 2024 18:14:53 +0000 (02:14 +0800)]
kernel: add define for kernel 6.6

Add define for kernel 6.6.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agotools: add util-linux
Weijie Gao [Tue, 9 Jan 2024 15:20:18 +0000 (23:20 +0800)]
tools: add util-linux

since kernel 6.4, commit bca2f3a9406b ("efi/zboot: Add BSS padding
before compression") introduces the use of hexdump to padding the
EFI kernel binary before compression.

util-linux which containing hexdump should then be compiled as a host
tool to guarantee not breaking the kernel build process.

Signed-off-by: Weijie Gao <hackpascal@gmail.com>
9 months agomediatek: mt7988: fix clk for 2nd PCIe port
Daniel Golle [Mon, 11 Mar 2024 18:32:38 +0000 (18:32 +0000)]
mediatek: mt7988: fix clk for 2nd PCIe port

Due to what seems to be an undocumented oddity in MediaTek's MT7988
SoC design the CLK_INFRA_PCIE_PERI_26M_CK_P2 clock requires
CLK_INFRA_PCIE_PERI_26M_CK_P3 to be enabled.

This currently leads to PCIe port 2 not working in Linux.

Reflect the apparent relationship in the clk driver to make sure PCIe
port 2 of the MT7988 SoC works.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agokernel: mtk_eth_soc: release MAC_MCR_FORCE_LINK only when MAC is up
Daniel Golle [Mon, 11 Mar 2024 18:26:55 +0000 (18:26 +0000)]
kernel: mtk_eth_soc: release MAC_MCR_FORCE_LINK only when MAC is up

Clearing bit MAC_MCR_FORCE_LINK which forces the link down too early
can result in MAC ending up in a broken/blocked state.

Fix this by handling this bit in the .mac_link_up and .mac_link_down
calls instead of in .mac_finish.

Suggested-by: Mason-cw Chang <Mason-cw.Chang@mediatek.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agomediatek: mt7622: linksys-e8450: set driving strength for SPI-NAND
Daniel Golle [Sun, 10 Mar 2024 23:14:33 +0000 (23:14 +0000)]
mediatek: mt7622: linksys-e8450: set driving strength for SPI-NAND

Set 12mA driving strength for SPI-NAND pins like the stock firmware's
bootloader does as well.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agouboot-mediatek: fix typo patch filename
Daniel Golle [Sun, 10 Mar 2024 13:49:45 +0000 (13:49 +0000)]
uboot-mediatek: fix typo patch filename

311-mt7986-select-roodisk.patch -> 311-mt7986-select-rootdisk.patch

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agouboot-mediatek: fix patch order
Daniel Golle [Sun, 10 Mar 2024 13:29:14 +0000 (13:29 +0000)]
uboot-mediatek: fix patch order

Make sure patch sequence number is unique by moving patch
440-add-jdcloud_re-cp-03.patch -> 441-add-jdcloud_re-cp-03.patch

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
9 months agolldpd: Implement location parameter
Paul Donald [Thu, 8 Feb 2024 18:15:55 +0000 (19:15 +0100)]
lldpd: Implement location parameter

Previously only partially implemented. After commit
5007f488bb5e1b556052ef246bd3822fed8d09d2 lldp_location was never removed

Now, add the value of lldp_location to the generated config.

The location param has a few syntaxes, so the config acquires the first
usage from the man page: 'address country EU'

Supplementary fix for PR #14193 (this param was included in the original
PR #13018 but the lldp_location fixes were absent from PR #14193).

Tested on 22.03.5, 22.03.6

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: fix error "sh: XXXms: bad number"
Paul Donald [Thu, 8 Feb 2024 22:37:13 +0000 (23:37 +0100)]
lldpd: fix error "sh: XXXms: bad number"

from commit 3ce909914a12647bec52bcee0a162dd6d158a4f6

The lldpd man page says that "configure lldp tx-interval" can
specify an interval value in milliseconds by appending a "ms" suffix to
the figure. Thus mandating string handling, and not integer comparison.

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: refactor out ifaces derivation; reuse function
Paul Donald [Thu, 8 Feb 2024 21:05:11 +0000 (22:05 +0100)]
lldpd: refactor out ifaces derivation; reuse function

from commit 909f0630663d7ae1471c76154516e3299992a150

Now pass two params to get_config_cid_ifaces() for:

cid_interface
interface

Each of which is a CSV of interfaces.

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: remove unneeded quotes
Paul Donald [Thu, 8 Feb 2024 20:54:35 +0000 (21:54 +0100)]
lldpd: remove unneeded quotes

from commit a5f715da713304972467612d6934130ce3aa2837

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: remove unneeded quotes and variable quoting
Paul Donald [Thu, 8 Feb 2024 20:44:56 +0000 (21:44 +0100)]
lldpd: remove unneeded quotes and variable quoting

from commit ac771313ebedd2c4bfda8adef47650d45d77c32d

portidsubtype takes 1 of 2 possible keywords which do not need quoting:

         configure lldp portidsubtype ifname | macaddress

The third keyword 'local' is used in the syntax when individual ports
are being defined:

         configure [ports ethX [,…]] lldp portidsubtype local value

When this syntax is used, quoting is useful (see test cases for lldpd).
In the init file, the 'local' syntax is unused.

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: remove unneeded quotes and variable quoting
Paul Donald [Thu, 8 Feb 2024 20:42:11 +0000 (21:42 +0100)]
lldpd: remove unneeded quotes and variable quoting

from commit c98ee4dbb3db0f064d990941cdd82e872da76946

agent-type takes 1 of 3 possible keywords which do not require quoting:

         configure lldp agent-type nearest-bridge | nearest-non-tpmr-bridge
         | nearest-customer-bridge

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: remove unneeded quotes and variable quoting
Paul Donald [Thu, 8 Feb 2024 20:29:37 +0000 (21:29 +0100)]
lldpd: remove unneeded quotes and variable quoting

from commit 3ce909914a12647bec52bcee0a162dd6d158a4f6

'capabilities enabled x' where x is a string of CSV

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: remove unneeded quotes
Paul Donald [Thu, 8 Feb 2024 20:31:29 +0000 (21:31 +0100)]
lldpd: remove unneeded quotes

from commit 3ce909914a12647bec52bcee0a162dd6d158a4f6

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: remove unneeded quotes and variable quoting
Paul Donald [Thu, 8 Feb 2024 20:31:57 +0000 (21:31 +0100)]
lldpd: remove unneeded quotes and variable quoting

from commit 24176a6bdd8f26040a97960868fd0d9ee968d695

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: fix a paste error
Paul Donald [Thu, 8 Feb 2024 19:26:13 +0000 (20:26 +0100)]
lldpd: fix a paste error
from commit 1be2088a5247b2cfabe8be991c1e52ddaf780a16

The original PR #13018 did not exhibit this.

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: spell fixes
Paul Donald [Thu, 8 Feb 2024 14:59:27 +0000 (15:59 +0100)]
lldpd: spell fixes

Supplementary fix for PR #14193

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agolldpd: fix -k 'lldp_no_version' row
Paul Donald [Thu, 8 Feb 2024 14:57:28 +0000 (15:57 +0100)]
lldpd: fix -k 'lldp_no_version' row

Supplementary fix for PR #14193 and commit
b67182008fd124706be0ec3ce67347447554ffd5

Tested on 22.03.5

Signed-off-by: Paul Donald <newtwen@gmail.com>
9 months agodnsmasq: version 2.90
Nathaniel Wesley Filardo [Sun, 18 Feb 2024 13:12:10 +0000 (13:12 +0000)]
dnsmasq: version 2.90

Bump to 2.90 to get upstream's fix for DNSSEC KeyTrap (CVE-2023-50387,
CVE-2023-50868) among many other goodies and fixes (notably, upstream
568fb024... fixes a UAF in cache_remove_uid that was routinely crashing
dnsmasq in my deployment).

Catch up our 200-ubus_dns.patch, too.

Signed-off-by: Nathaniel Wesley Filardo <nwfilardo@gmail.com>
9 months agoscripts: Kernel bumper script
Olliver Schinagl [Fri, 23 Feb 2024 21:54:48 +0000 (22:54 +0100)]
scripts: Kernel bumper script

For years, we have struggled and been frustrated at loosing history of
files in git, due to the 'copy + add' strategy. This could have been
prevented with a double-commit 'mv + add' trick.

On the mailing list [0] the discussion was started to put the
instructions in a wiki. Instead, it is much better to just script it and
put it in the repo.

Instead of doing mv + copy, which leads to two commits, but no history
on the copied files, it uses move, + copy and merge, which results in
three (merge) commits, but keeps the history of all files. As always
with renames, `--follow` will be needed.

The tool is trivial and works either in the OpenWrt git root directory,
or in the actual target directory.

Tested on the `realtek` and generic targets.

Note, that the tool does not do any of the labor needed after the move,
such as updating configs, dropping patches etc.

To make sure this script is easily found by any developer, who just
wants to do a kernel bump, the script is added here and not to
maintainer-tools repo as those scripts are a little bit more specialized.
Bumping a kernel is a trivial task that often regular developers do,
where most do not even know the existence of maintainer tools, are not
part of the main repo they'd clone, not part of the docker container
they'd use and so discoverability is probably much more important.

[0]: https://lists.openwrt.org/pipermail/openwrt-devel/2023-October/041673.html

Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
Tested-by: Robert Marko <robimarko@gmail.com>
Tested-by: Weijie Gao <hackpascal@gmail.com>
9 months agobmips: add support for SmartRG SR505n
Kyle Hendry [Sun, 18 Feb 2024 20:26:38 +0000 (12:26 -0800)]
bmips: add support for SmartRG SR505n

Specifications:
- SoC: Broadcom BCM63168 dual 400MHz MIPS
- Flash: 16MB SPI NOR W25Q128WFG
- RAM: 128MB DDR3 W631GG6KB-15
- Ethernet: 1x 1000M, 3x 100M
- Wifi: BCM435F
- 1x USB 2.0 port
- 3x Button
- 12x LED

Flashing via serial
- Connect to the 3.3V TTL UART on the board
  (J6 pinout Vcc Rx Tx Gnd) at 115200-8-N-1
- Press any key in the serial console when powering up the board to enter
  the CFE prompt
- Configure an interface on your workstation to static IP 192.168.1.100
  and connect it to the board
- Start a TFTP server with the firmware image
- On the CFE prompt, enter the command
  "f 192.168.1.100:openwrt-bmips-bcm63268-smartrg_sr505n-squashfs-cfe.bin"

Signed-off-by: Kyle Hendry <kylehendrydev@gmail.com>
[Remove unneeded LED labels]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
9 months agomac80211: select BRCMFMAC_SDIO on starfive
Zoltan HERPAI [Tue, 22 Aug 2023 21:39:14 +0000 (23:39 +0200)]
mac80211: select BRCMFMAC_SDIO on starfive

As the Visionfive V1 board has an Ampak module connected via SDIO, enable
support for SDIO in the brcmfmac module.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
9 months agostarfive: add new target for StarFive JH7100/7110 SoC
Zoltan HERPAI [Sun, 28 May 2023 13:14:02 +0000 (15:14 +0200)]
starfive: add new target for StarFive JH7100/7110 SoC

This target adds support for the StarFive JH7100 and JH7110 SoCs, based on
6.1, as well as a couple boards equipped with these.

Specifications:

SoCs:

JH7100:
 - StarFive JH7100 dual-core RISC-V (U74, RC64GC)
 - additional monitoring (S7) and control (E24) cores
 - 2Mb L2 cache

JH7110:
 - StarFive JH7110 quad-core RISC-V (U74, RV64GC)
 - additional monitoring (S7) and control (E24) cores
 - 2Mb L2 cache

Boards:

VisionFive1:
 - JH7100 @ 1GHz
 - Memory: 8Gb LPDDR4
 - 4x USB3.0
 - 1x GBit ethernet
 - AMPak 6236 wifi / bluetooth
 - audio
 - powered via USB-C

VisionFive2:
 - JH7110 @ 1.5GHz
 - Memory: 2/4/8Gb DDR4
 - 2x Gbit ethernet
 - 2x USB3.0 / 2x USB2.0
 - eMMC / SDIO
 - various multimedia input/outputs (MIPI CSI, HDMI, audio)
 - M.2 key M slot
 - PoE support
 - powered via USB-C

Installation:
Standard SD-card installation via dd-ing the generated image to
an SD-card of at least 256Mb.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
9 months agousb: add cdns3 support
Zoltan HERPAI [Mon, 1 Jan 2024 12:50:46 +0000 (13:50 +0100)]
usb: add cdns3 support

CDNS3 is a SuperSpeed (SS) USB 3.0 Dual-Role-Device (DRD) controller from
Cadence. Add support for this device, and add the required symbols into
the generic configs.

Compile-tested: apm821xx, bcm4908, imx, mpc85xx, pistachio, starfive

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
9 months agoramips: improve support for STORYLiNK SAP-G3200U3
Sungbo Eo [Sun, 10 Mar 2024 04:55:24 +0000 (13:55 +0900)]
ramips: improve support for STORYLiNK SAP-G3200U3

* Increase flash SPI frequency to 50MHz

  The maximum SPI frequency of MX25L6406EM2I is 86 MHz,
  but in this patch 50 MHz was chosen as a safe value.

* Update Ethernet MAC addresses

  Till now LAN/WAN MAC addresses were flipped
  compared to stock firmware.

* Fix Wi-Fi LEDs by adding mt76 led nodes

* Fix LAN port order

  LAN ports are in reverse order of switch ports.

* Fix the well-known "LZMA ERROR 1" error by using lzma-loader

* Set uImage name, which enables installation via stock web interface:

  1.  Upload **initramfs** image file to the web page.
  2.  Boot into OpenWrt and perform sysupgrade with sysupgrade image.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
9 months agoramips: add factory image for ipTIME AX2004M
Sungbo Eo [Sun, 4 Feb 2024 18:57:27 +0000 (03:57 +0900)]
ramips: add factory image for ipTIME AX2004M

Unlike the recovery image, this initramfs-factory image can be flashed
using the stock firmware web interface (from any active boot partition),
as well as the bootloader recovery web page. Drop the recovery image in
favor of the factory image.

Installation via stock/recovery web interface:
1.  Flash **initramfs-factory** image through the web page.
2.  Boot into OpenWrt and perform sysupgrade with sysupgrade image.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
9 months agoramips: mt7621: use variable for relocate-kernel argument
Sungbo Eo [Sun, 4 Feb 2024 13:10:29 +0000 (22:10 +0900)]
ramips: mt7621: use variable for relocate-kernel argument

The "0x80001000" address logically comes from "loadaddr-y" variable for
mt7621 subtarget. Let's replace the hardcoded value with the predefined
variable. This change is purely cosmetic.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>