Commit Graph

30322 Commits

Author SHA1 Message Date
Robert Marko
bb907d8d44 generic: add fix for AQR113 PMD Global Transmit Disable bit
PMD Global Transmit Disable bit should be cleared for normal operation.
This should be HW default, however I found that on Asus RT-AX89X that uses
AQR113C PHY and firmware 5.4 this bit is set by default.

With this bit set the AQR cannot achieve a link with its link-partner and
it took me multiple hours of digging through the vendor GPL source to find
this out, so lets always clear this bit during .config_init() to avoid a
situation like this in the future.

aqr107_wait_processor_intensive_op() is moved up because datasheet notes
that any changes to this bit are processor intensive.

This is a modified version of patch that got merged upstream as AQR113C
has a separate config_init() upstream.

Link: https://github.com/openwrt/openwrt/pull/15840
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-09 12:33:17 +02:00
Robert Marko
19ecf84f0f qualcommax: ipq807x: enable QCA83XX PHY driver
Asus RT-AX89X has an external QCA8337 switch that has built-in
internal ethernet PHY-s that are supported by the QCA83XX PHY driver so
lets enable it.

Link: https://github.com/openwrt/openwrt/pull/15840
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-09 12:33:17 +02:00
Robert Marko
b215f5c95e qualcommax: ipq807x: enable qca8k driver
Asus RT-AX89X has an Qualcomm QCA8337 switch used to provide additional
1G copper ports, so lets enable qca8k in order to utilize DSA instead of
relying on SSDK for it.

Link: https://github.com/openwrt/openwrt/pull/15840
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-09 12:33:17 +02:00
Robert Marko
c39c8da242 qualcommax: ipq807x: enable GPIO bitbanged MDIO
Asus RT-AX89X is using GPIO bitbanged MDIO on newer HW revisions, so lets
enable it in kernel config.

Link: https://github.com/openwrt/openwrt/pull/15840
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-09 12:33:17 +02:00
Robert Marko
157a33402d qualcommax: ipq8074-ess: move switch to ess-instance node
It seems that newer SSDK is now expecting the switch node to be a subnode
of "ess-instance" node which also contains "num_devices" as the number of
switches as you can also have external switches connected.

Asus RT-AX89X is even more peculiar as its bootloader has a hardcoded path
to enable if on that revision there is an AQR113 connected to port 6 of the
switch.

So, lets move the current switch node under ess-instance as otherwise it
seems that SSDK is having some issues parsing the UNIPHY mode properly as
I am getting the following:
[    6.981404] _adpt_hppe_instance1_mode_get[3275]:ERROR:port 6 doesn't support port_interface_mode 9

Which should not happen as that port has the mode set to 13.

Link: https://github.com/openwrt/openwrt/pull/15840
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-09 12:33:17 +02:00
Christian Marangi
2bae9d04af
qualcommax: ipq807x: fix build error with no initramfs for RAX120v2
Exclude additional initramfs image for Netgear RAX120v2 when no
initramfs image are compiled to fix build error.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-07-08 13:23:26 +02:00
Robert Marko
dbb6698721 kernel: fix x86 compilation on macOS
Trying to compile x86 or x86_64 on macOS will fail with:
openwrt/build_dir/target-x86_64_musl/linux-x86_64/linux-6.6.36/tools/include/linux/rbtree.h:21:10: fatal error: 'linux/stddef.h' file not found

After some digging, it seems that we dropped the old 212-tools_portability
patch when 6.6 x86 support was added, then Felix added back some parts of
it in ("kernel: fix tools build breakage on macos with x86") but trying to
build x86 kernels will still fail.

So, lets add more of the required changes from the 212-tools_portability
patch so that x86 kernels build on macOS.

Fixes: 69b145188f ("generic: 6.6: Removal of tools_portability.patch already included in kernel 6.6")
Link: https://github.com/openwrt/openwrt/pull/15904
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-08 12:43:50 +02:00
Zxl hhyccc
e7599942af kernel: bump 6.1 to 6.1.97
https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.97

All patches automatically rebased.

Build system: Kirkwood bcm53xx

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15883
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-08 00:01:30 +02:00
Qingfang Deng
2ded54972e mediatek: fit: fix use of uninitialized variable
When building the kernel with -Wmaybe-uninitialized, GCC reports this
warning:

block/partitions/fit.c: In function 'parse_fit_partitions':
block/partitions/fit.c:164:3: warning: 'images' may be used uninitialized in this function [-Wmaybe-uninitialized]
  164 |   printk(KERN_ERR "FIT: Cannot find %s node: %d\n", FIT_CONFS_PATH, images);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

It appears to be a copy paste error. It's the "config" variable that is
supposed to be printed.

Fixes: e6aac8d98f ("image: add support for building FIT image with filesystem")
Signed-off-by: Qingfang Deng <qingfang.deng@siflower.com.cn>
2024-07-07 20:59:48 +08:00
Chuanhong Guo
7117ebab0b kernel: mtdsplit: fix fit rootfs_data split
fit size should be rounded up instead of rounding down first and adding
a block. Otherwise the calculated size is one block more than needed
when fit size is exactly multiples of one block size.

Fixes: 9a863f803e ("kernel: mtdsplit: add support for FIT image")
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Signed-off-by: Qingfang Deng <qingfang.deng@siflower.com.cn>
2024-07-07 20:58:56 +08:00
Martin Schiller
75cd4ef48d lantiq: replace gswip patches with upstream version
Replace recently added patches with version accepted upstream.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Link: https://github.com/openwrt/openwrt/pull/15811
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-06 17:50:24 +02:00
Martin Schiller
04fde44973 lantiq: remove 6.1 kernel support
Since 6.6 is now default, drop 6.1 support.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Link: https://github.com/openwrt/openwrt/pull/15811
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-06 17:50:23 +02:00
Martin Schiller
a0e254826c lantiq: switch to kernel 6.6
Let's switch the lantiq target to use kernel 6.6 by default.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Link: https://github.com/openwrt/openwrt/pull/15811
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-06 17:50:23 +02:00
Martin Schiller
48d0068bb1 generic: 6.6: backport fix for broken cmdline "nosmp" and "maxcpus=0"
This backports the fix for the broken "nosmp" and "maxcpus=0" cmdline
params.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Link: https://github.com/openwrt/openwrt/pull/15811
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-06 17:50:23 +02:00
Martin Schiller
289f0ef403 lantiq: remove 5.15 kernel support
Since 6.1 is now default, drop 5.15 support.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Link: https://github.com/openwrt/openwrt/pull/15811
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-06 17:50:23 +02:00
Daniel Golle
4a2f712f85 generic: 6.6: mtk_eth_soc: add support for flow-control settings
Add patch implementing operations to get and set flow-control link
parameters of mtk_eth_soc via ethtool.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-07-06 04:22:37 +01:00
Daniel Golle
27b6838afa generic: 6.6: mtk_eth_soc: import accepted patches
Import two imported patches accepted upstream.
Move from pending:
 - net: ethernet: mtk_eth_soc: implement .{get,set}_pauseparam ethtool ops

Initial import:
 - net: ethernet: mtk_ppe: Change PPE entries number to 16K

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-07-06 04:22:37 +01:00
Álvaro Fernández Rojas
e74ead2249 bcm27xx: update to latest RPi patches
The patches were generated from the RPi repo with the following command:
git format-patch v6.6.36..rpi-6.6.y

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-07-05 10:05:58 +02:00
Daniel Golle
680944ce88 mediatek: filogic: openwrt,one: remove unneeded caldata extraction
WiFi calibration data is already obtained via in-kernel NVMEM framework.
There is no need to also do so in userspace.

Fixes: dd58ad968a ("mediatek/filogic: add OpenWrt One support")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-07-05 03:52:48 +01:00
Daniel Golle
05eb6d0ad2 mediatek: filogic: add missing ';;' in /etc/board.d/01_leds
Add missing ';;' to terminate switch-case script generating
board-specific LED configuration defaults.

Fixes: c71b68acdd ("mediatek: filogic: add Adtran SmartRG Mount Stuart series")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-07-05 03:49:44 +01:00
Shiji Yang
5f250cfd04 ramips: gpio: convert to the generic GPIO driver
Drop most of the code in favor of the generic MMIO GPIO driver.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-07-04 22:20:47 +02:00
Shiji Yang
7be6323d3f ramips: gpio: use devm_platform_ioremap_resource()
Simplify the code.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-07-04 22:20:47 +02:00
Shiji Yang
256f1648e7 ramips: gpio: remove header "gpio.h"
There are no source files using it.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-07-04 22:20:47 +02:00
Shiji Yang
24459dc108 ramips: gpio: always use dynamic GPIO numberspace base
The new numberspace base starts from 512 instead of 0. The number
base seems come from the kernel symbol CONFIG_GPIOLIB_FASTPATH_LIMIT.

Suppress warning:

gpio gpiochip0: Static allocation of GPIO base is deprecated, use dynamic allocation.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-07-04 22:20:47 +02:00
Shiji Yang
2f1ff5b4ce ramips: mt7621: fix GPIO switch pin number
The numberspace base has been changed since 6.6 kernel:

chip_num   chip0   chip1   chip2 (32 gpios per bank)
old base    480     448     416
new base    512     544     576

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-07-04 22:20:47 +02:00
Dirk Buchwalder
9e49593ff7 mediatek: filogic: add support for TP-LINK RE6000XD
This commit adds support for TP-LINK RE6000XD.
The device is quite similar to the Mercusys MR90X V1,
except only 3 LAN ports and more LEDs.
So thanks to csharper2005 for doing all the groundwork.

Device specification
--------------------
SoC Type:   MediaTek MT7986BLA, Cortex-A53, 64-bit
RAM:        MediaTek MT7986BLA (512MB)
Flash:      SPI NAND GigaDevice (128 MB)
Ethernet:   MediaTek MT7531AE + 2.5GbE MaxLinear GPY211C0VC (SLNW8)
Ethernet:   1x2.5Gbe (LAN3 2.5Gbps), 2xGbE (LAN 1Gbps, LAN1,
            LAN2)
WLAN 2g:    MediaTek MT7975N, b/g/n/ax, MIMO 4x4
WLAN 5g:    MediaTek MT7975P(N), a/n/ac/ax, MIMO 4x4
LEDs:       8 LEDs, 1 status blue, 2x WIFI blue, 2x signal
	    blue/red, 3 LAN blue gpio-controlled
Button:     2 (Reset, WPS)
USB ports:  No
Power:      12 VDC, 2 A
Connector:  Barrel
Bootloader: Main U-Boot - U-Boot 2022.01-rc4. Additionally, ubi0
            partition contain "seconduboot" (also U-Boot 2022.01-rc4)

Serial console (UART), unpopulated
---------------------
                            V
+-------+-------+-------+-------+
| +3.3V |  GND  |  TX   |  RX   |
+---+---+-------+-------+-------+
    |
    +--- Don't connect

Disassemble: rm the 2 screws at the bottom and the one at the backside.
            un-clip the case starting at the edge above the LEDs.

Installation (UART)
-------------------
1. Place OpenWrt initramfs image on tftp server with IP 192.168.1.2
2. Attach UART, switch on the router and interrupt the boot process by
   pressing 'Ctrl-C'
3. Load and run OpenWrt initramfs image:
      tftpboot openwrt-mediatek-filogic-tplink_re6000xd-initramfs-kernel.bin bootm
4. Run 'sysupgrade -n' with the sysupgrade OpenWrt image

Notice: while I was successfull at activating ssh (as described
        here:
        https://www.lisenet.com/2023/gaining-ssh-access-to-tp-link-re200-wi-fi-range-extender/)

        Unfortunately I haven't found the correct root password.
        Looks like they are using a static password
        (md5crypt, salt + 21 characters) that is not the web
        interface admin password.

        The TP-LINK RE900XD looks like the very same device,
        according to the pictures and the firmware.
        But I haven't checked if the OpenWrt firmware works as well
        on that device.

        The second ubi partition (ubi1) is empty and there is no known
        dual-partition mechanism, neither in u-boot nor in the stock firmware.

Signed-off-by: Dirk Buchwalder <buchwalder@posteo.de>
2024-07-04 22:14:32 +02:00
John Audia
3711557bdf kernel: bump 6.6 to 6.6.36
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.36

Manually rebased:
        generic/hack-6.6/765-mxl-gpy-control-LED-reg-from-DT.patch
        bcm27xx/patches-6.6/950-0536-dmaengine-dw-axi-dmac-Fixes-for-RP1.patch

Removed upstreamed:
	bmips/patches-6.6/010-v6.10-mips-bmips-BCM6358-make-sure-CBR-is-correctly-set.patch[1]

All other patches automatically rebased.

1. 7c9644a7b5

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

Signed-off-by: John Audia <therealgraysky@proton.me>
2024-07-04 22:07:10 +02:00
Zxl hhyccc
93cb81cf2b kernel: bump 6.1 to 6.1.96
https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.96

Manually rebased:
generic/hack-6.1/765-mxl-gpy-control-LED-reg-from-DT.patch
reference:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/drivers/net/phy/mxl-gpy.c?h=v6.1.96&id=5bd1b7ab6ae5799c136e4319d8644c5ff9c71757

generic: Fix spelling in dmesg output during boot when using the fitblk driver.

generic/pending-6.1/510-block-add-uImage.FIT-subimage-block-driver.patch

All other patches automatically rebased.

Build system: Kirkwood bcm53xx

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
2024-07-04 22:02:47 +02:00
Mieczyslaw Nalewaj
bfb7fe71be bcm47xx: drop 6.1 support
Drop configs, files and patches for Linux 6.1.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15635
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:32:50 +02:00
Mieczyslaw Nalewaj
366031d0a3 bcm47xx: use kernel 6.6 by default
Switch to Linux kernel version 6.6.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15635
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:32:50 +02:00
Mieczyslaw Nalewaj
de223b5121 bcm47xx: remove old cache aliasing patches
Remove patches related to some ancient cache aliasing bugs that were fixed in earlier versions and are no longer relevant to us.

Co-authored-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15635
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:32:50 +02:00
Shiji Yang
d836a688d1 generic: gpio: fix broken GPIO for big endian CPUs
Align the "bgpio_bits" with the data bus width.

Fixes: https://github.com/openwrt/openwrt/issues/15739
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
Suggested-By: Mark Mentovai <mark@mentovai.com>
Tested-by: Lóránd Horváth <lorand.horvath82@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15784
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:30:37 +02:00
Shiji Yang
ee01666cd3 ath79: suppress GPIO static base allocation warning
Silence ath79 GPIO driver warning by setting GPIO numberspace base
dynamically. This patch also reorganize and fix the GPIO numbers on
6.6 kernel. The new gpio chip base number algorithm:

gpiochip    ath79-SOC    ath9k-0       ath9k-1
base           512      512+ngpios   512+ngpios+10

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
Link: https://github.com/openwrt/openwrt/pull/15784
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:30:37 +02:00
Shiji Yang
8895c51d69 ath79: fix 5GHz External Antenna A GPIO for BSAP-1840
Each ath9k device only has 10 gpios. ath9k-0 gpio number range is
502-511, and ath9k-1 gpio number range is 492-501. So "5GHz External
Antenna A" gpio line number should be 492 instead of 489.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
Link: https://github.com/openwrt/openwrt/pull/15784
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:30:37 +02:00
Shiji Yang
731318667d ath79: correct dts ngpios properties
SoC Model	GPIO number

ar7100		12
ar7240		18(unknown, default)
ar7241		20
ar7242		18
ar9132		22(unknown, default)
ar9331		30
ar934x		23
qca953x		18
qca955x		24
qca956x		23

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
Link: https://github.com/openwrt/openwrt/pull/15784
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:30:37 +02:00
FUKAUMI Naoki
1664e506ac uboot-rockchip: use u-boot-rockchip.bin
use u-boot-rockchip.bin to copy SPL/TPL/U-Boot to the image.

since binman was used in mainline u-boot for rockchip, we can use
u-boot-rockchip.bin instead of idbloader.img and u-boot.itb.

Reviewed-by: Tianling Shen <cnsztl@immortalwrt.org>
Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://github.com/openwrt/openwrt/pull/15815
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:26:00 +02:00
Rodrigo Balerdi
702bad7212 ipq40xx: add BDFs for Linksys WHW03 V1
BDFs come from latest firmware, version 1.1.19.209880 (2022-06-20):
- /lib/firmware/IPQ4019/v1/FCC/boardData_1_0_IPQ4019_DK04_2G.bin
- /lib/firmware/IPQ4019/v1/FCC/boardData_1_0_IPQ4019_DK04_5G.bin
- /lib/firmware/QCA9888/v1/FCC/boardData_2_0_QCA9888_5G_Y9690_SBS_HB.bin

Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15844
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-07-04 19:14:20 +02:00
Álvaro Fernández Rojas
37636a8752 bcm27xx: base-files: diag: improve LEDs behaviour
As reported in https://github.com/openwrt/openwrt/issues/15834 using the PWR
LED for indicating diag status is confusing since this is usually used for
power supply failures on RPi devices.
This commit uses ACT LED for diag status and restores it to mmc activity.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-07-03 20:56:56 +02:00
Shiji Yang
a7f37b401b ramips: remove useless compatible strings from SoC dtsi
These removed compatible strings do not exist in the source code
nor the dt-binding documents. They are useless.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-07-02 10:13:45 +02:00
Daniel Golle
8ef4d78582 generic: 6.6: net: ethernet: mediatek: Allow gaps in MAC allocation
Some devices with MediaTek SoCs don't use the first but only the second
MAC in the chip. Especially with MT7981 which got a built-in 1GE PHY
connected to the second MAC this is quite common.
Make sure to reset and enable PSE also in those cases by skipping gaps
using 'continue' instead of aborting the loop using 'break'.

Fixes: 75081235b8 ("generic: 6.6: (re-)add support multiple PPE to mtk_eth_soc")
Reported-by: Daniel Suchy <danny@danysek.cz>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-07-01 21:04:41 +01:00
Álvaro Fernández Rojas
2bf2ee7be8 bmips: enet: restore netif_napi_add weight
Switch to netif_napi_add_weight and add back weight value from <= v5.15.

Fixes: 8f6033e287 ("bmips: enet: add compatibility with kernel 6.1")
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-07-01 19:20:46 +02:00
Daniel Golle
90b6728de2 generic: fitblk: typo in dmesg output
Fix spelling in dmesg output during boot when using the fitblk driver.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-07-01 03:19:12 +01:00
Hauke Mehrtens
de01fec4a7 pistachio: Fix setting mtd name
The bootloader provides the partition table using the boot arguments
and uses the name spi-nor and spi-nand for the different controllers.
The old code was not setting the name any more because mtd->name was
already set before. Move the setting of the name to the spi-mem code
now.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-01 00:46:16 +02:00
Hauke Mehrtens
cd080be84c pistachio: Update to kernel 6.6
Refresh the patches and the configuration for kernel 6.6 and make
directly use of it.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-01 00:46:16 +02:00
Hauke Mehrtens
fcdaf6673d kernel/pistachio: 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.

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

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-01 00:46:15 +02:00
Hauke Mehrtens
a5d6a60fd0 kernel/pistachio: 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: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-01 00:46:15 +02:00
Hauke Mehrtens
19305aff72 kernel: bump 5.15 to 5.15.161
No manual changes needed.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-01 00:22:09 +02:00
Hauke Mehrtens
6cfa186544 kernel: bump 5.15 to 5.15.159
Removed because they are upstream:
   generic/pending-5.15/778-net-l2tp-drop-flow-hash-on-forward.patch
   https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-5.15.y&id=e97e0051056b6dbcc43ae1862dcfcb05d06517c3

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-07-01 00:22:09 +02:00
Paul Spooren
67e0c5922c
malta: enable VM targets again
These targets are interesting for automated testing. The currently
available targets are from 2017 and either we should enable them again
or delete the remaining files on the download servers.

Signed-off-by: Paul Spooren <mail@aparcar.org>
Link: https://github.com/openwrt/openwrt/pull/15740
Link: https://github.com/openwrt/openwrt/pull/15740
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-30 22:00:03 +02:00
Robert Marko
b4069fad02 ipq40xx: habanero-dvk: fix LAN MAC adresses
Currently, only the WAN MAC is being populated on Habanero DVK, and that is
happening via the ethernet1 alias so U-Boot does it, previously ethernet0
was implicitly added in the SoC DTSI so it would populate the LAN MAC-s but
it was dropped(rightly so) so now LAN MAC-s and the GMAC one are random.

So, lets simply switch to using NVMEM to assign the proper MAC adresses.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-30 11:26:23 +02:00
John Thomson
515ad3ce8a ipq40xx: ipqess: do not free ipqess_init
If this function is marked as __init, kernel will splat when driver is
(re)bind
echo "c080000.ethernet">/sys/bus/platform/drivers/ipqess-edma/unbind
echo "c080000.ethernet">/sys/bus/platform/drivers/ipqess-edma/bind

Example with additional print messages, functions at boot:
[    2.039468] ipqess-edma c080000.ethernet: ipqess_axi_probe pre register_netdev
[    2.039530] ipqess-edma c080000.ethernet: *netdev: c27d2000
[    2.045609] ipqess-edma c080000.ethernet: &ipqess_init: c0d1e28c
[    2.051122] ipqess_init
[    2.057338] netdev: c27d2000
[    2.059492] ess = netdev_priv: c27d2500
[    2.062615] ess->pdev: c2138c00
[    2.066174] ess->pdev->dev: c2138c10
[    2.069314] ess->pdev->dev.of_node: ef6f6368
[    2.073120] ess->pdev->dev.of_node: /soc/ethernet@c080000

fails (bind) after unbind:
[   34.987948] ipqess-edma c080000.ethernet: ipqess_axi_probe pre register_netdev
[   34.988012] ipqess-edma c080000.ethernet: *netdev: c27d6000
[   34.994088] ipqess-edma c080000.ethernet: &ipqess_init: c0d1e28c
[   34.999652] 8<--- cut here ---
[   35.005802] Unable to handle kernel paging request at virtual address c0d1e28c when execute
[   35.008676] [c0d1e28c] *pgd=80c1941e(bad)
[   35.016918] Internal error: Oops: 8000000d [#1] SMP ARM

Signed-off-by: John Thomson <git@johnthomson.fastmail.com.au>
Link: https://github.com/openwrt/openwrt/pull/15831
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-30 11:07:02 +02:00
John Thomson
69d0ff5803 ipq40xx: ipqess: pass up ethdev_addr probe defer
Notify via dev_info when a random MAC address is set.
of_get_ethdev_address can return -EPROBE_DEFER for NVMEM devices,
return this up, so that ipqess can defer as well.
Also move this MAC assignment from _init into _probe, so that this defer
can happen earlier.

Before change, with MAC address allocated from a built-in NVMEM layout
driver (mikrotik,routerboot-nvmem) with extra of_get_ethdev_address
result and random MAC printfs:
[    1.197571] ipqess-edma c080000.ethernet: ipqess_init of_get_ethdev_address ret:-517, of_node: /soc/ethernet@c080000
[    1.197690] ipqess-edma c080000.ethernet: generated random MAC address 22:e7:36:e0:e4:a3
[    1.614444] ipqess-edma c080000.ethernet eth0: entered promiscuous mode
[    5.055929] ipqess-edma c080000.ethernet eth0: configuring for fixed/internal link mode

after change:
[    1.173776] ipqess-edma c080000.ethernet: of_get_ethdev_address: -517
[    1.614607] ipqess-edma c080000.ethernet eth0: entered promiscuous mode
[    5.246105] ipqess-edma c080000.ethernet eth0: configuring for fixed/internal link mode
[    5.260754] ipqess-edma c080000.ethernet eth0: Link is Up - 1Gbps/Full - flow control rx/tx

with extra __func__ printf to show _probe and _init:
[    1.173685] ipqess-edma c080000.ethernet: ipqess_axi_probe
[    1.173784] ipqess-edma c080000.ethernet: of_get_ethdev_address: -517
[    1.280347] ipqess-edma c080000.ethernet: ipqess_axi_probe
[    1.304844] ipqess-edma c080000.ethernet: ipqess_init
[    1.614664] ipqess-edma c080000.ethernet eth0: entered promiscuous mode

Signed-off-by: John Thomson <git@johnthomson.fastmail.com.au>
Link: https://github.com/openwrt/openwrt/pull/15831
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-30 11:07:02 +02:00
Daniel Golle
75081235b8 generic: 6.6: (re-)add support multiple PPE to mtk_eth_soc
Now that the issue with WED has been sorted out, re-add support for
multiple PPE to the mtk_eth_soc driver.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-28 20:55:11 +01:00
Shiji Yang
007437c225 kernel: mtd: ubi: avoid attaching "linux,ubi" mtd again
"linux,ubi" compatible MTD device can be automatically attached early
since commit fc153aa8d9. Therefore, there is no need to attach MTD
devices named "ubi" or "data" again.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-28 20:55:11 +01:00
Christian Marangi
7c9644a7b5 bmips: backport upstreamed RAC patches
Replace downstream bmips RAC fixes with upstream patches.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
[backport upstream patches]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-27 17:59:31 +02:00
Bryan Berg
173d59e7dc
ipq806x: 6.6: enable at803x driver
Used by ethernet interfaces on AP3935i.

Signed-off-by: Bryan Berg <bdb@north-eastham.org>
Link: https://github.com/openwrt/openwrt/pull/13629
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-27 17:11:40 +02:00
Bryan Berg
bf0602f9c8
ipq806x: ap3935: Use rgmii-id mode for LAN1
Fix issue with LAN1 interface on ap3935 devices, where the LAN
1interface won't come up after boot unless the bootloader has
initialized the network stack. Use of `fixed-link` in the prior code
kept the driver from clobbering PHY settings, but now that the driver
supports rgmii-id phy-mode, we can just use that.

Signed-off-by: Bryan Berg <bdb@north-eastham.org>
Link: https://github.com/openwrt/openwrt/pull/13629
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-27 17:11:39 +02:00
Bryan Berg
e27c7e4b9b
ipq806x: ap3935: Use gmac0 mdio controller
Updates ap3935 target to use the mdio controller built-in to gmac0,
rather than having the SoC bit-bang mdio from gpio pins

Signed-off-by: Bryan Berg <bdb@north-eastham.org>
Link: https://github.com/openwrt/openwrt/pull/13629
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-27 17:11:39 +02:00
Hang Zhou
f637cf5ef7 bmips: add support for Sagem F@ST3864OP
Specifications:
* SoC: BCM63168
* RAM: NT5CC64M16GP-DI, DDR3 128MiB
* NAND: W29N01HVSINA, 128MiB
* Ethernet: 4x1000M LAN, 1x 1000M WAN
* Serial interface: on board but not populated, 3.3V, 115200, 8N1

Notes:
* Use DSA for VLAN and switches
* Ethernet ports and USB works
* gpio-leds are not working
* WLAN, xDSL, and FXS are not going to work

Signed-off-by: Hang Zhou <929513338@qq.com>
[refactor, reorder, drop unneeded or not working stuff]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-26 19:28:13 +02:00
Daniel Golle
646ebbd32c ramips: yuncore_g720: fix buttons
Turns out the device got two buttons, while the currently listed on is
actually WPS, and the other (will hidden) button is intended as RESET.
Update DT accordingly.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-25 20:42:54 +01:00
Álvaro Fernández Rojas
713319f779 bmips: sercomm,ad1018: remove unneeded LED default-state
Remove unneeded default-state from led_power_green (led@8) to be in line with
other bmips devices.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-25 17:43:40 +02:00
Álvaro Fernández Rojas
dc71b91c12 bmips: innacomm,w3400v6: remove unneeded LED default-state
Remove unneeded default-state from led_power_green (led@4) to be in line with
other bmips devices.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-25 17:43:32 +02:00
Christian Marangi
69f8647608
generic: 6.6: replace Aquantia pending LEDs patch with upstream version
Replace Aquantia pending LEDs patch with upstream version.
Sadly net maintainers didn't like integrated solution hence we still
need to handle LED restore on reset with custom solution.

Link: https://github.com/openwrt/openwrt/pull/15797
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-25 14:20:17 +02:00
Christian Marangi
f8cb39183d
qualcommax: fix RAX120v2 PWM Fan controller wrong definition
Fix RAX120v2 PWM Fan controller wrong definition by using a non-existant
kmod and using the wrong compatible for it enabling an external clock
while actually the device use an internal one.

Link: https://github.com/openwrt/openwrt/pull/15796
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-25 12:52:44 +02:00
Christian Marangi
be26643e91
generic: 6.6: backport patch for G671 PWM Fan controller support
Backport patch for G761 PWM Fan controller support. This is used by
an ipq807x RAX120v2 and have an internal clock that was currently
unconfigured making the device not working.

Link: https://github.com/openwrt/openwrt/pull/15796
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-25 12:52:43 +02:00
Christian Marangi
18e2c65aa9
ipq806x: fix broken line break with Linksys e8350-v1
Fix broken line break for Linksys e8350-v1 pushed with CRLF instead of
LF.

Fixes: 45b3c620e5 ("ipq806x: add support for Linksys e8350-v1")
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-25 12:20:14 +02:00
Sergey Filippov
45b3c620e5
ipq806x: add support for Linksys e8350-v1
AC2400 Dual-Band Gigabit Wi-Fi Router base on ipq8064.
https://www.linksys.com/support-product?sku=E8350

Specification:
 - Qualcomm dual-core IPQ8064 @ 1.4 GHz
 - 512 MB of RAM
 - 4 MB of SPI NOR MX25U3235F
 - 128 MB of NAND S34MS01G2
 - Qualcomm QCA9880 2.4GHz 802.11bgn
 - Quantenna QSR1000 5GHz 802.11ac (no support)
 - 4 x 10/100/1000 Mbit/s w/ vlan support Ethernet
 - Qualcomm Atheros QCA8337 switch
 - 1 x 3.0 + 1 x 2.0 (combo with eSata port)
 - 115200, 8N1 internal serial console
 - Power, Reset, WPS and WLAN buttons
 - Power, WPS and WLAN leds
 - 12 VDC, 3 A power

Installation:
The installation must be done using web interface of the router.
To achive this new firmware-utils tool was added to set correct
magic headers for the factory images.

Installation from vendor firmware:
 1. Flash over the native Linksys WEB interface using factory image.

Installation using recovery mode:
 1. Power off the device and disconnect the WAN port.
    (Only LAN port to be connected)
 2. Press & hold the "Reset" button
 3. Power on the device & wait 10 seconds with pressed "Reset" button
 4. Set IP Internet Protocol on your PC from
    192.168.1.0/24 network (Router is on IP 192.168.1.1)
 5. Open the Firmware Recovery page in your browser:
    http://192.168.1.1/index.shtml
    Firmware Recovery -> File Name -> Recovery & Reboot

The device page in inbox:
https://openwrt.org/inbox/toh/linksys/linksys_ea8350_1

Signed-off-by: Sergey Filippov <sergey.filippov@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/15798
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-25 11:57:14 +02:00
Álvaro Fernández Rojas
d514213336 bmips: drop kernel 6.1 support
kernel 6.1 can be dropped since 6.6 is the default kernel.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-25 09:43:07 +02:00
Álvaro Fernández Rojas
e340d4be4b bmips: switch default kernel to 6.6
Update default kernel version to 6.6 for the bmips devices.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-25 09:40:49 +02:00
Goetz Goerisch
166d28ffea bmips: add 6.6 kernel as testing
enable testing kernel version 6.6 for bmips

Signed-off-by: Goetz Goerisch <ggoerisch@gmail.com>
2024-06-25 09:36:33 +02:00
Álvaro Fernández Rojas
7a14fe0981 bmips: refresh 6.6 kernel config files
Refresh config for kernel 6.6.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-25 09:36:29 +02:00
Goetz Goerisch
57af1abbb6 bmips: 6.6: refresh kernel patches
refresh 6.6. kernel patches via 'make target/linux/refresh'

Signed-off-by: Goetz Goerisch <ggoerisch@gmail.com>
[refresh patches]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-24 22:12:46 +02:00
Goetz Goerisch
9b62791a10 bmips: 6.6: copy patches, config from 6.1
copy the 6.1 config to 6.6

Signed-off-by: Goetz Goerisch <ggoerisch@gmail.com>
2024-06-24 22:12:46 +02:00
Álvaro Fernández Rojas
8e1316f3f6 generic: 6.6: backport mips kexec dependency fix
Backport upstream fix for incorrect ifdeffery and dependency of CONFIG_KEXEC,
which causes compilation errors with the following symbols:
CONFIG_CRASH_CORE=y
CONFIG_KEXEC_CORE=y
CONFIG_CRASH_DUMP=y

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-24 19:37:37 +02:00
Robert Marko
85d9fd6f0e mvebu: add support for RB5009UG+S+IN
This patch adds support for Mikrotik RB5009UG+S+IN.

Specifications:
  - SoC: Marvell Armada 7040 (88F7040) - 4 cores, ARMv8 Cortex-A72, 1.4GHz, 64bit
  - RAM: 1024MB DDR4
  - Flash: 16MB SPI NOR flash, 1024MB NAND
  - Ethernet:
  	* Marvell 88E6393X - Amethyst:
  	* one 2.5G RJ45 port via Qualcomm QCA8081 PHY
  	* seven 1G RJ45 ports via built-in PHY-s
  	* one 10G SFP+ cage
  	* All ports share the same 10G switch uplink to the CPU
  - LED: User, SFP, Hdr1, Hdr2
  - Buttons: Reset
  - UART: 115200 8n1 on the MikroTik 16 pin header
  - USB: One USB3 port
  - Power: 24-57 V via
  	* DC jack
  	* 802.3af/at PoE on Ethernet 1
  	* 2-pin terminal on the side

16 Pin header pinout:
1   GND Vcc  RX  ?  GND
   #--------------------#
   |.-. .-. .-. .-. .-. |
   |'-' '-' '-' '-' '-' |
   |.-. .-. .-. .-. .-. |
   |'-' '-' '-' '-' '-' |
   #--------------------#
2   CLK  DO /CS  TX  DI

Do note that the default RouterBoot has disabled UART even when the
required hard-config bit is set to indicate UART support.
Patched RouterBoot must be used if UART is desired.

Also, since ARM64 Linux support does not support in any way appending the
DTB to the kernel image we use mainline U-Boot with added RB5009 support
in order to boot OpenWrt.
MikroTik uses YAFFS to store the boot kernel and we use YAFUT to put U-Boot
as the kernel which RouterBoot then simply boots as an ELF.

Install instructions:

NOTE: In case you are using an existing out of tree version of OpenWrt make
sure to reinstall RouterOS via Netinstall to return the expected partition
layout.

1. Prepare FAT or EXT4 formatted USB drive with OpenWrt initramfs:
* Copy bin/targets/mvebu/cortexa72/openwrt-mvebu-cortexa72-mikrotik_rb5009-initramfs-uImage.itb
to the root of FAT or EXT4 formatted USB drive.
* Plug in the drive to the RB5009 USB port

2. Boot the modified OpenWrt built U-Boot ELF:
u-boot.elf from bin/targets/mvebu/cortexa72/u-boot-rb5009/u-boot.elf

Consult OpenWrt wiki for common instructions on switching to boot from
Ethernet once as well as serving the file:
https://openwrt.org/toh/mikrotik/common

Once U-Boot is booted it will attempt to boot in the following order:
1. NAND
2. USB
3. Network

NAND is expected to fail but USB or Networking need to serve the OpenWrt
initramfs image and after booting it will be accessible from LAN ports
on the default 192.168.1.1 IP with default credentials.

3. Flash modified RouterBoot that enables UART (Optional but recommended):
https://public.robimarko.eu/RB5009/70x0-7.15-uart.fwf

* Copy the file over to the booted OpenWrt initramfs to /tmp
* Run: mtd erase RouterBOOT-primary
* Run: mtd write /tmp/70x0-7.15-uart.fwf RouterBOOT-primary

4. Install U-Boot to boot OpenWrt:
* Copy the u-boot.elf from bin/targets/mvebu/cortexa72/u-boot-rb5009/u-boot.elf
to OpenWrt initramfs to /tmp.
* Run: . /lib/functions.sh
* Run: yafut -d /dev/mtd$(find_mtd_index "YAFFS") -w -i /tmp/u-boot.elf -o kernel -T
This will use yafut to copy the U-Boot as kernel in YAFFS so that RouterBoot boots it.

5. Wipe the NAND UBI partition:
* Run: ubiformat /dev/mtd$(find_mtd_index "ubi") -y
This will prepare the existing RouterOS rootfs partition for OpenWrt.

6. Flash OpenWrt:
* Copy the bin/targets/mvebu/cortexa72/openwrt-mvebu-cortexa72-mikrotik_rb5009-squashfs-sysupgrade.bin
to OpenWrt initramfs to /tmp.
* Run: sysupgrade /tmp/openwrt-mvebu-cortexa72-mikrotik_rb5009-squashfs-sysupgrade.bin

Device will reboot, boot U-Boot and then OpenWrt.

Recovery:

In case you need to reinstall OpenWrt if it crashes after U-Boot, there is
a recovery mechanism in OpenWrt to boot the OpenWrt initramfs.
You need to hold the reset button while U-Boot is booting and then it will
boot the OpenWrt initramfs from:
1. USB
2. Networking

In recovery mode U-Boot will light all of the LED-s except for the switch
ones.

In case you want to return to RouterOS, you can simply do that via
Netinstall like on any other MikroTik board.

Credits also go to Serhii Serhieiev <adron@mstnt.com> who origininally
figured out the RouterBoot modification for UART, the missing 10G MVPP2
support in U-Boot as well as the custom aux loader to boot directly via
RouterBoot.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
b5004bac84 mvebu: cortex-a72: enable MikroTik NVMEM layout driver
RB5009 will take advantage of the driver to get MAC adress.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
62fa12e3c9 mvebu: cortex-a72: enable U-Boot NVMEM driver
In order to not have to ship envtools configuration per board, we can
instead rely on the kernel U-Boot environment NVMEM driver through which
envtools can read/write the environement.

Since size difference is negligeble and this subtarget has rather large
storage regardless, enable it by default.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
9f2b2d8dcd mvebu: cortex-a72: enable MikroTik platform drivers and NOR variable erase
MikroTik RB5009 will be using advantage of the MikroTik platform drivers,
RouterBoot partition parser and SPI NOR variable erase support.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
2b316f4e22 mvebu: cortex-a72: enable ARM SBSA Generic Watchdog
Marvell 70x0 and 80x0 both have ARM SBSA Generic Watchdog built-in,
so lets enable the required driver for them.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
8be64365c4 mvebu: cortex-a72: enable QCA8081 PHY support
MikroTik RB5009 uses Qualcomm QCA8081 PHY for the 2.5G RJ45 port,
so we need to enable the driver for it.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
215a3ca2a4 treewide: refresh patches
These need to be refreshed, probably the generic backports affected them.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
f04e377a50 generic: backport QCA808x possible interfaces fix
QCA808x does not currently fill in the possible_interfaces.

This leads to Phylink not being aware that it supports 2500Base-X as well
so in cases where it is connected to a DSA switch like MV88E6393 it will
limit that port to phy-mode set in the DTS.

That means that if SGMII is used you are limited to 1G only while if
2500Base-X was set you are limited to 2.5G only.

Populating the possible_interfaces fixes this, so lets backport the patches
from kernel 6.9.

This also includes a backport of the Phylink PHY validation series from
kernel 6.8 that allows the use of possible_interfaces.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Robert Marko
568a3db8ee generic: 6.6: backport Marvell Amethyst SMI GPIO setup
Marvell Amethyst switches use a different SMI GPIO pin setup than other
switches, and since RB5009 uses Amethyst switch and its SMI bus to talk
to QCA8081 lets backport the required fix from kernel 6.9.

Link: https://github.com/openwrt/openwrt/pull/15765
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-24 09:46:19 +02:00
Álvaro Fernández Rojas
6d29378eb5 bcm27xx: drop upstream patch that breaks rpi5 wifi
As reported in the following issue, this patch breaks wifi on the RPi 5.
https://github.com/raspberrypi/linux/issues/6237

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-24 05:48:44 +02:00
Álvaro Fernández Rojas
ea2ff25d4c generic: 6.6: backport upstream r8169 patches
Backport a bunch of upstream r8169 patches:
- RTL8168/RTL8101 LEDs support.
- RTL8126A support.
- RTL8125/RTL8126 LEDs support.
- RTL8168M support.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-24 05:36:14 +02:00
Robert Marko
a47650e4cb qualcommax: get rid of custom socinfo.h header
Now that SSDK has been updated to use in-kernel SMEM ID-s to identify
the SoC its running on instead of relying on the downstream socinfo.h
header we can move the read_ipq_soc_version_major() function directly to
cpr3-util.c as its the only user of anything from the header and drop it.

Link: https://github.com/openwrt/openwrt/pull/15786
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-23 23:09:54 +02:00
Shiji Yang
354690ebc9 ath79: remove SPI driver link order hack
This hack is used to make sure that the mfd device starts before the
mtd driver[1]. Now the linux driver framework "struct spi_driver {}"
can always ensure this.

[1] 47f8fd1dde ("ar71xx: rewrite SPI drivers for the RB4xx boards")

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-23 21:04:20 +02:00
Shiji Yang
f444dea428 ath79: remove GPIO driver earlier registration hack
After porting the ar71xx target to the new ath79 target, we are now
using the device tree instead of the device mach file. And the
platform drivers already support deferred probe. So there is no need
to keep it.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-23 21:04:20 +02:00
Kristian Skramstad
87a45ea432 kernel: qca-ssdk: update 12.5 to 2024-06-13
There are some new commits, so refresh and update patches.
Some build warnings have been fixed upstream too.

Add backport target/linux/generic/backport-6.6/722-v6.10-dt-bindings-arm-qcom-ids-Add-SoC-ID-for-IPQ5321.patch.

Removed upstream:
[-] qca-ssdk/patches/101-hsl_phy-add-support-for-detection-PSGMII-PHY-mode.patch
[-] qca-ssdk/patches/201-fix-compile-warnings.patch

List of changes:
2024-04-16  -c451136b-  qca-ssdk: strip MRPPE code
2024-06-05  -f455a820-  [qca-ssdk]: fix enum-int-mismatch warnings
2024-05-31  -bbfc0fa9-  Merge "[qca-ssdk]: update eee status of phydev"
2024-05-31  -adbe9dc5-  Merge "[qca-ssdk]: support psgmii and uqsxgmii mode of kernel"
2024-05-31  -d06ca777-  Merge "[qca-ssdk]: fix 5G issue with the AQR FW that use 5gbaser for 5G speed"
2024-05-31  -c6f539a5-  Merge "qca-ssdk: support mrppe pktedit padding functions"
2024-04-29  -c321e2a9-  qca-ssdk: support mrppe pktedit padding functions
2024-05-24  -ee6e201e-  qca-ssdk: Fix the big endian compile error
2024-05-15  -8c116bb9-  [qca-ssdk]: update eee status of phydev
2024-05-20  -f0341a2c-  Merge "qca-ssdk: Enable igmp for PPE MINI profile"
2024-05-16  -44a0ce93-  qca-ssdk: Enable igmp for PPE MINI profile
2024-05-15  -8b91bbf6-  [qca-ssdk]: support psgmii and uqsxgmii mode of kernel
2024-05-14  -7eec1658-  [qca-ssdk]: fix 5G issue with the AQR FW that use 5gbaser for 5G speed
2024-05-12  -b9f5ea0e-  [qca-ssdk]: ethtool support, do not change wake-up timer when the requested timer is 0
2024-05-09  -5e2c15ed-  Merge "[qca-ssdk]: remove check when mht clock enable"
2024-05-09  -a1563b90-  Merge "[qca-ssdk] support new sku IPQ5321"
2024-04-23  -f04b7680-  [qca-ssdk]: show unknown status when link down
2024-03-22  -33b91b30-  [qca-ssdk]: remove check when mht clock enable
2024-04-29  -b6362f2b-  Merge "qca-ssdk:fix bug in marina nptv6 iid cal"
2024-04-29  -097033ae-  Merge "[qca-ssdk] support cypress uniphy0 connecting MHT switch port0"
2024-04-24  -d45560fd-  qca-ssdk:fix bug in marina nptv6 iid cal
2024-04-24  -7d7a42af-  qca-ssdk: enable policer counter on low memory profile
2024-04-18  -e36cf6ea-  Merge "[qca-ssdk]: change portvlan egress mode initial value as untouched"
2024-04-18  -27817881-  Merge "[qca-ssdk]: update the aqr phy supported ability"
2024-04-18  -5a3a693c-  Merge "qca-ssdk:support marina nptv6"
2024-04-16  -129fe9b3-  Merge "qca-ssdk: support tunnel fields and innner fields inverse"
2024-01-09  -fc8f6abd-  qca-ssdk:support marina nptv6

Signed-off-by: Kristian Skramstad <kristian+github@83.no>
Link: https://github.com/openwrt/openwrt/pull/15771
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-23 17:42:17 +02:00
Zxl hhyccc
ed6935613e kernel: bump 6.1 to 6.1.95
https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.95

Removed upstreamed:
generic/pending-6.1/779-net-vxlan-don-t-learn-non-unicast-L2-destinations.patch
reference:
This patch can be removed. It will never return false. And the upstream commit should fix the same issue:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.1.95&id=a31d0e5deb1abe7c57c6457ae2502f278063126e

All other patches automatically rebased.

Build system: Kirkwood bcm53xx

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
2024-06-23 16:33:41 +02:00
Mathew McBride
bcbdde00c3 armsr: add realtek and smsc ethernet phy drivers to the default image
This adds two more common PHY brands to the image.
Realtek is used on the Google Coral "Phanbell" board (i.MX8MQ).
SMSC has been used on various Raspberry Pi boards.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2024-06-23 16:15:28 +02:00
Mathew McBride
8ef5d56121 armsr: armv8: enable NXP i.MX8MQ/P USB phy
Support for 'fsl,imx8mq-usb-phy' is needed for USB to work
on NXP i.MX8MQ and i.MX8MP platforms.

Tested with a Google Coral "Phanbell" board.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2024-06-23 16:15:28 +02:00
Mathew McBride
ea7383e721 armsr: enable framebuffer emulation for virtio-gpu/drm displays
This was discovered when trying to run OpenWrt on Hetzner Cloud's
Arm-based instances.

Hetzner uses QEMU/KVM with virtio-gpu as the main display device,
together with an ACPI firmware. This was not displaying a console
previously.

This setup can be emulated by qemu using options below:
qemu-system-aarch64 \
    -machine virt \
    -bios QEMU_EFI.fd \
    -device virtio-gpu \
    -usb \
    -device qemu-xhci,id=xhci \
    -device usb-tablet,bus=xhci.0 \
    -device usb-kbd,bus=xhci.0 \
    -vnc :0

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2024-06-23 16:15:28 +02:00
Mathew McBride
4468c2f4bd kernel/armsr: disable NXP i.MX9 PMU related option
This PMU (performance management unit) related kernel option
can appear under certain kernel configurations (such as
KVM being enabled).

Disable them, as we do with other PMU-related options.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2024-06-23 16:15:28 +02:00
Robert Marko
0ed72c271b uml: fix glibc-static check with GCC14
Running the glibc-static check with GCC14 as the host compiler will fail:
Please install a static glibc package. (Missing libutil.a, librt.a or libpthread.a)

However, this error will get printed even with the required static
libraries installed when GCC14 is used.

Manually running the check exposes the real error:
<stdin>: In function ‘main’:
<stdin>:1:45: error: implicit declaration of function ‘timer_gettime’ [-Wimplicit-function-declaration]

GCC14 now errors on implicit declarations by default, so lets add the
required time.h header to fix compilation and thus the check.

Link: https://github.com/openwrt/openwrt/pull/15778
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-22 22:06:06 +02:00
John Audia
832e2f6dd0 kernel: bump 6.6 to 6.6.35
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.35

Removed upstreamed:
	bcm27xx/patches-6.6/950-1135-ax25-Fix-refcount-imbalance-on-inbound-connections.patch[1]

Removed no longer needed:
	generic/pending-6.6/779-net-vxlan-don-t-learn-non-unicast-L2-destinations.patch[2]

All other patches automatically rebased.

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

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.35&id=52100fd74ad07b53a4666feafff1cd11436362d3
2. As suggested by @DragonBluep, "This patch can be removed. It will never return false. And the upstream commit should fix the same issue: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit?h=v6.6.35&id=924f7bbfc5cfd029e417c56357ca01eae681fba6"

Signed-off-by: John Audia <therealgraysky@proton.me>
2024-06-22 16:50:57 +02:00
Tim Harvey
5f307b29cd imx: 6.6: add upstream patches for imx8m{m,n,p} venice
Add a set of upstream patches for the imx8m{m,n,p} based Venice
boards.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/15736
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-22 16:29:39 +02:00
Tim Harvey
176b8df701 imx: coretexa53: fix network configuration for GW74xx
The GW74xx's first RJ45 is eth0 which should be the WAN adapter, not
eth1 which is the CPU uplink port to the switch.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/15736
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-22 16:29:39 +02:00
Robert Marko
dcc4307205 qoriq: use 6.1 by default and drop 5.15
qoriq has had kernel 6.1 as testing for 2 months now, so lets default to
it and drop 5.15 support.

Link: https://github.com/openwrt/openwrt/pull/15767
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-21 20:27:53 +02:00
Robert Marko
73a9f9f857 generic: platform/mikrotik: add NVMEM layout driver
Currently, information from MikroTik hard_config is only available via
sysfs, meaning that we have to rely on userspace to for example setup MACs.

So, lets provide a basic NVMEM layout based driver to expose the same cells
as sysfs driver exposes.

Do note that the we dont extract the WLAN caldata and BDF-s at this point.

Reviewed-by: Thibaut VARÈNE <hacks@slashdirt.org>
Link: https://github.com/openwrt/openwrt/pull/15665
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-20 15:53:55 +02:00
Robert Marko
6527619395 generic: platform/mikrotik: move hard config tag ID-s to a header
Move the hard config tag ID-s to a separate header so they can be reused
by the NVMEM driver as well.

Link: https://github.com/openwrt/openwrt/pull/15665
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-20 15:53:55 +02:00
Shiji Yang
bc56334428 ath79: trim useless package kmod-leds-reset for some devices
Only NETGEAR WNDR3x00 series devices have reset controller LED.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-20 14:02:13 +02:00
Shiji Yang
5901598586 ath79: disable unnecessary driver CONFIG_LEDS_RESET
This driver has already been packed as a software package. There is
no need to build it into the kernel.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-20 14:02:13 +02:00
Shiji Yang
66b41c4afd ath79: add back usb LED label for NETGEAR WNDR3x00 devices
The "reset-leds" driver does not support parsing color and function
properties.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-20 14:02:13 +02:00
Álvaro Fernández Rojas
0a07a3a13d
bcm27xx: fix malformed upstream arm64 DT patch
This patch was causing buildbot issues when copying arm64 DT files since
bcm283x-rpi-csi1-2lane.dtsi and bcm283x-rpi-lan7515.dtsi were linked to
"../../../../arm/boot/dts/" instead of "../../../../arm/boot/dts/broadcom".
These files aren't needed, so let's remove them instead of fixing them.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15762
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-20 05:55:08 +02:00
Robert Marko
150d0ceab7 ath79: ag71xx: support probe defferal for getting MAC address
Currently, of_get_ethdev_address() return is checked for any return error
code which means that trying to get the MAC from NVMEM cells that is backed
by MTD will fail if it was not probed before ag71xx.

So, lets check the return error code for EPROBE_DEFER and defer the ag71xx
probe in that case until the underlying NVMEM device is live.

Link: https://github.com/openwrt/openwrt/pull/15752
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-20 11:11:36 +02:00
Matthias Schiffer
0b6b54eca9 ipq40xx: net/ipqess: fix outbound port tag computation
Since the introduction of out-of-band tagging, writing the outbound tag
had been completely broken: First, in place of a port mask containing
the port number, just the port number itself was set in the register
value. Just after that, the full port mask 0x3e (all 5 external ports)
was set unconditionally.

This remained unnoticed because the switch would then use the FDB to
decide where to send unicast packets; broadcast and multicast packets
were however sent to every port.

Fix the port tag computation and only use the full port mask as a
fallback for non-DSA mode, as it was done in the older driver patches
used on Linux 5.15.

Fixes: cd9c721124 ("ipq40xx: 6.1: use latest DSA and ethernet patches")
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-20 10:52:26 +02:00
Zxl hhyccc
b004feaafb kernel: bump 6.1 to 6.1.94
https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.94

All other patches automatically rebased.

Build system: Kirkwood bcm53xx

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
2024-06-20 10:41:50 +02:00
Martin Schiller
f6fe19ed6d lantiq: fix pci driver once again
In my previous attempt to solve the PCI problems for the lantiq targets,
I did not pay attention to the fact that the original accesses to the
GPIO took place in RAW mode. As a result, the polarity defined in the
device trees (apart from the initial value) was irrelevant.

In addition, the expected name of the GPIO in the dts has changed due to
the upstream change and therefore no RESET is currently performed.

As discussed in [1] on the linux-mips mailing list, we will now adapt
the dts files accordingly instead of patching the driver:

- dts property will be renamed to "reset-gpios"
- Polarity is set to "GPIO_ACTIVE_LOW".

I have verified this with a TP-Link TD-W8980. The PCI device is now
recognized by the system.

[1] https://patchwork.kernel.org/project/linux-mips/patch/20240607090400.1816612-1-ms@dev.tdt.de/

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Tested-by: Aleksander Jan Bajkowski <olek2@wp.pl> # Tested on AVM 7330 (ar9)
Link: https://github.com/openwrt/openwrt/pull/15731
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-20 09:56:50 +02:00
Daniel Golle
5e7955171c generic: backport pending driver for Winchip CH348 USB serial
Import patch and package kernel module for Winchip CH348
USB-to-8x-UART chip.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-20 01:11:09 +01:00
Daniel Golle
c4e6a147a6 generic: 6.6: mt7530: add support for bridge port isolation
Import patches accepted upstream introducing port isolation feature
on MT7530 switches:
  - [net-next,v3,1/2] net: dsa: mt7530: factor out bridge join/leave logic
    https://git.kernel.org/netdev/net-next/c/c25c961fc7f3
  - [net-next,v3,2/2] net: dsa: mt7530: add support for bridge port isolation
    https://git.kernel.org/netdev/net-next/c/3d49ee2127c2

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-20 01:11:09 +01:00
John Audia
a09a72d86d kernel: bump 6.6 to 6.6.34
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.34

Removed upstreamed:
	backport-6.6/701-v6.8-net-sfp-bus-fix-SFP-mode-detect-from-bitrate.patch[1]

All other patches automatically rebased.

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

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.34&id=9399baa02e4b7f101c39fdbc4d681d54bca4465b

Signed-off-by: John Audia <therealgraysky@proton.me>
2024-06-20 01:55:19 +02:00
Álvaro Fernández Rojas
6fdf3a32d9 bcm27xx: base-files: diag: fix LEDs
At some point RPi LEDs were renamed from led0/led1 to PWR/ACT.
This patch fixes this and also automatically detects the status_led without
relying on board_name.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-19 20:07:08 +02:00
Álvaro Fernández Rojas
68f7ca23fb bcm27xx: drop kernel 6.1 support
kernel 6.1 can be dropped since 6.6 is the default kernel.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-19 19:36:09 +02:00
Álvaro Fernández Rojas
98cfff4745 bcm27xx: switch default kernel to 6.6
Update default kernel version to 6.6 for the Raspberry Pi devices.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-19 19:36:09 +02:00
Robert Marko
070b87e7ac ath79: mikrotik: set compat version for NAND devices
Currently, trying to upgrade on a MikroTik NAND device will force you to
use sysupgrade -n due to:
upgrade: The device is supported, but the config is incompatible to the new image (1.0->1.1). Please upgrade without keeping config (sysupgrade -n).
upgrade: NAND images switched to yafut. If running older image, reinstall from initramfs.

So instead of having users manually set the new compat version lets do
what other targets do and set it for all NAND devices after good boot.

Link: https://github.com/openwrt/openwrt/pull/15754
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-19 12:26:19 +02:00
Dave Brand
820823198d bcm27xx: add support for RPI A, A+, 3A+, Zero2 and Zero2W
These devices were already supported. I merely added missing entries to:
1. make them easier to locate in firmware selector
2. allow firmware upgrades to proceed without dire warnings

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

With this patch, the firmware upgrade proceeds normally.

Signed-off-by: Dave Brand <dbrand666@users.noreply.github.com>
2024-06-19 10:24:49 +02:00
Hauke Mehrtens
8e214d48b1 ramips: Fix DOS line endings
Convert line endings from DOS to Unix using dos2unix.

Fixes: 2da2705a44 ("ramips: add support for WINSTARS WS-WN536P3")
Fixes: 5560791bbd ("ramips: add support for OpenFi 5Pro Travel Router")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-06-19 00:01:41 +02:00
Álvaro Fernández Rojas
157c7bd50c bcm27xx: remove 6.6 CONFIG_ARCH_BCM_63XX symbol
This symbol was removed upstream, but it was present on bcm27xx due to a
malformed upstream RPi patch.

Fixes: 8c405cdccc ("bcm27xx: add 6.6 kernel patches")
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-18 21:58:29 +02:00
Álvaro Fernández Rojas
2cd6da257c bcm27xx: enable 6.6 testing kernel
The bcm27xx now supports 6.6 kernel as testing.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-18 19:00:51 +02:00
Álvaro Fernández Rojas
670bb13649 bcm27xx: refresh 6.6 kernel config files
Refresh config for kernel 6.6 and add missing symbols.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-18 19:00:44 +02:00
Álvaro Fernández Rojas
8c405cdccc bcm27xx: add 6.6 kernel patches
The patches were generated from the RPi repo with the following command:
git format-patch v6.6.34..rpi-6.1.y

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

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-18 18:52:49 +02:00
Álvaro Fernández Rojas
e8067fa108 bcm27xx: copy kernel config from 6.1 to 6.6
This is preparation for 6.6 kernel support. Copying files makes it easier to
track their git history.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-18 18:52:49 +02:00
Mieczyslaw Nalewaj
7ccd7dac7e
generic: replace spi Silicon Labs patch with upstream version
Replace Silicon Labs patch with upstream version as they got merged in
kernel 6.3.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
[ rework commit title and description, use better patch ]
Link: https://github.com/openwrt/openwrt/pull/15300
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-18 14:14:38 +02:00
Robert Marko
70088a7e4c
mvebu: uDPU/eDPU: mount F2FS with ZSTD compression
Now that we can pass the desired compression via cmdline, pass ZSTD as the
desired compression algorithm for F2FS.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2024-06-17 20:16:20 +02:00
Robert Marko
149a1ab273
mvebu: uDPU/eDPU: mount misc partition with ZSTD compression
F2FS requires the compression algorith to be passed as argument while
mounting, so lets do so for the misc partition.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2024-06-17 20:16:20 +02:00
Robert Marko
23191b4075
mvebu: uDPU/eDPU: format F2FS partitons with compression support
In order to prolong the eMMC life and utilize ZSTD compression on Methode
devices, we must format the F2FS rootfs and misc partition with xattr and
compression support feature flags first.

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

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2024-06-17 20:16:20 +02:00
Robert Marko
793b925f8b
mvebu: cortexa53: include mkfs.f2fs and fdisk for sysupgrade
Methode devices require mkfs.f2fs in order to format rootfs and misc
partitions if they have not already been formatted.
fdisk is required if partition table got broke so it can be regenerated.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2024-06-17 20:16:19 +02:00
Robert Marko
ae358b8489
mvebu: cortexa53: enable F2FS ZSTD compression support
We would love to utilize ZSTD compression support in F2FS on the
Methode euroDPU so lets enable the required kernel support.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2024-06-17 20:16:19 +02:00
Daniel Golle
e3afc7047b generic: 6.6: refresh patches
Refresh patches as line numbers changed with newer upstream version
since original backport PR was opened.

Fixes: a5c095c453 ("generic: 6.6: replace (broken) downstream patch with upstream solution")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-17 15:03:47 +01:00
Daniel Golle
a5c095c453
generic: 6.6: replace (broken) downstream patch with upstream solution
Our downstream patch "net/core: add optional threading for backlog processing"
has been broken with the switch to Linux 6.6.
Replace it by backporting the now available upstream solution.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Link: https://github.com/openwrt/openwrt/pull/15592
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 13:31:20 +02:00
Christian Lamparter
9328817e75
uml: drop 6.1 kernel support files
Drop config+patches for kernel 6.1.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15713
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 12:59:06 +02:00
Christian Lamparter
85f6deb4e8
uml: switch to 6.6 kernel
Switch the uml target to kernel 6.6.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15713
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 12:59:06 +02:00
Christian Lamparter
cef30e225d
uml: define "generic" subtarget
UML didn't have a subtarget defined.

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

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

Fixes: d997477775 ("treewide: remove implicit SUBTARGET")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15713
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 12:59:05 +02:00
Christian Lamparter
76dabadda8
apm821xx: drop 6.1 kernel support files
Drop config+patches for kernel 6.1.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15721
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 12:58:41 +02:00
Christian Lamparter
02d47af19e
apm821xx: switch to 6.6 kernel
Switch the apm821xx targets to kernel 6.6.
no complains received.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15721
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 12:58:40 +02:00
Rosen Penev
6ff598306f
treewide: gpio to gpios
gpio is deprecated. Found with dtc's -Wdeprecated_gpio_property

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

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/15681
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-17 12:57:06 +02:00
Andrew Smith
9745de82d5 qualcommax: ipq807x: use ath11k_patch_mac for SXK80
Use ath11k_patch_mac and ath11k_set_macflag functions for SXK80

Signed-off-by: Andrew Smith <gul.code@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/15732
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-17 12:35:07 +02:00
John Vincent
531b3f667c kernel: armsr: Renesas: RZ: Ethernet module and ttySC0
Ethernet module enable for Renesas RZ platform
inittab fix for ttySC0

Fixes: #15284
Signed-off-by: John Vincent <john.vincent.xa@bp.renesas.com>
2024-06-17 00:10:53 +02:00
Sven Huang
5560791bbd ramips: add support for OpenFi 5Pro Travel Router
OpenFi 5Pro is a DualBand Travel Router, based on MT7621A.

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

How to upgrade image in uboot

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

Signed-off-by: Sven Huang <1036456939@qq.com>
2024-06-17 00:01:51 +02:00
Sven Huang
2da2705a44 ramips: add support for WINSTARS WS-WN536P3
WS-WN536P3 is a 2.4/5 GHz band 11ac router, based on MT7621DA.

Specification:

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

How to upgrade image in uboot

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

Signed-off-by: Sven Huang <1036456939@qq.com>
2024-06-16 23:42:59 +02:00
Mieczyslaw Nalewaj
098be45d02 kernel: generic: refresh patches
Refresh patches by 'make target/linux/refresh'

Fixes: 487cc3831c ("generic: 6.6: drop patch adding support for multiple MTK PPE")
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 23:02:25 +02:00
Shiji Yang
6fd8cca172 ath79: diable some 6 MiB image size TP-Link devices
The max image sizes are too small to generate images.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-16 22:10:37 +02:00
Shiji Yang
4309be6bcb ath79: drop factory image for DIR-825 and TEW-673GRU
The max image sizes are too small to generate factory images.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-16 22:10:37 +02:00
Milinda Brantini
c95ed79787 rockchip: Add cache information to the SoC dtsi for RK356x
Fix cacheinfo: Unable to detect cache hierarchy for CPU 0.

Signed-off-by: Milinda Brantini <C_A_T_T_E_R_Y@outlook.com>
2024-06-16 21:59:11 +02:00
Mieczyslaw Nalewaj
b0d418035e ramips: tplink_8m: cleaning up nvmem-cells definitions
Move nvmem-cells definitions to dts files for compatibility with other files
in which mt7628an_tplink_8m.dtsi is loaded, to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Mieczyslaw Nalewaj
3ce71a1ead ramips: netgear_r6xxx: cleaning up nvmem-cells definitions
Move nvmem-cells definitions to dts files to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Mieczyslaw Nalewaj
fd610a2083 ramips: elecom_wrc-gs-1pci: cleaning up nvmem-cells definitions
Move nvmem-cells definitions to dts files to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Mieczyslaw Nalewaj
c54ce12a74 ramips: cudy_x6: cleaning up nvmem-cells definitions
Move nvmem-cells definitions to dts files to prevent overwriting

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Mieczyslaw Nalewaj
e750c22904 ramips: xiaomi,mi-ra75: cleaning up nvmem-cells definitions
Remove nvmem-cells definitions due to duplication
in mt7628an_xiaomi_mi-router-4.dtsi

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Mieczyslaw Nalewaj
3504667bbe ramips: tplink,archer-c2-v1: cleaning up nvmem-cells definitions
Remove nvmem-cells definitions due to duplication
in mt7620a_tplink_8m.dtsi

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Mieczyslaw Nalewaj
e125cf5a8c ramips: hiwifi,hc5861: cleaning up nvmem-cells definitions
Remove nvmem-cells definitions due to duplication
in mt7620a_hiwifi_hc5x61.dtsi

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
2024-06-16 21:24:11 +02:00
Daniel Golle
487cc3831c generic: 6.6: drop patch adding support for multiple MTK PPE
Partially revert commit 98ddfbc56a ("generic: 6.6: backport upstream
commits for mtk_eth_soc") as the commit breaks WED. A better solution to
assign PPE units in case of WED has still to be found.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-16 18:41:40 +01:00
Daniel Golle
94e0190082 generic: 6.6: update NVMEM-on-MMC series
Allow a wider audience to test this pending series.

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

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

Fixes: #15642
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-16 13:28:01 +01:00
Daniel Golle
4fd4be6bbe generic: 6.6: move NVMEM-on-UBI patches from pending to backports
The series was merged for Linux v6.9, so move it to backports.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-16 13:28:01 +01:00
Daniel Golle
98ddfbc56a generic: 6.6: backport upstream commits for mtk_eth_soc
Backport two commits for mtk_eth_soc:
 * net: ethernet: mtk_eth_soc: handle dma buffer size soc specific
   (torvalds/linux@c57e558194)
 * net: ethernet: mtk_eth_soc: ppe: add support for multiple PPEs
   (torvalds/linux@dee4dd10c7)

Refresh pending patches which require that.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-16 13:28:01 +01:00
David Bauer
e321e70ddc mpc85xx: fix label-mac-address for Enterasys WS-AP3710i
The WS-AP3710i does not correctly expose its label-mac on eth0 anymore
since the change to simpleLoader.

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

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-16 14:02:19 +02:00
Shiji Yang
05aec66d53 ramips: fix MAC address for some devices
1. Remove unused macaddr NVMEM cells.
2. Fix "mac-base" compatible cells references.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-15 22:54:52 +02:00
John Audia
f34620f146 kernel: bump 6.6 to 6.6.33 and adjust subarches
This commit accomplishes three goals:
1. bump 6.6 to 6.6.33
2. kernel: modules: video: change package definition for fb for
   upstream changes[1]
3. kernel/multiple subtargets: add CONFIG_FB_IOMEM_FOPS=y to all
   subtargets which also set CONFIG_FB_CORE=y.

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

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

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

All other patches automatically rebased.

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

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

Tested-by: Stijn Segers <foss@volatilesystems.org>
Signed-off-by: John Audia <therealgraysky@proton.me>
2024-06-15 22:44:06 +02:00
Zxl hhyccc
fc9cb9b609 kernel: bump 6.1 to 6.1.93
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.93

Removed upstreamed:
bcm27xx/patches-6.1/950-0081-smsx95xx-fix-crimes-against-truesize.patch
reference: 517e64bcc9

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

All other patches automatically rebased.

Build system: bcm53xx ath79

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
2024-06-15 19:55:01 +08:00
David Bauer
22f92cce22 mpc85xx: fix Enterasys WS-AP3710i eth mac-address
With the introduction of the simpleImage loader, the MAC address is not
set by the bootloader anymore.

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

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-14 23:33:06 +02:00
Shiji Yang
2db6459ed4 ath79: fix MAC address for senao loader devices
The "mac-base" nvmem-cell-cells size is 1.

Fixes: b2f1c6ed52 ("ath79: qca: remove mac-address-increment")
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-14 21:05:19 +02:00
Shiji Yang
4fdc7bb8f1 ath79: switch default kernel to 6.6
We haven't received any bug reports in the past few weeks. So it's
time to set kernel 6.6 as the default and remove kernel 6.1 support.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-14 17:38:09 +02:00
Shiji Yang
bcbf666f69 ath79: refresh 6.6 kernel config
Add the missing kernel symbols by
`make kernel_oldconfig CONFIG_TARGET={target,subtarget}`.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-14 17:38:09 +02:00
Hauke Mehrtens
99aa86ef85 bcm47xx: Remove profiles for broadcom-wl
The broadcom-wl driver was removed from OpenWrt, remove also the
profiles using it.

Fixes: e772b75d5d ("broadcom-wl: remove package")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-06-14 14:54:16 +02:00
Hauke Mehrtens
2beea2943b bcm47xx: Remove exports for braodcom-wl driver
The braodcom-wl driver was removed from OpenWrt, remove the special
exports it needed.

Fixes: e772b75d5d ("broadcom-wl: remove package")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-06-14 14:54:16 +02:00
Mikhail Zhilkin
ef845675f5 ramips: fix wrong dts file permission
This file is executable:
   target/linux/ramips/dts/mt7621_dlink_dir-2150-a1.dts
Has to be fixed.

Fixes: 30e8fd73ec ("ramips: Add support for D-Link DIR-2150-A1")
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
2024-06-14 14:44:04 +02:00
Mikhail Zhilkin
61dce63c04 ramips: fix random LAN MAC for sercomm dxx devices
This commit fixes random lan mac for sercomm dxx devices.

Fixes: 3395184825 ("ramips: mt7621: nix mac-address-increment")
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
2024-06-14 14:43:07 +02:00
Mikhail Zhilkin
24d2519755 ramips: fix wrong eeprom data for sercomm dxx devices
This commit fixes wrong WiFi eeprom data:
   /sys/kernel/debug/ieee80211/phy0/mt76/eeprom
   /sys/kernel/debug/ieee80211/phy1/mt76/eeprom

Fixes: fb4cea45ec ("ramips: convert MT7603 EEPROM to NVMEM format")
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
2024-06-14 14:41:30 +02:00
Rosen Penev
932808ebde ath79: fix wrong mac address for ecb1xx0
0db4f9785c changed the variable name from
athaddr to ethaddr. Restore.

Fixes: 0db4f9785c ("ath79: convert ath10k calibration data to NVMEM (ASCII MAC)")
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-14 14:20:27 +02:00
Chukun Pan
0a76244a72 qualcommax: ipq807x: fix sysupgrade for ZBT-Z800AX
This router has two rootfs partitions and dualboot is used.
Vendor firmware may swap the rootfs partition location, u-boot append
'ubi.mtd=rootfs' in the end of cmdline. Since we use fixed-partitions,
force boot from the first rootfs partition to avoid boot failure.

Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Link: https://github.com/openwrt/openwrt/pull/15700
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-13 18:01:03 +02:00
Tony Ambardar
ce51f27fb0
kernel: 6.6: prevent garbage-cleanup of BPF kfuncs
Backport an upstream Linux fix to prevent BPF kfunc functions from being
removed during linker optimization when building BTF-enabled vmlinux.

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

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

Link: https://lore.kernel.org/bpf/ZlkoM6%2FPSxVcGM6X@kodidev-ubuntu/
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15697
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-13 14:16:34 +02:00
Kristian Skramstad
75a76355cb qualcommax: ipq807x: wax620 and wax630: fix wifi mac address
The wifi radios on wax620 and wax630 got a random mac
address on boot. So fix this by using ath11k_patch_mac
and give a static mac address from label-mac-device.

Tested and working on wax620 and wax630.

Signed-off-by: Kristian Skramstad <kristian+github@83.no>
Link: https://github.com/openwrt/openwrt/pull/15597
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-13 11:01:59 +02:00
Robert Marko
169a695280 octeontx: drop target
octeontx is currently stuck on kernel 5.15 since using 6.1 breaks booting,
and unfortunately nobody has stepped up to fix this issue.

Gateworks who were primary users have supported the removal.

Link: https://github.com/openwrt/openwrt/pull/15686
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-12 21:52:41 +02:00
Koen Vandeputte
167b016a21 ipq40xx: fix invalid GPIO numbers since kernel 6.6
The bump to kernel 6.6 increased the GPIO base from
412 to 512 on this target.

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

[   24.176183] export_store: invalid GPIO 423

Tested on a Wallys DR40x9 board.

Please note that:

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

Suggested-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Koen Vandeputte <koen.vandeputte@citymesh.com>
2024-06-12 14:25:56 +02:00
Sebastian Schaper
aa4d63c2da ramips: add support for 7Links WLR-1240
The WLR-1240 (ZX-5434) is an AC1200 Wave 2 outdoor repeater
with omnidirectional antennas for wall or pole mounting.
The device is manufactured by Todaair and meant to be used with
a tuya-based app, there is no webinterface for configuration.

Specifications:
- MT7628AN, 8 MiB SPI NOR flash, 64 MiB RAM, 2x2 802.11n
- MT7613 2x2 802.11ac Wave 2
- 802.3af PoE or 12V 1A 5.5x2.1 power supply (included)
- top RGB LED ring

TFTP installation:
- rename sysupgrade to `firmware_auto.bin`
- provide at 192.168.1.10 during boot

HTTP installation:
- keep reset button pressed for 5 seconds during power on (light blue
  LED flashes slowly, then quickly to confirm, then remains steady on)
- recovery web interface is at 192.168.1.1, upload sysupgrade

Opening the device
- use suction cup to remove top cap within LED ring
- two screws are located in holes underneath silicone sealant
- two further screws are located at the bottom

initramfs boot
- open device, connect serial console (pins are labelled)
- keep pressing `4` during second tftp attempt to enter uboot shell
- run `tftpboot 82000000` to avoid memory overlap, then `bootm`

Signed-off-by: Sebastian Schaper <openwrt@sebastianschaper.net>
2024-06-11 00:09:06 +02:00
Sebastian Schaper
3d6cbe287a ramips: add support for 7Links WLR-1230
The WLR-1230 (ZX-5207) is an AC1200 Wave 2 outdoor repeater
with sector antennas for wall or pole mounting.
The device is manufactured by Todaair and meant to be used with
a tuya-based app, there is no webinterface for configuration.

Specifications:
- MT7628AN, 8 MiB SPI NOR flash, 64 MiB RAM, 2x2 802.11n
- MT7613 2x2 802.11ac Wave 2
- 802.3af PoE or 12V 1A 5.5x2.1 power supply (included)
- 3 LEDs WLAN, LAN, RES; PWR LED is not software-controllable

TFTP installation:
- rename sysupgrade to `firmware_auto.bin`
- provide at 192.168.1.10 during boot

HTTP installation:
- keep reset button pressed for 5 seconds during power on (LEDs
  flash slowly, then quickly to confirm, then remain steady on)
- recovery web interface is at 192.168.1.1, upload sysupgrade

Opening the device
- two screws are located in the bottom left and right corners
  underneath the label, inner tray slides out easily

initramfs boot
- open device, connect serial console (pins are labelled)
- keep pressing `4` during second tftp attempt to enter uboot shell
- run `tftpboot 82000000` to avoid memory overlap, then `bootm`

Signed-off-by: Sebastian Schaper <openwrt@sebastianschaper.net>
2024-06-11 00:09:06 +02:00
Hauke Mehrtens
5be9a8790c mediatek: Ruijie RG-X60 Pro: Add kmod-mt7915e
Add the kmod-mt7915e wifi driver to the default packages for the Ruijie
RG-X60 Pro. kmod-mt7915e has to be added recently and was not done
before merging the support for Ruijie RG-X60 Pro.

Fixes: 3de3c2bdfa ("mediatek: add support for Ruijie RG-X60 Pro")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-06-10 12:42:23 +01:00
Luis Mita
d780d530dd ramips: mt76x8: sync Cudy TR1200 v1 naming
Cudy assigns hardware versions to its devices on its website, and
the Cudy TR1200 router is now Cudy TR1200 v1.
OpenWrt currently uses both variants, and this commit removes
inconsistencies using only the new name.

Signed-off-by: Luis Mita <luis@luismita.com>
2024-06-10 10:13:56 +02:00
Tianling Shen
0397932fdd mediatek: convert eeprom/macaddr to nvmem format for jdcloud re-cp-03
Switch to new nvmem binding.

Also fixes a issue that the MAC address assigned to lan/wan was reversed.

Tested-by: Yangyu Chen <cyy@cyyself.name>
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-06-10 10:08:19 +02:00
Sijia Huang
33db914607 mediatek: filogic: Add support for Wavlink WL-WN586X3
Hardware
--------
- SOC: MediaTek MT7981
- ram: 256MB DDR3
- FLASH: 16MB SPI-NOR
- Ethernet: 2x1Gb Lan 1x1Gb Wan
- WIFI: MediaTek MT7981 2x2 DBDC 802.11ax 2T2R (2.4/5)
- LEDs: 2xLan 1x Wan 1x WIFI 1xSTATUS

MAC table, same as stock firmware:
LAN: 80:3F:5D:xx:xx:x1 partition "hw" at 0x44e (ASCII)
WAN: 80:3F:5D:xx:xx:x2 partition "hw" at 0x460 (ASCII)
 2G: 80:3F:5D:xx:xx:x3 partition "factory" at 0x4 (binary), on label
 5G: 80:3F:5D:xx:xx:x3 Same as 2G

Installation Method 1: ssh
--------------------------
1. Connect PC to the lan port. Set the PC IP to 192.168.10.100 if
   required.
2. Navigate to http://192.168.10.1/
3. Log into the Wavlink WebGUI. Default username/password is
   admin/admin.
4. Use WebGUI to upgrade the firmware to
   WAVLINK_WN586X3-A_M86X3A_V240113_WO-GDBYFM-modified.bin
   downloaded from
   https://github.com/themaverickdm/firmware-misc/tree/main/wavlink/wl-wn586x3
   Warning: All settings will be lost!
5. Wait about 5 minutes, and after flashing is completed, log into
   the router using (with admin123 as password):
   ssh root@192.168.10.1
6. scp the openwrt image file onto the router, usually under /tmp
   somewhere.
   openwrt-mediatek-filogic-wavlink_wl-wn586x3-squashfs-sysupgrade.bin
7. Flash openwrt image file like so:
   mtd write \
     openwrt-mediatek-filogic-wavlink_wl-wn586x3-squashfs-sysupgrade.bin \
     firmware
   Warning: Previous firmware will be overwritten!
8. Wait about 5 minutes, and after the flashing is completed, set
   the PC IP to 192.168.1.100 if required and log into the router
   like so:
   ssh root@192.168.1.1

Installation Method 2: u-boot
-----------------------------
1. Connect UART:  TX-> 586X3 RX, RX-> 586X3 TX, GND-> 586 GND.
2. Connect PC to the wan (not lan!) port.
3. Setup the tftp server on PC, set IP to 192.168.10.100,
4. Power on the device. Select '2' to upgrade firmware in Uboot.
5. Input the image name and start to upgrade.

Uboot console log:

CPU:   MediaTek MT7981
Model: mt7981-rfb
DRAM:  256 MiB
Core:  34 devices, 13 uclasses, devicetree: embed
Loading Environment from nowhere... OK
In:    serial@11002000
Out:   serial@11002000
Err:   serial@11002000
Net:
Warning: ethernet@15100000 (eth0) using random MAC address -
02:47:fb:b2:53:2d
eth0: ethernet@15100000
UBOOT WN586X3A
gpio: pin 9 (gpio 9) value is 0
gpio: pin 10 (gpio 10) value is 0
gpio: pin 5 (gpio 5) value is 0
gpio: pin 12 (gpio 12) value is 0
gpio: pin 13 (gpio 13) value is 0

  *** U-Boot Boot Menu ***

      1. Startup system (Default)
      2. Upgrade firmware
      3. Upgrade ATF BL2
      4. Upgrade ATF FIP
      5. Upgrade single image
      6. Load image
      0. U-Boot console

Co-authored-by: R Maru <deviantmaru@gmail.com>
Signed-off-by: R Maru <deviantmaru@gmail.com>
Signed-off-by: Sijia Huang <engineer31@win-star.com>
2024-06-09 14:58:25 +02:00
Rosen Penev
dd6bbbabd3 ath79: 8dev: remove wmac userspace handling
Before the nvmem rework, this was already handled in dts with
mtd-cal-data instead of qca,no-eeprom. No need to duplicate. Also, the
800 size value seems nonsensical. 440 is the standard.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-09 12:24:15 +02:00
Rosen Penev
74f2df9dbc ath79: mtd-cal-data removals
Replacement can be done with nvmem.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-09 12:24:15 +02:00
Rosen Penev
79fc4dba60 ath79: convert pcs,cap324 calibration to nvmem
Userspace handling is deprecated.

Also fix a bug with userspace handling where the wrong calibration data
was being used for the PCI card. The dts was correct but userspace was
not.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-09 12:24:15 +02:00
Rosen Penev
6483615580 ath79: cd-e380ac-v2: remove duplicate eth0
It seems in the transition to nvmem, eth0 was specified twice and was
already converted to use nvmem.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-09 12:24:15 +02:00
Rosen Penev
85c5c9aa68 ath79: remove unused dts labels
These are not referenced.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-09 12:24:15 +02:00
Rosen Penev
ff5e8476d9 ath79: fix dtc address warnings
These should match reg values.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2024-06-09 12:24:15 +02:00
Shiji Yang
2d00ed7caa kernel: trim outdated kernel config symbols
These symbols have already been removed from the upstream Linux source
code. They are automatically compared and removed by a kernel config
scanning script[1].

[1] https://github.com/openwrt/openwrt/pull/15324

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
2024-06-09 11:45:34 +02:00
Martin Schiller
6ec7711d00 lantiq: Refresh patches and configuration for linux 6.6
Make all the patches apply. This also refreshes some of the kernel
configurations.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
2024-06-08 23:25:35 +02:00
Martin Schiller
c80fa584e5 lantiq: set Linux 6.6 as testing kernel
Add KERNEL_TESTING_PATCHVER for Linux 6.6.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
2024-06-08 23:25:35 +02:00
Martin Schiller
5b522e4969 kernel/lantiq: 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.

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

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
2024-06-08 23:25:35 +02:00
Martin Schiller
e85c80edcb kernel/lantiq: 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: Martin Schiller <ms@dev.tdt.de>
2024-06-08 23:25:35 +02:00
David Bauer
c2a5cd110c mpc85xx: only build zImage on required targets
Make the OF-compatible zImage per-board selectable. This allows the
image to only be built with the wrapper if the target actually uses it.

This fixes build-failures for the mpc85xx-p2020 subtarget.

Fixes: 557c094f0579 ("mpc85xx: only build zImage on required targets")

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-08 17:30:20 +02:00
Mieczyslaw Nalewaj
df28fe4b59 kernel: rtl8367b: remove unnecessary cpu_port setting
Set the appropriate cpu_port value based on the use of realtek,extif0 to extif2
instead of the additional cpu_port parameter.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15033
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-08 16:28:37 +02:00
Mieczyslaw Nalewaj
c1a26de1c6 kernel: rtl8367: set the correct cpu_port value
Set the appropriate cpu_port value based on the use of realtek,extif0 or realtek,extif1 parameter.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15033
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-08 16:28:36 +02:00
Zxl hhyccc
2d6cedab27 kernel: bump 6.1 to 6.1.92
https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.1.92

Removed upstreamed:
 bcm27xx/patches-6.1/950-0270-net-bcmgenet-Reset-RBUF-on-first-open.patch
 generic/backport-6.1/600-v6.9-03-net-gro-add-flush-check-in-udp_gro_receive_segment.patch
 generic/pending-6.1/681-net-bridge-fix-multicast-to-unicast-with-fraglist-GS.patch
 generic/pending-6.1/682-net-core-reject-skb_copy-_expand-for-fraglist-GSO-sk.patch
 generic/pending-6.1/684-net-bridge-fix-corrupted-ethernet-header-on-multicas.patch
 generic/pending-6.1/778-net-l2tp-drop-flow-hash-on-forward.patch
 imx/patches-6.1/002-6.2-phy-freescale-imx8m-pcie-Refine-i.MX8MM-PCIe-PHY-dri.patch

All other patches automatically rebased.

Signed-off-by: Zxl hhyccc <zxlhhy@gmail.com>
2024-06-08 14:16:19 +02:00
David Bauer
de59fc4540 ipq40xx: fix broken image generation for EX6150v2
All NETGEAR EX6150v2 validate the rootfs for which OpenWrt places a
fakeheader at the position, where the bootloader expects it.

Some EX6150v2 bootloaders do however make a broken assumption about
where the rootfs starts. This is due to them calculating the rootfs
start not based upon the kernel-length but the string-offset of the
FIT-image.

We have to be compatible with both this broken as well as the valid
calculation. So we do relocate the FDT string section to a
block-boundary and enlarge the FIT image to end at this boundary +
BLOCKSIZE / 2. This way, both the broken as well as correct calculations
do expect the rootfs-header at the same position.

It is worth noting, that this is a rare edge-case in which only happens
if the image-length as well as the start of the string-section are not
placed in the same erase-block. This is an edge-case which happens very
rarely (thus it was not spotted prior).

Affected:
 - U-Boot 2012.07 (Jun 16 2016 - 11:59:37)

Signed-off-by: David Bauer <mail@david-bauer.net>
(cherry picked from commit 8f9546f7b0a14f3afa813e39ed45c968ece24464)
2024-06-08 02:09:15 +02:00
Linus Walleij
884bef5d1b kirkwood: Add Marvell RTC to two devices
The recently added D-Link DNS-320L and the Zyxel NSA310S
is missing an RTC module so let's give them the default
Marvell RTC at least.

Reviewed-by: Robert Marko <robimarko@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2024-06-07 21:48:42 +02:00
Tianling Shen
4edde98768 mediatek: fix wps button for nokia ea0326gmp
The gpio is actually low active, fix it.

Fixes: 40e7fab9e4 ("mediatek: add Nokia EA0326GMP support")
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
Link: https://github.com/openwrt/openwrt/pull/15651
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-07 14:19:39 +02:00
Tim Harvey
0520c45f2f imx: 6.6: update kernel config
added some missing configs needed when building 6.6 with all kmods

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
2024-06-06 22:04:23 +02:00
Tim Harvey
c78c71737b imx: 6.6: refresh kernel patches
refresh 6.6 kernel patches via 'make target/linux/refresh'

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
2024-06-06 22:04:23 +02:00
Tim Harvey
a6d4d369eb imx: add 6.6 kernel as testing
allow to test 6.6 kernel for imx

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
2024-06-06 22:04:23 +02:00
Tim Harvey
368cd88c44 imx: fix cortexa9/cortexa7 image builds due to dts move
The IMX device-tree's for arm moved from arch/arm/boot/dts to
arch/arm/boot/dts/nxp/imx. Use that if using the 6.6 kernel.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
2024-06-06 22:04:23 +02:00
Tim Harvey
7dfdfac344 imx: copy config from 6.1 to 6.6
Copy the 6.1 config to 6.6

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
2024-06-06 22:04:23 +02:00
Tim Harvey
e4d76cf6ae imx: copy patches from 6.1 to 6.6
copy 6.1 patches to 6.6 and fixup:
 - removed patches already upstream
 - adapted pathnames of dts patches for new kernel

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
2024-06-06 22:04:23 +02:00
Daniel Golle
56bce303ce generic: 6.6: refresh patches
Patch 733-01-net-ethernet-mtk_eth_soc-use-napi_build_skb.patch needs
a refresh as line numbers no longer match.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-06 20:08:13 +01:00
Tianling Shen
a568540fd4 mediatek: filogic: move nand-only devices out of bootdev detection
For the first-time installation (mostly migrates from vendor firmware)
the ubiblock is not ready, but bootdev detection relies on it. This
means users must create ubiblock manually otherwise the sysupgrade
will not work.

Now a unique case is added for nand devices which use new fit format,
let's move to it.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-06-06 18:56:32 +01:00
Tianling Shen
40e7fab9e4 mediatek: add Nokia EA0326GMP support
Hardware specification:
  SoC: MediaTek MT7981B 2x A53
  Flash: 128 MB SPI-NAND
  RAM: 256MB
  Ethernet: 4x 10/100/1000 Mbps
  Switch: MediaTek MT7531AE
  WiFi: MediaTek MT7976C
  Button: Reset, WPS/Mesh
  Power: DC 12V 1A

Gain SSH access:
1. Login into web interface, and download the configuration.
2. Download the configration utilities:
   https://firmware.download.immortalwrt.eu.org/cnsztl/mediatek/filogic/openwrt-mediatek-mt7981-nokia-ea0326gmp-config-utils.tar.gz
     These binaries are extraced from the factory firmware, which are
     dynamically linked with aarch64 musl 1.1.24. To use them, you
     must run them under the same runtime environment, otherwise the
     binaries will not work properly!
3. Upload the configuration and utilities to a suitable environment.
4. Uncompress the utilities, move them to '/bin' and give them executable permisison:
   tar -zxf openwrt-mediatek-mt7981-nokia-ea0326gmp-config-utils.tar.gz
   mv mkconfig seama /bin
   chmod +x /bin/mkconfig
   chmod +x /bin/seama
5. Decrypt and uncompress the configuration:
     Enter fakeroot if you are not login as root.
   mkconfig -a de-enca -m EA0326GMP_3FE79221BAAA -i EA0326GMP_3FE79221BAAA-xxxxxxxx-backup.tar.gz -o backup.tar.gz
   tar -zxf backup.tar.gz
6. Edit 'etc/config/dropbear', set 'enable' to '1'.
7. Edit 'etc/passwd', remove root password: 'root::1:0:99999:7:::'.
8. Repack the configuration:
   tar -zcf backup.tar.gz etc/
   mkconfig -a enca -m EA0326GMP_3FE79221BAAA -i backup.tar.gz -o EA0326GMP_3FE79221BAAA-xxxxxxxx-backup.tar.gz
9. Upload new configuration via web interface, now you can SSH to EA0326GMP.

A minimum configuration which enabled SSH access is also provided
to simplify the process:
https://firmware.download.immortalwrt.eu.org/cnsztl/mediatek/filogic/openwrt-mediatek-mt7981-nokia-ea0326gmp-enable-ssh.tar.gz

Flash instructions:
1. SSH to EA0326GMP, backup everything, especially 'Factory' part.
2. Write new BL2:
   mtd write openwrt-mediatek-filogic-nokia_ea0326gmp-preloader.bin BL2
3. Write new FIP:
   mtd write openwrt-mediatek-filogic-nokia_ea0326gmp-bl31-uboot.fip FIP
4. Set static IP on your PC:
   IP 192.168.1.254/24, GW 192.168.1.1
5. Serve OpenWrt initramfs image using TFTP server.
6. Cut off the power and re-engage, wait for TFTP recovery to complete.
7. After OpenWrt has booted, perform sysupgrade.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2024-06-06 18:56:32 +01:00
Felix Fietkau
f352ca5a8a kernel: use napi_build_skb in mtk_eth_soc
Improves performance

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2024-06-06 11:47:59 +02:00
Robert Marko
458cafd0d0 generic: routerbootpart: fix compilation on 64-bit
Trying to compile routerbootpart parsers on 64-bit platforms will fail:
drivers/mtd/parsers/routerbootpart.c: In function 'routerboot_find_dynparts':
./include/linux/kern_levels.h:5:25: error: format '%X' expects argument of type 'unsigned int', but argument 3 has type 'size_t' {aka 'long unsigned int'} [-Werror=format=]
    5 | #define KERN_SOH        "\001"          /* ASCII Start Of Header */
      |                         ^~~~~~
./include/linux/printk.h:427:25: note: in definition of macro 'printk_index_wrap'
  427 |                 _p_func(_fmt, ##__VA_ARGS__);                           \
      |                         ^~~~
./include/linux/printk.h:498:9: note: in expansion of macro 'printk'
  498 |         printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
      |         ^~~~~~
./include/linux/kern_levels.h:11:25: note: in expansion of macro 'KERN_SOH'
   11 | #define KERN_ERR        KERN_SOH "3"    /* error conditions */
      |                         ^~~~~~~~
./include/linux/printk.h:498:16: note: in expansion of macro 'KERN_ERR'
  498 |         printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
      |                ^~~~~~~~
drivers/mtd/parsers/routerbootpart.c:170:25: note: in expansion of macro 'pr_err'
  170 |                         pr_err("%s: mtd_read error while parsing (offset: 0x%X): %d\n",

So, lets simply add the length modifier 'z' to fix compilation.

Link: https://github.com/openwrt/openwrt/pull/15640
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-06 11:45:03 +02:00
Daniel Golle
84a527417d mediatek: improve reliability of Fidelix/Dosilicon SPI-NAND
Prior to performing a PROGRAM LOAD RANDOM DATA operation, a WRITE
ENABLE (06h) command must be issued to change the contents of the
memory array. Following a WRITE ENABLE (06) command, **first a PROGRAM
LOAD (02h or 32h) command must be issued to reset the cache**, then
issue a PROGRAM LOAD RANDOM DATA (84h or 34h) command

This is dirty fix provided to use by MediaTek engineer Sky Huang which
may resolve the "OpenWrt Kiss of Death" issue we've been seeing on the
Linksys E8450 aka. Belkin RT3200. However, it means that everything has
to be re-written with that patch already applied, ie. we need to rebuild
the installer once it is part of snapshot builds to have any effect.

Users already on FIP-in-UBI layout are advised to re-write 'fip' UBI
volume and 'bl2' MTD partition manually once from within Linux after
this fix has been applied.

A similar fix will also be required for U-Boot.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-05 21:05:52 +01:00
INAGAKI Hiroshi
1fbfc251c9 ramips: add support for Buffalo WSR-2533DHPL2
Buffalo WSR-2533DHPL2 is a 2.4/5 GHz band 11ac (Wi-Fi 5) router, based
on MediaTek MT7621A.

Specification:

- SoC           : MediaTek MT7621AT
- RAM           : DDR3 128 MiB (Winbond W631GG6MB12J)
- Flash         : RAW-NAND 128 MiB (Winbond W29N01HVSINF)
- WLAN          : 2.4/5 GHz (2x MediaTek MT7615N)
- Ethernet      : 10/100/1000 Mbps x4
  - Switch      : MediaTek MT7530 (SoC)
- LED/keys      : 8x/6x (2x buttons, 1x slide-switch)
- UART          : through-hole on PCB (J4)
  - arrangement : 3.3V, GND, TX, RX from triangle-mark
  - settings    : 57600n8
- Power         : 12VDC 1.5A

Flash instruction using factory.bin image:

1. boot WSR-2533DHPL2 normally with "Router" mode
2. access to the WebI ("http://192.168.11.1/") on the device and open
   firmware update page
   ("管理" -> "ファームウェア更新")
3. select the OpenWrt factory.bin image and click update ("更新実行")
   button
   Attention: do not use "factory-uboot.bin" image
4. Wait ~120 seconds to complete flashing

Flash instruction using initramfs image:

1. prepare the TFTP server with the initramfs image renamed to
   "linux.trx-recovery" and IP address "192.168.11.2"
2. press the "AOSS" button while powering on the WSR-2533DHPL2
3. after 10 seconds, release the "AOSS" button, WSR-2533DHPL2 downloads
   the initramfs image and boot with it automatically
4. on the initramfs image, download the factory-uboot.bin image to the
   device and perform sysupgrade with it and "-F" option
5. wait ~120 seconds to complete flashing

Notes:

- There are 2x factory*.bin images for different purposes.

  - factory.bin      : for flashing on OEM WebUI
  - factory-uboot.bin: for flashing on OEM bootloader or initramfs image

  factory-uboot.bin is useful for recoverying the device, or refreshing
  when the kernel partition is expanded in the future. sysupgrade on
  this device accepts factory-uboot.bin with option "-F", but on that
  situation, user configurations won't be kept, so it's not for normal
  use.

MAC addresses:

LAN    : 18:EC:E7:xx:xx:E0 (board_data, "mac" (text))
WAN    : 18:EC:E7:xx:xx:E0 (board_data, "mac" (text))
2.4 GHz: 18:EC:E7:xx:xx:E1 (Factory, 0x4    (hex))
5 GHz  : 18:EC:E7:xx:xx:E4 (Factory, 0x8004 (hex))

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
2024-06-05 21:14:16 +02:00
INAGAKI Hiroshi
ea8d140b25 ramips: add support for Buffalo WSR-2533DHPLS
Buffalo WSR-2533DHPLS is a 2.4/5 GHz band 11ac router, based on MediaTek
MT7621A.

Very similar to Buffalo WSR-2533DHPL, but with NAND, different GPIO
and TRX partitions.

Specification:

- SoC           : MediaTek MT7621AT
- RAM           : DDR3 256 MiB (Samsung K4B2G1646F-BYMA)
- Flash         : RAW-NAND 128 MiB
                  (Winbond W29N01HV or KIOXIA TC58BVG0S3HTAI0)
- WLAN          : 2.4/5 GHz (2x MediaTek MT7615N)
- Ethernet      : 10/100/1000 Mbps
  - Switch      : MediaTek MT7530 (SoC) 4 ports
- LED/keys      : 8x/6x (2x buttons, 1x slide-switch)
- UART          : through-hole on PCB (J4)
  - arrangement : 3.3V, GND, TX, RX from triangle-mark
  - settings    : 115200n8
- Power         : 12VDC 1.5A

Flash instruction using factory.bin image:

1. boot WSR-2533DHPLS normally with "Router" mode
2. access to the WebI ("http://192.168.11.1/") on the device and open
   firmware update page
   ("管理" -> "ファームウェア更新")
3. select the OpenWrt factory.bin image and click update ("更新実行")
   button
   Attention: do not use "factory-uboot.bin" image
4. Wait ~120 seconds to complete flashing

Flash instruction using initramfs image:

1. prepare the TFTP server with the initramfs image renamed to
   "linux.trx-recovery" and IP address "192.168.11.2"
2. press the "AOSS" button while powering on the WSR-2533DHPLS
3. after 10 seconds, release the "AOSS" button, WSR-2533DHPLS downloads
   the initramfs image and boot with it automatically
4. on the initramfs image, download the factory-uboot.bin image to the
   device and perform sysupgrade with it and "-F" option
5. wait ~120 seconds to complete flashing

Notes:

- The embedded addresses in eeprom data in Factory partition have
  Buffalo's OUI, but they don't match with the actual addresses
  assigned to wlan devices. So fixup addresses by the user-space
  script.

  root@localhost:/# hexdump -C /dev/mtdblock3 | grep "^0000[08]000\s"
  00000000  15 76 a0 00 88 57 ee bc  01 a8 15 76 c3 14 00 80  |.v...W.....v....|
  00008000  15 76 a0 00 88 57 ee bc  01 f8 15 76 c3 14 00 80  |.v...W.....v....|

  See "MAC addresses" below for actual addresses.

- There are 2x factory*.bin images for different purposes.

  - factory.bin      : for flashing on OEM WebUI
  - factory-uboot.bin: for flashing on OEM bootloader or initramfs image

  factory-uboot.bin is useful for recoverying the device, or refreshing
  when the kernel partition is expanded in the future. sysupgrade on
  this device accepts factory-uboot.bin with option "-F", but on that
  situation, user configurations won't be kept, so it's not for normal
  use.

MAC addresses:

LAN    : 90:96:F3:xx:xx:30 (board_data, "mac" (text))
WAN    : 90:96:F3:xx:xx:30 (board_data, "mac" (text))
2.4 GHz: 90:96:F3:xx:xx:31
5 GHz  : 90:96:F3:xx:xx:38

[original work]
Signed-off-by: Audun-Marius Gangstø <audun@gangsto.org>
[convert to ubi, fix/improve DT, add sysupgrade support]
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
2024-06-05 21:14:16 +02:00
INAGAKI Hiroshi
d529ac5da8 ramips: mt7621: switch trx parser to parser_trx from mtdsplit
Switch trx parser to parser_trx of Linux Kernel from mtdsplit_trx to
split firmware partition using model-specific trx magic number on
some Buffalo devices.
This change is tested on Buffalo WSR-2533DHPL.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
2024-06-05 21:14:16 +02:00
INAGAKI Hiroshi
47d9dcd01a build: move Build/buffalo-trx to image-commands.mk
Move Build/buffalo-trx to image-commands.mk from image/mt7622.mk to use
that definition from ramips as well.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
2024-06-05 21:14:16 +02:00
Ashley Lee
3de3c2bdfa mediatek: add support for Ruijie RG-X60 Pro
This pull request ports Ruijie RG-X60 Pro router support to the main branch.

Parameters:
- SoC       : MediaTek MT7986A Quad-core ARM Cortex-A53 2.0GHz
- RAM       : DDR3 512MiB (W634GU6QB)
- Flash     : SPI-NAND 128 MiB (W25N01GVZEIG)
- WLAN      : MediaTek MT7986A integration dual-band WiFi 6
  - 2.4 GHz : b/g/n/ax, MIMO 4x4
  - 5 GHz   : a/n/ac/ax, MIMO 4x4
- Ethernet  : 10/100/1000 Mbps x4 (MediaTek MT7531AE)
                    2500Mbps x 1 (Realtek RTL8221B-VB-CG)
- UART      : through-hole on PCB
  - [J500] GND, TX, RX, 3.3V (115200n1)
- Buttons   : Mesh, Reset
- LEDs      : 1x Power (Blue)
                  1x Turbo (Purple)
- Power     : 12 VDC, 3 A

How to Installation:
1. Remove the case and connect the TTL cable to the corresponding position.
2. Power on the device and quickly press "down" on the keyboard, then
   U-Boot will stay in the menu.
3. Select "1. Upgrade Firmware", select "0. TFTP Client(Default)".
4. Input the IP address, input the Openwrt image file name to be
   flashed, start the TFTP server, and press "Enter".
5. Wait for the flashing to complete.

How return to stock:

1. Remove the case and connect the TTL cable to the corresponding
   position.
2. Power on the device and quickly press "down" on the keyboard, then
   U-Boot will stay in the menu.
3. Select "1. Upgrade Firmware", select "0. TFTP Client(Default)".
4. Input the IP address, input the Stock “E-WEBOS” image file name to
   be flashed, start the TFTP server, and press "Enter".
5. Wait for the flashing to complete.

About recovery:
Connect uart, use u-boot menu to flash stock firmware image or boot
OpenWrt initramfs image.

About MAC Address:
+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| WAN     | 10:82:3D:XX:XX:9E | label     |
| LAN     | 10:82:3D:XX:XX:9F | label+1   |
| WLAN 2g | 10:82:3D:XX:XX:A0 | label+2   |
| WLAN 5g | 10:82:3D:XX:XX:A1 | label+3   |
+---------+-------------------+-----------+

Signed-off-by: Ashley Lee <code@emtips.net>
2024-06-05 17:44:11 +01:00
Michał Kępień
a60721f2ed mikrotik: switch to Yafut for building MikroTik NOR images
The Yafut tool now has limited capabilities for working on filesystem
images stored in regular files.  This enables preparing Yaffs2 images
for devices with NOR flash using upstream Yaffs2 filesystem code instead
of the custom kernel2minor tool.

Since minimizing the size of the resulting filesystem image size is
important and upstream Yaffs2 code requires two allocator reserve blocks
to be available when writing a file to the filesystem, a trick is
employed while preparing an OpenWRT image: the blank filesystem image
that Yafut operates on initially contains two extra erase blocks that
are chopped off after the kernel file is written.  This is safe to do
because Yaffs2 has a true log structure and therefore only ever writes
sequentially (and the size of the kernel file is known beforehand).
While the two extra erase blocks are necessary for writes, Yaffs2 code
seems to be perfectly capable of reading back files from a "truncated"
filesystem that does not contain these extra erase blocks.

In terms of image size, this new approach is only marginally worse than
the current kernel2minor-based one: specifically, upstream Yaffs2 code
needs to write three object headers (each of which takes up an entire
data chunk) when the kernel file is written to the filesystem:

  - an object header for the kernel file when it is created,

  - an object header for the root directory when the kernel file is
    created,

  - an updated object header for the kernel file when the latter is
    fully written (so that its new size can be recorded).

kernel2minor only writes two of these headers, which is the absolute
minimum required for reading the file back.  This means that the
Yafut-based approach causes firmware images to be at most one erase
block (64 kB) larger than those created using kernel2minor, but only in
the very unfortunate scenario where the size of the kernel file is
really close to a multiple of the erase block size.

The rest of the calculations performed when the empty filesystem image
is first prepared stems from the Yaffs2 layout used by MikroTik NOR
devices: each 65,536-byte erase block contains 63 chunks, each of which
consists of 1024 bytes of data followed by 16-byte Yaffs tags without
ECC data; each such group of 63 chunks is then followed by 16 bytes of
padding, which translates to "-C 1040 -B 64k -E" in the Yafut
invocation.  Yaffs2 checkpoints and summaries are disabled (using
Yafut's -P and -S switches, respectively) as they are merely performance
optimizations that require extra storage space.  The -L and -M switches
are used to force little-endian or big-endian byte order (respectively)
in the resulting filesystem image, no matter what byte order the build
host uses.  The tr invocation is used to ensure that the filesystem
image is initialized with 0xFF bytes (which are an indicator of unused
space for Yaffs2 code).

Signed-off-by: Michał Kępień <openwrt@kempniu.pl>
Link: https://github.com/openwrt/openwrt/pull/13453
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-05 17:03:24 +02:00
Daniel Golle
683a35098f ipq40xx: use NVMEM-on-UBI for ASUS RT-AC58U
Instead of extracting WiFi precal as well as MAC addresses in userspace
use recently introduced NVMEM-on-UBI instead.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Tested-by: Christian Lamparter <chunkeey@gmail.com>
2024-06-05 13:46:00 +01:00
Luis Mita
f1091ef7ac ramips: mt76x8: add support for Cudy TR1200 v1
Hardware:
 - SoC: MediaTek MT7628AN (MIPS 580MHz)
 - Flash: 16 MiB XMC 25QH128CH10
 - RAM: 128 MiB ESMT M14D1G1664A
 - WLAN: 2.4 GHz (MT7628), 5 GHz (MT7613BEN 802.11ac)
 - Ethernet: 1x 10/100 Mbps WAN, 1x 10/100 LAN (MT7628)
 - USB 2.0 port
 - Buttons: 1 Reset button, 1 slider button
 - LEDs: 1x Red, 1x White
 - Serial console: unpopulated header, 115200 8n1
 - Power: 5 VDC, 2 A

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

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. Upgrade to a beta firmware (signed by Cudy) that can be downloaded
from the wiki. This is required in order to use an unlocked u-boot.
2. Connect to UART.
3. While the router is turning on, press 1.
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 as recovery.bin.
5. Press Enter three times. Verify the filename.
6. If you can reach LuCI or SSH now, just use the sysupgrade image with
the 'Keep settings' option turned off.

If you don't want to use the beta firmware nor the unlocked u-boot, you
can install the firmware writing the sysupgrade image on the firmware
partition of the SPI flash.

Signed-off-by: Luis Mita <luis@luismita.com>
2024-06-05 10:44:44 +02:00
Robert Marko
f5df45efa3 airoha: drop kernel 6.1 support
Now that 6.6 is the default, lets remove 6.1.

Link: https://github.com/openwrt/openwrt/pull/15630
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-05 09:34:06 +02:00
Robert Marko
690ec44141 airoha: default to kernel 6.6
Move airoha do kernel 6.6 as the default.

Link: https://github.com/openwrt/openwrt/pull/15630
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-05 09:34:06 +02:00
Shiji Yang
6e51b363e9 ramips: simplify multi-phy support patches
For MT7620, we should always prevent main ethernet interface from
going down due to phy link changes. And the ralink net driver does
not support cable test function, so this patch won't change any
behavior.

Ref:
6fcba5eec3 ("ramips: port 0034-NET-multi-phy-support.patch to 5.4")

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
Link: https://github.com/openwrt/openwrt/pull/15591
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
2024-06-04 16:19:41 +08:00
Mieczyslaw Nalewaj
65f34e9928 bcm47xx: 6.6: refresh patches
CI tells us that we need to, so lets refresh them.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
a82b2e79e3 bcm47xx: 6.6: set testing kernel
Select 6.6 as testing kernel on bcm47xx.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
5285a7d2b1 bcm47xx: remove 5.15 support
Since 6.1 is now default, drop 5.15 support.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
f75b530d20 bcm47xx: default to kernel 6.1
Default to kernel 6.1 on bcm47xx.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
29aa1a94c4 bcm47xx: 6.6: refresh patches
Refresh kernel patches. Remove patches already included in the kernel.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
930eedaafe bcm47xx: 6.6: refresh kernel config
Refresh kernel config.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
83647098a1 kernel/bcm47xx: 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: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Mieczyslaw Nalewaj
907c1c5fe1 kernel/bcm47xx: 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: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/15010
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 17:57:54 +02:00
Chukun Pan
29faf53b8c qualcommax: use ath11k_patch_mac for ZBT-Z800AX
Use ath11k_patch_mac and ath11k_set_macflag functions
instead of fix_wifi_mac script.

Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Link: https://github.com/openwrt/openwrt/pull/15580
Signed-off-by: Robert Marko <robimarko@gmail.com>
2024-06-03 13:15:48 +02:00
David Bauer
d4acd05218 mpc85xx: refresh patches
Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-02 22:43:46 +02:00
David Bauer
63239a939f mpc85xx: fix patch for kernel 6.6
Fixes: af329ec389 ("mpc85xx: add support for Hewlett Packard MSM460")

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-02 22:43:46 +02:00
Keith Harrison
6707eba9f0 ramips: add support for D-Link DIR-2055 A1
Add support for D-Link DIR-2055 A1 based on similarities to DIR-1960 A1,
as well as various DIR-8xx A1 models. Existing DIR-1960 A1 openwrt
"factory" firmware installs without modifications via the D-Link Recovery
GUI and has no known incompatibilities with the DIR-2055 A1.

Changes to be committed:
new file:   target/linux/ramips/dts/mt7621_dlink_dir-2055-a1.dts
modified:   target/linux/ramips/image/mt7621.mk
modified:   target/linux/ramips/mt7621/base-files/etc/board.d/01_leds
modified:   target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh

Specifications:

    Board: Not known
    SoC: MediaTek MT7621 Family (MT7621AT)
    RAM: 256 MB (Micron 9OK17 D9PTK, should be DDR3 MT41K128M16JT-125)
    Flash: 128 MB (Winbond W29N01HVSINA)
    WiFi: MediaTek MT7615 Family (MT7615N x2)
    Switch: 1 WAN, 4 LAN (Gigabit)
    Ports: 1 USB 3.0 (front)
    Buttons: Reset, WiFi Toggle, WPS
    LEDs: Power (white/orange), Internet (white/orange),
          WiFi 2.4G (white), WiFi 5G (white)

Notes:

    Only known difference vs. the DIR-1960 A1 is that the DIR-2055 A1
    doesn't have a USB activity LED

Serial port:

    Tested to be identical to various DIR-8xx A1 models with a similar
    enclosure/pcb design:
        Parameters: 57600, 8N1, 3.3V TTL no flow control
        Location: J1 header (close to the Reset, WiFi and WPS buttons)
        Pinout: 1 - VCC 2 - RXD 3 - TXD 4 - GND
            Did not connect VCC when using

Installation:

    D-Link Recovery GUI: power down the router, press and hold the reset
    button, then re-plug it. Keep the reset button pressed until the power
    LED starts flashing orange, manually assign a static IP address under
    the 192.168.0.xxx subnet (e.g. 192.168.0.2) and go to
    http://192.168.0.1

    Some modern browsers may have problems flashing via the Recovery GUI,
    if that occurs consider uploading the firmware through cURL:

    curl -v -i -F "firmware=@file.bin" 192.168.0.1

Signed-off-by: Keith Harrison <keithh@protonmail.com>
2024-06-02 18:41:17 +02:00
Hauke Mehrtens
21213c8156 tegra: Activate CONFIG_SND_DRIVERS
The option CONFIG_SND_DRIVERS is activated by default in the generic
configuration, do not deactivate it for tegra. This fixes the build of
the kmod-sound-dummy package on tegra.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-06-02 17:56:28 +02:00
Hauke Mehrtens
8647ce0800 kernel: Split kmod-video-dma into two kmods
Split the kmod-video-dma into kmod-video-dma-sg and
kmod-video-dma-contig. The old one contained two kmods, but sometimes
only one of them is build which caused problems. The configuration
options are not manually selectable in the kernel and hidden in OpenWrt.

Currently this causes build failures on some targets.

Fixes: 4d7cbe0a55 ("kernel: video-dma: explicitly state packaged modules")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-06-02 17:38:23 +02:00
Christian Marangi
37ff0ea726 mvebu: disable polling delay for passive trip point for puzzle thermal
We don't have any passive trip point hence we can set the polling delay
for passive trip to 0 effectively disabling this polling.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-01 16:40:10 +01:00
Christian Marangi
611413cc3f mvebu: split thermal zone for puzzle chassis
Split thermal zone for puzzle chassis. Thermal platform supports only
one sensor per thermal zone.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-06-01 16:40:10 +01:00
Christian Marangi
e5c7b5ec43 mvebu: fix missing property in puzzle thermal
Fix missing property in puzzle thermal. The thing was never supposed to
work.

Property #thermal-sensor-cells was missing from the puzzle hwmon, making
the entire thermal platform referencing that fail to probe with -EINVAL.

The puzzle hwmon expose 2 termistor but they probably use an userspace
downstream utility to configure and handle thermal. For this reason we
really don't know what they use the sensor for or when it's attached.

We use them to sensor if the Chassis gets too hot due to ambient
temperature and generic components getting too warm.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-01 16:40:10 +01:00
Daniel Golle
ac783b419b mvebu: improve thermal management of IEI Puzzle devices
- Make step_wise thermal governor respect hysteresis
   This is done by importing a downstream patch, backporting the same feature
   now present in Linux v6.10+ would be too messy.
 - Introduce thermal zone for the WT61P803 uC (chassis and board sensors)
 - Introduce thermal zones for AQR NBase-T PHYs
 - No longer modify existing SoC thermal zones (which are now only in charge
   for emergency shutdown, and can be interrupt driven instead of polled)

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2024-06-01 16:40:10 +01:00
David Bauer
dbc9596c7e mpc85xx: add label-mac for HP MSM460
Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-01 16:53:17 +02:00
David Bauer
af329ec389 mpc85xx: add support for Hewlett Packard MSM460
Hardware
--------
CPU:  Freescale P1020 2xe500 PPC
RAM:  256M DDR3 (Micron MT41J64M16JT-15E:G "D9MNJ")
NAND: 128M (Micron 2CA1)
BTN:  1x Reset
LED:  Power - ETH - Radio1 - Radio2
UART: RJ-45 Cisco Pinout - 115200 8N1

Installation
------------
NOTE: You can find a repo with up-to-date instructions as well as
the required files here:

https://github.com/blocktrron/msm460-flashing

Required files
==============
You need a command-files as well as a U-Boot image.

The command-file has the following content (padded to 131072 bytes).

If you copy paste these, remove the newlines!

```
U-BOOT setenv ethaddr 02:03:04:05:06:07; setenv ipaddr 192.168.1.1;
setenv serverip 192.168.1.66; tftpboot 0x3000000 msm460-uboot.bin;
nand device; nand erase 0 0xC0000; nand write 0x3000000 0x0 0xC0000; reset
```

You can download the required U-Boot from this repository:

https://github.com/blocktrron/u-boot-msm/releases

Preparation
===========
Prepare a TFTP server serving two files:

 - U-Boot NAND image as `msm460-uboot.bin`.
 - OpenWrt factory image as `msm460-factory.bin`
 - Command-file names `commands.tftp`

You can start a TFTP server in the current directory using dnsmasq:

```bash
sudo dnsmasq --no-daemon --listen-address=0.0.0.0 \
    --port=0 --enable-tftp=enxd0 --tftp-root="$(pwd)" \
    --user=root --group=root
```
Replace `enxd0` with the name of your network interface.

Procedure
=========
1. Assign yourself the IP-Address 192.168.1.66/24.
3. Connect the Router to the PC while keeping the reset button
   pressed.
4. The LEDs will eventually begin to flash.
   They will start to flash faster after around 15 seconds.
5. Release the reset button.
6. Start a new shell
7. Make sure you are currently in the directory where the tftp server
   is located.
8. Run the following command:

```bash
tftp 192.168.1.1 -m binary -c put commands.tftp nflashd.cccc9999
```

You get the message "Transfer timed out."
To find out if you have been successful, please check the
blinking LED Pattern.

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-01 14:41:11 +02:00
David Bauer
7d768a9ba6 mpc85xx: add compressed zImage for mpc85xx
Add a universal zImage which can be loaded by mpc85xx boards at
load address 0x3000000. This allows boards to boot kernels larger than
16MB even if the image is loaded temporarily from NAND at offset
0x1000000 which some bootloaders do by default.

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-01 14:37:43 +02:00
Zoltan HERPAI
8619d7af67 kirkwood: add D-Link DNS-320L support
Dual-slot NAS based on Marvell Kirkwood.

Specifications:
 - Marvell 88F6702 @1GHz
 - 256Mb RAM
 - 128Mb NAND
 - 1x GbE LAN (Marvell 88E1318R)
 - 1x USB 2.0
 - 2x SATA
 - Weltrend WT69P3 ("supervisor" MCU chip)
 - Serial on J2 (115200,8n1)
 - Newer bootROM so kwboot-ing via serial is possible

Notes:
 - The Weltrend MCU is controlled by the package added in utils/dns320l-mcu.
 - The original MAC address is stored in the "mini firmware" image's first
   17 bytes.
 - Compared to the original MTD layout, the uImage+rootfs are now stored in
   a common ubi partition.

Installation:
1. Serial console
 - Connect your levelshifter to the serial console
   on J2 (refer to the wiki page for pinout)
2. Update u-boot
 - Download the u-boot.kwb image for the device
 - Powercycle the NAS
 - Run "kwboot -b u-boot-dns320l/u-boot.kwb /dev/ttyUSB0 -p"
 - Connect to the serial console with minicom
 - tftp 0x0800000 u-boot-dns320l/u-boot.kwb
   (Please note that "PHY reset timed out" seems to be customary
    on kirkwood devices, the egiga0 interface works regardless.)
 - nand erase 0x0 100000
 - nand write 0x0800000 0x0 0x100000
 - reset
3. Install OpenWrt
 - Boot up the initramfs image
 - tftpboot 0x800000 openwrt-kirkwood-generic-dlink_dns320l-initramfs-uImage; bootm 0x800000
 - Download the sysupgrade image and perform sysupgrade

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
Reviewed-by: Pawel Dembicki <paweldembicki@gmail.com>
2024-06-01 01:29:09 +02:00
Tomasz Maciej Nowak
b1bddb1d35 tegra: enable VDE driver
Upstream commit 83b7f0b8aeab ("ARM: tegra: Add OPP tables and power
domains to Tegra20 device-trees") added power domains to all devices
supporting power management and one of them is Video Decoder Engine.
Because of lacking driver for VDE, its power gate couldn't be driven
which inhibited reboot of the whole device.

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2024-05-31 14:38:17 +02:00
Tomasz Maciej Nowak
192ab0903f tegra: add testing 6.6 kernel
Preliminary support.

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2024-05-31 14:38:17 +02:00
Tomasz Maciej Nowak
4ff770e763 tegra: 6.6: refresh config and patches
Simple refresh to get rid of any fuzz and drop serial patch. With few
bug fixes around tegra serial driver the spurious IRQ didn't appear any
more during test. Let's see how long that'll last.

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2024-05-31 14:38:17 +02:00
Tomasz Maciej Nowak
2f7b5d5472 kernel/tegra: Restore kernel files for v5.15
This is an automatically generated commit which aids following Kernel patch
history, as git will see the move and copy as a rename thus defeating the
purpose.

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

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2024-05-31 14:38:17 +02:00
Tomasz Maciej Nowak
b693eca468 kernel/tegra: Create kernel files for v6.6 (from v5.15)
This is an automatically generated commit.

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

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2024-05-31 14:38:17 +02:00
Tomasz Maciej Nowak
c1a09173ab tegra: refresh 5.15 config
Reduce diffstat in kernel config on new version introduction.

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
2024-05-31 14:38:17 +02:00