aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* realtek: Create rtl838x sub-target specific makefilesBirger Koblitz2022-02-173-128/+129
| | | | | | | | Create the RTL838x specific Makefiles. Move CPU-type into rtl838x.mk as this is specifc to that platform. Add rtl838x subtarget into main Makefile. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add initial kernel config for RTL838x sub-targetBirger Koblitz2022-02-171-0/+0
| | | | | | Move the generic kernel configs to the rtl838x sub-target. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add Makefile for RTL839x sub-architectureBirger Koblitz2022-02-171-0/+13
| | | | | | Adds the initial Makefile for the RTL839x sub-architecture. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Set RTL838X sub-target specific propertiesBirger Koblitz2022-02-171-1/+15
| | | | | | | This defines the sub-target specific properties for the RTL838X sub-target. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Create rtl838x subtargetBirger Koblitz2022-02-171-0/+0
| | | | | | | mv generic/target.mk to rtl838x/target.mk in order to create an initial makefile for the rtl838x sub-architecture Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add support for SFP EEPROM-access over SMBusBirger Koblitz2022-02-174-0/+294
| | | | | | | | | | | | | | | | | The EEPROMs on SFP modules are compatible both to I2C as well as SMBus. However, the kernel so far only supports I2C access. We add SMBus access routines, because the I2C driver for the RTL9300 HW only supports that protocol. At the same time we disable I2C access to PHYs on SFP modules as otherwise detection of any SFP module would fail. This is not in any way problematic at this point in time since the RTL93XX platform so far does not support PHYs on SFP modules. The patches are copied and rebased version of: https://bootlin.com/blog/sfp-modules-on-a-board-running-linux/ Signed-off-by: Daniel Golle <daniel@makrotopia.org> Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add support for RTL9300/RTL9310 I2C multiplexingBirger Koblitz2022-02-174-37/+359
| | | | | | | | | | | | The RTL9300/RTL9310 I2C controllers have support for 2 independent I2C masters, each with a fixed SCL pin, that cannot be changed. Each of these masters can use 8 (RTL9300) or 16 (RTL9310) different pins for SDA. This multiplexer directly controls the two masters and their shared IO configuration registers to allow multiplexing between any of these busses. The two masters cannot be used in parallel as the multiplex is protected by a standard multiplex lock. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add support for RTL9300/RTL9310 I2C controllerBirger Koblitz2022-02-174-0/+581
| | | | | | | | | | This adds support for the RTL9300 and RTL9310 I2C controller. The controller implements the SMBus protocol for SMBus transfers over an I2C bus. The driver supports selecting one of the 2 possible SCL pins and any of the 8 possible SDA pins. Bus speeds of 100kHz (standard speed) and 400kHz (high speed I2C) are supported. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: remove legacy GPIO driver supportBirger Koblitz2022-02-173-500/+0
| | | | | | | This patch removes support for the legacy GPIO driver, since now the gpio-otto driver can be used on all platforms Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add GPIO support for RTL930X and RTL931XBirger Koblitz2022-02-171-0/+165
| | | | | | | | We add support for the RTL930X and RTL931X architectures in the gpio-realtek-otto.c driver. Signed-off-by: Sebastian Gottschall <s.gottschall@dd-wrt.com> Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: drop support for Linux 5.4Daniel Golle2022-02-1763-16843/+0
| | | | | | | Drop patches and files for Linux 5.4 now that we've been using 5.10 for a while and support for Linux 5.4 has gone out-of-sync. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* base-files: Make sure rootfs_data_max is consideredDaniel Golle2022-02-171-8/+5
| | | | | | | | | | | | | | | For sysupgrade on NAND/UBI devices there is the U-Boot environment variable rootfs_data_max which can be used to limit the size of the rootfs_data volume created on sysupgrade. This stopped working reliable with recent kernels, probably due to a race condition when reading the number of free erase blocks from sysfs just after removing a volume. Change the script to just try creating rootfs_data with the desired size and retry with maximum size in case that fails. Hence calculating the available size in the script can be dropped which works around the problem. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* libnetfilter-conntrack: bump to 1.0.9Stijn Tintel2022-02-171-2/+2
| | | | | Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be> Acked-by: Jo-Philipp Wich <jo@mein.io>
* ath25: drop Linux 5.4 supportRui Salvaterra2022-02-1713-3843/+0
| | | | | | We've been bumped to 5.10, no need to carry this stuff anymore. Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
* ramips: fix NAND flash driver ECC bit position maskFelix Fietkau2022-02-161-1/+1
| | | | | | | | The bit position mask was accidentally made too wide, overlapping with the LSB from the byte position mask. This caused ECC calculation to fail for odd bytes Signed-off-by: Chad Monroe <chad.monroe@smartrg.com> Signed-off-by: Felix Fietkau <nbd@nbd.name>
* kernel: backport fix for initializing skb->cb in the bridge code to 5.4Felix Fietkau2022-02-162-2/+30
| | | | | | Fixes issues with proxyarp Signed-off-by: Felix Fietkau <nbd@nbd.name>
* bcm4908: backport watchdog and I2C changesRafał Miłecki2022-02-1616-26/+282
| | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* mt76: update to the latest versionFelix Fietkau2022-02-151-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | ddd3c2f38b30 mt76: redefine mt76_for_each_q_rx to adapt mt7986 changes 7fa5229a4228 mt76: improve signal strength reporting 025a72cd2d24 mt76: mt7915: fix injected MPDU transmission to not use HW A-MSDU 8c765fd92d97 mt76: mt7615: introduce SAR support 799a15bb68f9 mt76: fix endianness errors in reverse_frag0_hdr_trans c114919f0c08 mt76: mt7915: Fix channel state update error issue 93191a37e59a mt76: mt7915: fix potential memory leak of fw monitor packets cde589b2efb7 mt76: mt7921s: fix missing fc type/sub-type for 802.11 pkts 6ef22f4dc4e4 mt76: mt7915: add support for MT7986 7f1818cd8f2d mt76: mt7915: introduce band_idx in mt7915_phy 1d57a0d506db mt76: mt7915: initialize smps mode in mt7915_mcu_sta_rate_ctrl_tlv() 1f2a4816a3de mt76: mt7615: fix compiler warning on frame size d60f335e785b mt76: mt7915: fix endianness warnings in mt7915_debugfs_rx_fw_monitor d0ab636cb61c mt76: mt7915: fix endianness warnings in mt7915_mac_tx_free() 9d9bd7b3c48c mt76: connac: adjust wlan_idx size from u8 to u16 be1091f1172d mt76: mt7615: Fix assigning negative values to unsigned variable d4fc42889a30 mt76: mt7915: check band idx for bcc event 98ee3e2889ea mt76: mt7915: fix logic error and remove the unused member of mt7915_dev bbbbafb67bac mt76: mt7915: fix compiler warning abd80cf68db1 mt76: mt7915: fix the muru tlv issue a050c14b5631 mt76: mt7915: use min_t() to make code cleaner 9fee8f3736eb mt76: mt7915e: Fix degraded performance after temporary overheat f2e1a62cf0d0 mt76: mt7915e: Add a hwmon attribute to get the actual throttle state. c67df0d3130a mt76: mt7915e: Enable thermal management by default Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mac80211: fix traffic stalls on forwarded mesh packets due to wrong AC selectionFelix Fietkau2022-02-151-0/+50
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* feeds: use git-src-full to allow Git versioningPaul Spooren2022-02-152-9/+9
| | | | | | | | | | | | | | | Both $(AUTORELEASE) and $(PKG_SRC_VERSION) (from luci.git) use the Git log to determine releases and package timestamps. Feeds are shallow cloned by default, resulting in an incomplete Git log and therefore different local package versions than offered upstream. This commits sets the default feeds to use `src-git-full` to solve that. Add fixes from "2b1d92f: scripts/feeds: silence git warning by selecting pull style" to `src-git-full` Signed-off-by: Paul Spooren <mail@aparcar.org>
* build: store source_date_epoch as integerPaul Spooren2022-02-141-1/+1
| | | | | | | | | The value is retreived from a env variable which defaults to be read as a string. However the SOURCE_DATE_EPOCH is a unix timestamp aka integer. Fix this to allow downstream tools to parse the value directly. Signed-off-by: Paul Spooren <mail@aparcar.org>
* kernel: fix a race condition leading to a crash in hw flow offloadingFelix Fietkau2022-02-141-5/+6
| | | | | | | flowtable->net was initialized too late, and this could be triggered even without hardware offload support on the device Signed-off-by: Felix Fietkau <nbd@nbd.name>
* kernel: fix copy&paste mistake in bridge offload codeFelix Fietkau2022-02-141-1/+1
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* ramips: mt7621: do memory detection on KSEG1Chuanhong Guo2022-02-141-0/+58
| | | | | | | | | | | | | | | | | | | | It's reported that current memory detection code occasionally detects larger memory under some bootloaders. Current memory detection code tests whether address space wraps around on KSEG0, which is unreliable because it's cached. Rewrite memory size detection to perform the same test on KSEG1 instead. While at it, this patch also does the following two things: 1. use a fixed pattern instead of a random function pointer as the magic value. 2. add an additional memory write and a second comparison as part of the test to prevent possible smaller memory detection result due to leftover values in memory. Fixes: 6d91ddf517 ("ramips: mt7621: add support for memory detection") Reported-by: Rui Salvaterra <rsalvaterra@gmail.com> Tested-by: Rui Salvaterra <rsalvaterra@gmail.com> Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
* procd: simplify uxc init scriptDaniel Golle2022-02-131-7/+1
| | | | | | | | 'uxc boot' is inteded to be called multiple times, so there is not need to guard the first call on boot -- the actual code anyway didn't do that, so just remove it. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* kernel: remove 640-bridge-only-accept-EAP-locally.patchFelix Fietkau2022-02-122-164/+0
| | | | | | | The issue of EAP frames sent to group address (or the wrong address) has been addressed in mac80211, so this hack is no longer needed Signed-off-by: Felix Fietkau <nbd@nbd.name>
* kernel: add a fast path for the bridge codeFelix Fietkau2022-02-122-4/+821
| | | | | | | | | This caches flows between MAC addresses on separate ports, including their VLAN in order to bypass the normal bridge forwarding code. In my test on MT7622, this reduces LAN->WLAN bridging CPU usage by 6-10%, potentially even more on weaker platforms Signed-off-by: Felix Fietkau <nbd@nbd.name>
* tcpdump: Fix CVE-2018-16301Hauke Mehrtens2022-02-122-1/+102
| | | | | | | | | | | This fixes the following security problem: The command-line argument parser in tcpdump before 4.99.0 has a buffer overflow in tcpdump.c:read_infile(). To trigger this vulnerability the attacker needs to create a 4GB file on the local filesystem and to specify the file name as the value of the -F command-line argument of tcpdump. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* mac80211: fix rekey failure in drivers with 802.3 decap offloadFelix Fietkau2022-02-121-0/+43
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* firewall4: update to latest Git HEADJo-Philipp Wich2022-02-121-3/+3
| | | | | | | | | | | | | 53caa1a fw4: resolve zone layer 2 devices for hw flow offloading 9fe58f5 fw4: rework and fix family inheritance logic 8795296 tests: mocklib: fix infinite recursion in wrapped print() 281b1bc tests: change mocked wan interface type to PPPoE 93b710d tests: mocklib: forward compatibility change 1a94915 fw4: only stage reflection rules if all required addrs are known 5c21714 fw4: add device iifname/oifname matches to DSCP and MARK rules 3eacc97 tests: adjust 01_ruleset test case to latest changes Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* ucode: update to latest Git HEADJo-Philipp Wich2022-02-121-3/+3
| | | | | | | | a29bad9 compiler: fix patchlist corruption on switch statement syntax errors 86f0662 lib: change `ord()` to always return single byte value 116a8ce vallist: fix storing/retrieving short strings with 8bit byte value Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* kernel: bump 5.10 to 5.10.100John Audia2022-02-117-11/+11
| | | | | | | | | | All patches automatically rebased. Build system: x86_64 Build-tested: bcm2711/RPi4B, mt7622/RT3200 Run-tested: bcm2711/RPi4B, mt7622/RT3200 Signed-off-by: John Audia <graysky@archlinux.us>
* kernel: bump 5.10 to 5.10.99John Audia2022-02-116-58/+7
| | | | | | | | | | | | | | | | | | | | Had to update generic defconfig (make kernel_menuconfig CONFIG_TARGET=generic) for this bump, but since that only modifies the target defined in .config, and since that target also needed to be updated for unrelated reasons, manually propagated the newly added symbol to the generic config. Removed upstreamed: pending-5.10/860-Revert-ASoC-mediatek-Check-for-error-clk-pointer.patch[1] All other patches automatically rebased. 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.99&id=080f371d984e8039c66db87f3c54804b0d172329 Build system: x86_64 Build-tested: bcm2711/RPi4B, mt7622/RT3200 Run-tested: bcm2711/RPi4B, mt7622/RT3200 Signed-off-by: John Audia <graysky@archlinux.us>
* kernel: bump 5.10 to 5.10.98John Audia2022-02-1126-92/+68
| | | | | | | | | | | | | Manually rebased: bcm27xx/patches-5.10/950-0675-drm-vc4-hdmi-Drop-devm-interrupt-handler-for-CEC-int.patch All other patches automatically rebased. Build system: x86_64 Build-tested: bcm2711/RPi4B, mt7622/RT3200 Run-tested: bcm2711/RPi4B, mt7622/RT3200 Signed-off-by: John Audia <graysky@archlinux.us>
* ramips: add support for ELECOM WRC-2533GS2INAGAKI Hiroshi2022-02-112-0/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ELECOM WRC-2533GS2 is a 2.4/5 GHz band 11ac (Wi-Fi 5) router, based on MT7621A. Specification: - SoC : MediaTek MT7621A - RAM : DDR3 128 MiB (NT5CC64M16GP-DI) - Flash : SPI-NOR 16 MiB (MX25L12835FM2I-10G) - WLAN : 2.4/5GHz 4T4R (2x MediaTek MT7615) - Ethernet : 10/100/1000 Mbps x5 - Switch : MediaTek MT7530 (SoC) - LEDs/Keys : 4x/6x (2x buttons, 1x slide-switch) - UART : through-hole on PCB - J4: 3.3V, GND, TX, RX from ethernet port side - 57600n8 - Power : 12 VDC, 1.5 A Flash instruction using factory image: 1. Boot WRC-2533GS2 normally with "Router" mode 2. Access to "http://192.168.2.1/" and open firmware update page ("ファームウェア更新") 3. Select the OpenWrt factory image and click apply ("適用") button 4. Wait ~120 seconds to complete flashing MAC Addresses: LAN : 04:AB:18:xx:xx:FB (Factory, 0xFFF4 (hex)) WAN : 04:AB:18:xx:xx:FC (Factory, 0xFFFA (hex)) 2.4 GHz : 04:AB:18:xx:xx:FD (Factory, 0x4 (hex)) 5 GHz : 04:AB:18:xx:xx:FE (Factory, 0x8004 (hex)) Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ramips: move MAC configs to device dts from wrc-gs-2pci.dtsiINAGAKI Hiroshi2022-02-117-24/+144
| | | | | | | | | | | | | | | | | | | | | | The locations of MAC addresses in mtd for LAN/WAN on ELECOM WRC-2533GS2 are changed from the other WRC-GS/GST devices with 2x PCIe. So move the related configurations in mt7621_elecom_wrc-gs-2pci.dtsi to dts of each model. - WRC-1750GS - WRC-1750GSV - WRC-1750GST2 - WRC-1900GST - WRC-2533GST - WRC-2533GST2 -> LAN: 0xE000, WAN: 0xE006 - WRC-2533GS2 -> LAN: 0xFFF4, WAN: 0xFFFA Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ramips: update WLAN MAC address of ipTIME A3004TSungbo Eo2022-02-111-0/+6
| | | | | | | | | | | | | | | | Reported MAC addresses: | interface | MAC address | source | comment |-----------|-------------------|----------------|--------- | LAN | 90:xx:xx:18:xx:1F | | [1] | WAN | 90:xx:xx:18:xx:1D | | | WLAN 2G | 92:xx:xx:48:xx:1C | | | WLAN 5G | 90:xx:xx:18:xx:1C | factory 0x4 | | | 90:xx:xx:18:xx:1C | config ethaddr | [1] Used in this patch as WLAN 2G MAC address with the local bit set Signed-off-by: Sungbo Eo <mans0n@gorani.run>
* ramips: add support for ipTIME AX2004MSungbo Eo2022-02-115-0/+197
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ipTIME AX2004M is an 802.11ax (Wi-Fi 6) router, based on MediaTek MT7621A. Specifications: * SoC: MT7621A * RAM: 256 MiB * Flash: NAND 128 MiB * Wi-Fi: * MT7915D: 2.4/5 GHz (DBDC) * Ethernet: 5x 1GbE * Switch: SoC built-in * USB: 1x 3.0 * UART: J4 (115200 baud) * Pinout: [3V3] (TXD) (RXD) (GND) MAC addresses: | interface | MAC address | source | comment |-----------|-------------------|----------------|--------- | LAN | 58:xx:xx:00:xx:9B | | [1] | WAN | 58:xx:xx:00:xx:99 | | | WLAN 2G | 58:xx:xx:00:xx:98 | factory 0x4 | | WLAN 5G | 5A:xx:xx:40:xx:98 | | | | 58:xx:xx:00:xx:98 | config ethaddr | [1] Used in this patch as WLAN 5G MAC address with the local bit set Load addresses: * stock * 0x80010000: FIT image * 0x81001000: kernel image -> entry * OpenWrt * 0x80010000: FIT image * 0x82000000: uncompressed kernel+relocate image * 0x80001000: relocated kernel image -> entry Notes: * This device has a dual-boot partition scheme, but this firmware works only on boot partition 1. The stock web interface will flash only on the inactive boot partition, but the recovery web page will always flash on boot partition 1. Installation via recovery mode: 1. Press reset button, power up the device, wait >10s for CPU LED to stop blinking. 2. Upload recovery image through the recovery web page at 192.168.0.1. Revert to stock firmware: 1. Install stock image via recovery mode. Signed-off-by: Sungbo Eo <mans0n@gorani.run>
* octeon: switch to Kernel 5.10Paul Spooren2022-02-111-2/+1
| | | | | Acked-by: Stijn Tintel <stijn@linux-ipv6.be> Signed-off-by: Paul Spooren <mail@aparcar.org>
* target/linux: add missing symbolRosen Penev2022-02-111-0/+1
| | | | | | Found when building the qoriq target. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* tools/cmake: add MAKE config variableRosen Penev2022-02-111-1/+2
| | | | | | | | | Makes sure that Ninja from staging_dir is used and nowhere else. Reported by reproducible builds project. Builds have been failing ever since tools/cmake started using Ninja. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* qosify: update to the latest versionFelix Fietkau2022-02-101-3/+3
| | | | | | | | e230e71e0a12 map: fix copy-paste error in codepoints map 580d2ccf89f3 bpf: declare tcp_ports/udp_ports without typedef 8d6c19a81f3f ubus: fix a use-after-free bug Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mt7622: linksys-e8450: enable using mt7531 switch irqDaniel Golle2022-02-101-0/+4
| | | | | | | | Turns out the MT7531 switch IRQ line is connected to GPIO#53 just like on the BPi-R64, so this seems to be part of the reference design and will probably apply to most MT7622+MT7531 boards. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mt7622: bpi-r64: enable using mt7531 switch irqDaniel Golle2022-02-101-0/+13
| | | | | | | | | | Now that we support link-state-change interrupts, wire up MT7531 IRQ line which is connected to GPIO#53 according to the schematics [1]. As a result, PHY state no longer needs to be polled on that board. [1]: https://forum.banana-pi.org/t/bpi-r64-mt7622-schematic-diagram-public/10118 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* kernel: backport MT7530 IRQ supportDENG Qingfang2022-02-102-0/+428
| | | | | | | | | | | Support MT7530 PHY link change interrupts, and enable for MT7621. For external MT7530, a GPIO IRQ line is required, which is board-specific, so it should be added to each DTS. In case the interrupt-controller property is missing, it will fall back to polling mode. Signed-off-by: DENG Qingfang <dqfext@gmail.com>
* ath25: switch to 5.10 KernelPaul Spooren2022-02-101-1/+1
| | | | | Tested-by: Chuanhong Guo <gch981213@gmail.com> Signed-off-by: Paul Spooren <mail@aparcar.org>
* kernel: backport MediaTek Ethernet PHY driverDENG Qingfang2022-02-095-0/+163
| | | | | | | | | | | | | | Add support for MediaTek Gigabit Ethernet PHYs found in MT7530 and MT7531. Fix some link up/down issues. The errornous check for the PHY mode which broke things with MT7531 has been removed as suggested by patch net: phy: mediatek: remove PHY mode check on MT7531 As a result, things are working fine now on MT7622+MT7531 as well. Signed-off-by: DENG Qingfang <dqfext@gmail.com> Tested-by: Daniel Golle <daniel@makrotopia.org> Tested-by: Arınç ÜNAL <arinc.unal@arinc9.com> Tested-by: Stijn Tintel <stijn@linux-ipv6.be>
* meta: drop issue_templateJo-Philipp Wich2022-02-091-13/+0
| | | | | | | The contents do not apply anymore now that the switch to Github issue has been decided. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* kernel: generic: select the fq_codel qdisc by defaultRui Salvaterra2022-02-092-101/+4
| | | | | | | | | The kernel configuration allows us to select a default qdisc. Let's do this for 5.10 (as 5.4 is on its way out) and get rid of the hacky patch we've been carrying. Acked-by: Jo-Philipp Wich <jo@mein.io> Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
* ucode: update to latest Git HEADJo-Philipp Wich2022-02-081-4/+4
| | | | | | a317c17 compiler: fix incorrect loop break targets Signed-off-by: Jo-Philipp Wich <jo@mein.io>