aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm4908
Commit message (Collapse)AuthorAgeFilesLines
* bcm4908: use upstream-accepted watchdog patchesRafał Miłecki2022-07-182-1/+11
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 864fdf2bf3f4b5c71e57a27c514672b966580148)
* bcm4908: backport latest DT patchesRafał Miłecki2022-07-187-1/+363
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 001856fa51eaa704a254955138f76907eb02c2b4)
* kernel: backport LEDs driver for BCMBCA devicesRafał Miłecki2022-07-181-0/+1
| | | | | | | This includes BCM63xx and BCM4908 families. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit d9ab1e56d8d16182bd292f393c012d7e6873ed89)
* bcm4908: include U-Boot in imagesRafał Miłecki2022-03-141-3/+32
| | | | | | | This is a step forward in adding support for devices with U-Boot. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 34fd5e325af5cbcb64696c9b4b1660f22299790f)
* bcm4908: support "rootfs_data" on U-Boot devicesRafał Miłecki2022-03-073-13/+122
| | | | | | | | | | | | | | | | | | | | | | | | | | 1. Create "rootfs_data" dynamicaly U-Boot firmware images can contain only 2 UBI volumes: bootfs (container with U-Boot + kernel + DTBs) and rootfs (e.g. squashfs). There is no way to include "rootfs_data" UBI volume or make firmware file tell U-Boot to create one. For that reason "rootfs_data" needs to be created dynamically. Use preinit script to handle that. Fire it right before "mount_root" one. 2. Relate "rootfs_data" to flashed firmware As already explained flashing new firmware with U-Boot will do nothing to the "rootfs_data". It could result in new firmware reusing old "rootfs_data" overlay UBI volume and its file. Users expect a clean state after flashing firmware (even if flashing the same one). Solve that by reading flash counter of running firmware and storing it in "rootfs_data" UBI volume. Every mismatch will result in wiping old data. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 93259e8ca261c7965618fe11c2d385638da5cfa6)
* bcm4908: fix USB PHY supportRafał Miłecki2022-03-071-0/+147
| | | | | | | This fixes problem with USB PHY not handling some USB 3.0 devices. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 0dbcefdd5229daacf6cd4c9996b8e6f31c90ffd1)
* kernel: bump 5.4 to 5.4.182Hauke Mehrtens2022-03-061-30/+0
| | | | | | | | | | | | | | The following patch was integrated upstream: target/linux/bcm4908/patches-5.4/180-i2c-brcmstb-fix-support-for-DSL-and-CM-variants.patch All other updated automatically. The new config option CONFIG_BPF_UNPRIV_DEFAULT_OFF is now handled too. Compile-tested on: lantiq/xrx200, armvirt/64 Runtime-tested on: lantiq/xrx200, armvirt/64 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* bcm4908: backport watchdog and I2C changesRafał Miłecki2022-02-168-13/+141
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 923cc869a6eec7dd6fdf728b2adb05824e4b9ac0)
* bcm4908: backport first 5.18 DTS changesRafał Miłecki2022-02-163-19/+211
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit da8b720b0ecbb6d58f28a31b082b0c53be149a5a)
* bcm4908: backport bcm_sf2 patch for better LED registers supportRafał Miłecki2022-02-163-2/+211
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 840f07e532e081befc2465fd16a0388dd95e55fb)
* bcm4908: backport BCM4908 pinctrl driverRafał Miłecki2022-02-163-0/+747
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit b0145891676faa38f0a5991e3e229aed7b4a9117)
* bcm4908: include ATF in bootfs imagesRafał Miłecki2022-01-032-0/+16
| | | | | | | It's required for proper booting. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 65974aa18bf49005509e0c31ee3f3aa6fb186015)
* bcm4908: sysupgrade: add pkgtb format supportRafał Miłecki2022-01-031-2/+183
| | | | | | | | | | | | | | | BCM4908 devices with U-Boot use pkgtb firmware format. It's based on U-Boot's FIT: DTB with configurations, images & embedded data. This format contains bootfs, rootfs and optionally a first stage U-Boot loader. Contained images need to be extracted & flashed. Broadcom used two sets of firmwares: main & backup. It uses UBI volumes "metadata1" & "metadata2" for storing U-Boot env variables with info about flashed images. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 5f05795aa7716879e46fabbd0c51ff20ef9f13bf)
* bcm4908: add uboot-envtools to default packagesRafał Miłecki2022-01-031-1/+1
| | | | | | | It's required by sysupgrade to access UBI metadata partitions. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 444b4ea4a479d76761ee4833cb340b442dac662a)
* bcm4908: add fdt-utils to default packagesRafał Miłecki2022-01-031-1/+1
| | | | | | | It's required by sysupgrade. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 30b93672ec48d247fcd86b5bca283423db5250b9)
* bcm4908: sysupgrade: refactor handling different firmware formatsRafał Miłecki2022-01-031-32/+76
| | | | | | | | | | | This results in setting format specific data (format info, extract commands) in a single function. It should help maintaining sysupgrade code. This change has been tested on Asus GT-AC5300 and Netgear R8000P. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 30b168b9b8451d6165833cee75019ef7dbfd8a2e)
* bcm4908: build chk image for Netgear RAXE500Rafał Miłecki2021-12-131-1/+1
| | | | | | Fixes: 63ba3eaccdde ("bcm4908: start working on Netgear RAXE500 image") Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 0e8a5acf6eb4c689b6deed2146010b5b2c54fa78)
* bcm4908: start working on Netgear RAXE500 imageRafał Miłecki2021-12-132-0/+36
| | | | | | | | | bootfs still needs more work before it's ready. For some unknown reason model RAXE500 uses board id RAX220. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 63ba3eaccddeb8058b0fabd69197e650735573bc)
* bcm4908: enable MTD_CMDLINE_PARTSRafał Miłecki2021-12-131-0/+1
| | | | | | | | It's needed to support devices with U-Boot. That bootloader passes MTD layout using cmdline. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 21d28adbc1cc98c55858a73d62b9bf89c3874b08)
* bcm4908: continue work on images for U-Boot based devicesRafał Miłecki2021-12-133-0/+96
| | | | | | | It still isn't ready though - more data needs to be added to the bootfs. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 494c033f9cbad67ea2cee3860894bdfffea65109)
* bcm4908: backport upstream DT commitsRafał Miłecki2021-12-137-8/+234
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit d745835ae19caf1999924a434abd25e92cce4343)
* bcm4908: add watchdog supportRafał Miłecki2021-12-133-0/+77
| | | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 9565bd9bd61f026effce7ebfe17d413d1adb032f)
* bcm4908: start work on images for devices using U-BootRafał Miłecki2021-12-132-0/+36
| | | | | | | | | | | | | | | | | | | | | New BCM4908 family based routers will use U-Boot bootloader. That will require using a totally different firmware format. Kernel has to be put in a FIT image. OpenWrt has some helpers for generating .its files but they don't fit BCM4908 requirements and there is no simple way of extending any of them. The best solution seems to be storing an .its template. BCM4908 bootfs may: 1. contain extra binaries (other than kernel & DTB) 2. include multiple DTB files 3. store device specific U-Boot configurations with custom properties Such setups are too complex to generate using shell script. Raw .its file on the other hand seems quire clean & reasonable. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit a02c971dff934a11ddadf7ffd850dabcab5a3cdf)
* bcm4908: fix calculation of new cferam indexSungbo Eo2021-11-051-2/+2
| | | | | | | | | | | | | | The arithmetic expansion fails when idx becomes a two digit number. Fix this by relying on expr command. root@OpenWrt:/# echo $(((028 + 0) % 1000)) /bin/ash: arithmetic syntax error root@OpenWrt:/# echo $(($(expr 028 + 0) % 1000)) 28 Fixes: a6a0b252baa6 ("bcm4908: add sysupgrade support") Signed-off-by: Sungbo Eo <mans0n@gorani.run> (cherry picked from commit f4323538501d58298f4df73a034a51375a477cfc)
* kernel: bump 5.4 to 5.4.150Hauke Mehrtens2021-10-021-2/+2
| | | | | | | | | | | | | | | | | | Manually rebased: generic/backport-5.4/370-netfilter-nf_flow_table-fix-offloaded-connection-tim.patch generic/pending-5.4/800-bcma-get-SoC-device-struct-copy-its-DMA-params-to-th.patch mvebu/patches-5.4/021-arm64-dts-marvell-armada-37xx-Move-PCIe-comphy-handl.patch Removed upstreamed: generic/backport-5.4/040-ARM-8918-2-only-build-return_address-if-needed.patch layerscape/patches-5.4/819-uart-0004-MLK-18137-fsl_lpuart-Fix-loopback-mode.patch All others updated automatically. Compile-tested on: lantiq/xrx200, armvirt/64 Runtime-tested on: lantiq/xrx200, armvirt/64 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* bcm4908: fix Ethernet broken state after interface restartRafał Miłecki2021-06-221-0/+43
| | | | | | | This fixes traffic stalls after ifdown & ifup. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit f8d5bd20b31842ef7fdb740d27c70294f21c6124)
* bcm4908: add kmod-gpio-button-hotplugRafał Miłecki2021-06-221-0/+1
| | | | | | | | | All bcm4908 devices are expected to have GPIO buttons to make relevant package selected by default. This "fixes" triggering failsafe mode. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit fcfa60408c37a129b143e4928b6d86e383c2c8f6)
* kernel: bump 5.4 to 5.4.111Hauke Mehrtens2021-04-117-18/+18
| | | | | | | | | | | | | | | | | | | | | Refreshed all patches. The following patches were manually changed: * 610-netfilter_match_bypass_default_checks.patch * 611-netfilter_match_bypass_default_table.patch * 802-can-0002-can-rx-offload-fix-long-lines.patch * 802-can-0003-can-rx-offload-can_rx_offload_compare-fix-typo.patch * 802-can-0004-can-rx-offload-can_rx_offload_irq_offload_timestamp-.patch * 802-can-0005-can-rx-offload-can_rx_offload_reset-remove-no-op-fun.patch * 802-can-0006-can-rx-offload-Prepare-for-CAN-FD-support.patch * 802-can-0018-can-flexcan-use-struct-canfd_frame-for-CAN-classic-f.patch The can-dev.ko model was moved in the upstream kernel. Compile-tested on: x86/64, armvirt/64, ath79/generic Runtime-tested on: x86/64, armvirt/64, ath79/generic Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* bcm4908: enable Netgear R8000P bootloader imageRafał Miłecki2021-04-081-2/+2
| | | | | | | | | | | | | | | | | | | This enables building BCM4908 "raw" image that can be flashed using bootloader web UI. It requires serial console access & stopping booting by the "Press any key to stop auto run". It's easy to build vendor like CHK image but it can't be safely flashed using vendor UI at this point. Netgear implements method called "NAND incremental flashing" that doesn't seem to flash bootfs partition as provided. Above method seems to update vmlinux.lz without updating 94908.dtb. It prevents OpenWrt kernel from booting due to incomplete DTB file. Full Netgear R8000P support can be enabled after finding a way to make vendor firmware flash OpenWrt firmware including the 94908.dtb update. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit d92a9c97bf3700e90af1d3c9157502af660365c0)
* bcm4908: enable target & Asus GT-AC5300 imageRafał Miłecki2021-04-082-1/+3
| | | | | | | | | | OpenWrt was succesfully tested on the GT-AC5300 model. It's possible to: 1. Install OpenWrt using vendor UI 2. Perform UBI aware sysupgrade 3. Install vendor firmware using OpenWrt sysupgrade Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 5e78cb9b85a045f436abf6a03aa5c774d30e1090)
* firmware-utils: bcm4908img: convert into a packageRafał Miłecki2021-04-081-1/+3
| | | | | | | | | | | bcm4908img is a tool managing BCM4908 platform images. It's used for creating them as well as checking, modifying and extracting data from. It's required by both: host (for building firmware images) and target (for sysupgrade purposes). Make it a host/target package. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 9b4fc4cae9fa0cd0cd9060e1c9d33320c3249ced)
* bcm4908: fix Netgear R8000P imageRafał Miłecki2021-04-081-2/+5
| | | | | | | Use vendor format to allow flashing using Negear UI. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit f2c8c62d98f2137d8af896e56d5e29759cf48715)
* bcm4908: add sysupgrade supportRafał Miłecki2021-04-081-0/+213
| | | | | | | | | | | It supports flashing OpenWrt images (bootfs & UBI upgrade) as well as vendor images (whole MTD partition write). Upgrading cferom is unsupported. It requires copying device specific data (like MAC) to target image before flashing. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit a6a0b252baa6c19dfc62611ea910b56527ce4fa5)
* bcm4908: pad firmware image bootfs JFFS2 partition to 8 MiBRafał Miłecki2021-04-081-1/+1
| | | | | | | | | | This way MTD "bootfs" partition will be always 8+ MiB. This should be enough for any custom / future firmware to fit its bootfs (e.g. big kernel) without having to repertition whole flash. That way we can preserve UBI and its erase counters during sysupgrade. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit ca9b1f15c424d68af0f372c37c8eee81b36ee7e1)
* bcm4908: rename bootfs dummy file to the 1-openwrtRafał Miłecki2021-04-081-1/+1
| | | | | | | | | | | | | The purpose of that dummy file is to make CFE work properly with OpenWrt bootfs. CFE for some reason ignores JFFS2 files with ino 0. Rename it to 1-openwrt so: 1. It's consistent with bcm63xx 2. It's OpenWrt specific so sysupgrade can distinguish it from vendor images Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 880c8b44223c9cbce3dd14da78c33676c6f1a8a6)
* bcm4908: enable JFFS2 supportRafał Miłecki2021-04-081-1/+0
| | | | | | | It's needed for accessing JFFS2 bootfs partition. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 180c4635265b4907221a62b3068ac89447cd83d7)
* bcm4908: backport DT patch adding Ethernet MAC addressRafał Miłecki2021-04-081-0/+82
| | | | | | | | This tells OS (Linux) where from MAC should be read (bootloader MTD partition). Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 1cc5eb45d5192b41d97d5da58c34353f4c3240f9)
* bcm4908: backport the latest bcm_sf2 commitsRafał Miłecki2021-04-086-111/+210
| | | | | | | | 1. CFP support for BCM4908 2. Upstream RGMII regs fix Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit a49fd9db0a2bfad8ea9a09f32fadbd3cc7e46205)
* bcm4908: backport DTS patch with Ethernet TX IRQRafał Miłecki2021-04-082-1/+31
| | | | | | | It allows bcm4908_enet Linux driver to work more efficiently. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 13d9904acdd24e002aab3d6c3dd7879826b54008)
* kernel: backport 5.13 mtd partitioning changesRafał Miłecki2021-04-081-0/+1
| | | | | | | | | 1. Use upstream accepted NVMEM patches 2. Minor fix for BCM4908 partitioning 3. Support for Linksys firmware partitions on Northstar Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 3fd0a4222b6efbfbdb560c5b13e899ecda627494)
* kernel: bump 5.4 to 5.4.108Hauke Mehrtens2021-03-278-23/+23
| | | | | | | | | Refreshed all patches. Compile-tested on: x86_64, ath79, lantiq Runtime-tested on: x86_64, ath79 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* bcm4908: backport recent bcm_sf2 changesRafał Miłecki2021-03-177-8/+265
| | | | | | | One 5.12 link fix and 5.13 crossbar support. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit e1b4fd52a8efe1dfcad4f4fbe59f1c35a09be0bd)
* bcm4908: backport recent bcm4908_enet changesRafał Miłecki2021-03-174-0/+431
| | | | | | | This includes 5.12 fix and 5.13 improvements. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 7091e312307f4563d4a7afb5946140120cfa87fa)
* bcm4908: backport first PHY 5.13 patchesRafał Miłecki2021-03-172-3/+43
| | | | | | | | 1. Upstream accepted version of Kconfig change 2. Documentation binding fix Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit d7c8ca4d0b5c18c08e645f010fd0012f54c1c102)
* bcm4908: use accepted 5.13 DTS patchesRafał Miłecki2021-03-1712-50/+238
| | | | | | | | | | | | | Some patches were slightly cleaned up. One things worth mentioning is that adding: phy-mode = "rgmii" broke SF2 driver. It made it access random register breaking switch setup. That's why this commit also adds a quick sf2 fix. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 05dbfe616d551bce1a19d3846c8949c047325624)
* bcm4908: prepare to support TP-Link Archer C2300 V1Rafał Miłecki2021-03-175-0/+239
| | | | | | | | | | | It's a BCM4906 based device (2 CPU cores). It has 512 MiB of RAM, 4 LAN ports, 1 WAN port, 2 USB ports, NAND flash. WiFi unknown at this point. Flashing is possible using CFE only, proper image will be worked on later. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 8d24da14702b8da820bf2e3952d5691f77136018)
* kernel: add the latest mtd patch extending ofpart parserRafał Miłecki2021-03-171-650/+0
| | | | | | | | | | | | | This adds the latest version of ofpart commit. It hopefully 1. Doesn't break compilation 2. Doesn't break partitioning (this time). It's required to implement fixed partitioning with some quirks. It's required by bcm53xx, bcm4908, kirkwood, lantiq and mvebu. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit 7a7b2fd809809fbd7045bd3dad4fc896a6fef06f)
* bcm4908: backport Ethernet driver fixes from the 5.12Rafał Miłecki2021-03-174-2/+103
| | | | | | | The most noticeable one is fix for RX stopping on high traffic. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit acbea54bc29a22d8fb171bc9da0f1b16fb0ec233)
* bcm4908: add bcm_sf2 fixes for the 5th GPHYRafał Miłecki2021-03-172-0/+76
| | | | | | | | This allows using the last integrated PHY (and so e.g. WAN port on the ASUS GT-AC5300). Signed-off-by: Rafał Miłecki <rafal@milecki.pl> (cherry picked from commit ad8b759fd17bd31fdb7a026f247fd6ec81b372d3)
* bcm4908: fix GPIOs support by limiting them to 64Rafał Miłecki2021-02-151-0/+23
| | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl>