Commit Graph

791 Commits

Author SHA1 Message Date
Rui Salvaterra
72d2c54ccb kernel: 5.10: allocate last level PTEs in high memory
Enable support for allocating user space page table entries in high memory [1],
for the targets which support this feature. This saves precious low memory
(permanently mapped, the only type of memory directly accessible by the kernel).

[1] https://www.kernel.org/doc/html/latest/vm/highmem.html

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2022-03-01 22:57:34 +00:00
Rui Salvaterra
61e58f7cec kernel: bump 5.10 to 5.10.92
Patches automatically rebased.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2022-01-16 20:51:14 +01:00
Sergey Ryazanov
fa3690f8f1 kernel: 5.10: consolidate mac80211 crypto options
Each of
- CRYPTO_AEAD2
- CRYPTO_AEAD
- CRYPTO_GF128MUL
- CRYPTO_GHASH
- CRYPTO_HASH2
- CRYPTO_HASH
- CRYPTO_MANAGER2
- CRYPTO_MANAGER
- CRYPTO_NULL2

either directly required for mac80211 crypto support, or directly
selected by such options. Support for the mac80211 crypto was enabled in
the generic config since c7182123b9 ("kernel: make cryptoapi support
needed by mac80211 built-in"). So move the above options from the target
configs to the generic config to make it clear why do we need them.

CC: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
2021-12-17 16:16:34 +01:00
Sergey Ryazanov
b61ab8f57e kernel: filter out both Clang and LLD versions
Both CLANG_VERSION and LLD_VERISON are autogenerated runtime
configuration options, so add them to the kernel configuration filter
and remove from generic and per-target configs to keep configs clean.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
2021-12-17 16:16:34 +01:00
John Audia
a696e325f7 kernel: bump 5.4 to 5.4.165
All patches automatically rebased.

Build system: x86_64
Build-tested: ramips/mt7621*

*FS#4149 affects me so I had to revert 7f1edbd412
in order to downgrade to 2.35.1

Signed-off-by: John Audia <graysky@archlinux.us>
2021-12-17 15:10:22 +01:00
Rafał Miłecki
3bcf3e8143 bcm53xx: sysupgrade: fix support for Luxul's legacy firmware format
Fixes: 80041dea70 ("bcm53xx: sysupgrade: refactor handling different firmware formats")
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-12-13 18:19:35 +01:00
John Audia
6c945fa379 kernel: bump 5.10 to 5.10.83
Removed upstreamed:
    bcm53xx/patches-5.10/033-v5.16-0024-ARM-dts-BCM5301X-Fix-I2C-controller-interrupt.patch[1]
    bcm53xx/patches-5.10/033-v5.16-0025-ARM-dts-BCM5301X-Add-interrupt-properties-to-GPIO-no.patch[2]

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.83&id=b2cd6fdcbe0a5cb44e4610a08cc58261d494a885
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.83&id=9db1d4a3c2700e1cc84c3d61199411d75c2a3ec6

Build system: x86_64*
Build-tested: bcm2711/RPi4B, ipq806x/R7800†
Run-tested: bcm2711/RPi4B, ipq806x/R7800†

* Had to revert 7c99085bd6 in order to build
  (latest bump of ca-certificates)

† Had to revert 7f1edbd412 in order to build
  (binutils 2.37, https://bugs.openwrt.org/index.php?do=details&task_id=4149)

Signed-off-by: John Audia <graysky@archlinux.us>
2021-12-12 21:11:30 +01:00
Rafał Miłecki
80041dea70 bcm53xx: sysupgrade: refactor handling different firmware formats
List of supported formats grew over time and implementation got a bit
messy. There are multiple functions with format-specific parameters and
commands.

Refactor it by making platform_identify() setup all required info right
after detecting firmware format. This simplifies formats handling in
platform_other_check_image() and platform_do_upgrade() a lot.

This has been tested on:
1. SmartRG SR400ac (TRX): non-NAND sysupgrade
2. Netgear R8000 (CHK): NAND aware and standard sysupgrade-s
3. D-Link DIR-885L (Seama): NAND aware and standard sysupgrade-s
4. Luxul XWR-3150 (LXL): NAND aware and standard sysupgrade-s

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-12-02 09:15:18 +01:00
Rafał Miłecki
e7bd6cce4c bcm53xx: sysupgrade: simplify extracting image from Seama seal
Use "oseama extract" which supports now writing to stdout.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-12-02 09:15:18 +01:00
Hauke Mehrtens
be3fcd72e9 kernel: Deactivate B53 symbols in generic configuration
Deactivate all the symbols of the B53 DSA driver in the generic kernel
configuration. Multiple targets are now using this drivers and they
only need some of the options.
This fixes the bcm4908 build which didn't deactivate all of the options.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-11-29 22:37:58 +01:00
John Audia
894f483d20 kernel: bump 5.10 to 5.10.82
Removed upstreamed:
    bcm53xx/patches-5.10/033-v5.16-0014-ARM-dts-NSP-Fix-mpcore-mmc-node-names.patch

Manually rebased:
    ipq806x/patches-5.10/086-ipq8064-fix-duplicate-node.patch

All other patches automatically rebased.

Build system: x86_64
Build-tested: bcm2711/RPi4B, ipq806x/R7800
Run-tested: bcm2711/RPi4B, ipq806x/R7800

Signed-off-by: John Audia <graysky@archlinux.us>
2021-11-27 19:19:30 +01:00
Rafał Miłecki
824ac6e11c bcm53xx: fix platform clocks & USB 2.0 PHY
This fixes WARNing, missing clocks and
[   10.422481] bcm_ns_usb2 1800c164.usb2-phy: Clock not defined

Fixes: 5901917b93 ("bcm53xx: use more upsteam DT patches from 5.16 / 5.17")
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-23 13:49:10 +01:00
Rafał Miłecki
1d7c1a4198 bcm53xx: use new USB 2.0 PHY binding
This fixes:
[   10.440495] bcm_ns_usb2 1800c000.usb2-phy: can't request region for resource [mem 0x1800c000-0x1800cfff]
[   10.450039] bcm_ns_usb2 1800c000.usb2-phy: Failed to map DMU regs
[   10.456183] bcm_ns_usb2: probe of 1800c000.usb2-phy failed with error -16
caused by conflict in allocating resources.

Fixes: f55f1dbaad ("bcm53xx: switch to the kernel 5.10")
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-23 13:49:10 +01:00
Rafał Miłecki
294fa3770b bcm53xx: specify switch ports on TP-LINK devices
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-22 15:23:22 +01:00
Rui Salvaterra
3ae5da5adc kernel: bump 5.10 to 5.10.80
Deleted (upstreamed):
ath79/patches-5.10/921-serial-core-add-support-for-boot-console-with-arbitr.patch [1]
bcm53xx/patches-5.10/033-v5.15-0012-ARM-dts-BCM5301X-Fix-memory-nodes-names.patch [2]
lantiq/patches-5.10/0016-mtd-rawnand-xway-Keep-the-driver-compatible-with-on-.patch [3]
lantiq/patches-5.10/0110-MIPS-lantiq-dma-add-small-delay-after-reset.patch [4]
lantiq/patches-5.10/0111-MIPS-lantiq-dma-reset-correct-number-of-channel.patch [5]
lantiq/patches-5.10/0112-MIPS-lantiq-dma-fix-burst-length-for-DEU.patch [6]

Manually rebased:
ipq806x/patches-5.10/0065-arm-override-compiler-flags.patch

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.80&id=47462c5e600fbaffd755cd13dedd80d04e41ff83
[2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.80&id=2fde76df1885a6bec04317e457121326070450eb
[3] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.80&id=9b366f5221d8aa64b22f35be137a5749326444ce
[4] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.80&id=5af57ce8a6155fe3e4270d28d171abf8903bebc0
[5] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.80&id=b92a5df2c7adc79a57481445f67de0c1c716581f
[6] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.10.80&id=6b72caabc47011d03f44064452b2c65e8ed18326

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-11-19 09:40:29 +00:00
Rafał Miłecki
5901917b93 bcm53xx: use more upsteam DT patches from 5.16 / 5.17
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-18 16:34:55 +01:00
Rafał Miłecki
4e9be47087 bcm53xx: drop patch for downstream swconfig-based b53
It isn't used anymore so there is no need to hack CPU port. Upstream
(DSA-based) b53 also supports all switch ports just fine.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-08 15:58:42 +01:00
Rafał Miłecki
406c5002b8 bcm53xx: drop downstream patch for Buffalo WZR-1750DHP button
This patch never received a proper description and was never sent
upstream as supposed. It was meant to be handled in 2015-2018 so it
should be safe to assume noone really understands it or care.

Cc: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-08 15:58:30 +01:00
Rui Salvaterra
4b26ba4155 kernel: bump 5.10 to 5.10.77
Deleted (upstreamed):
bcm53xx/patches-5.10/081-v5.15-Revert-pinctrl-bcm-ns-support-updated-DT-binding-as-.patch [1]

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-5.10.y&id=01c2881bb0e0a71b87ca425e1b763ac13855aa7e

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-11-06 14:24:07 +01:00
Rafał Miłecki
1ee6d3d24e bcm53xx: add first 5.17 DTS changes
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-11-04 07:00:21 +01:00
Rui Salvaterra
02026d0a6f kernel: bump 5.10 to 5.10.76
Deleted (upstreamed):
bcm27xx/patches-5.10/950-0145-xhci-add-quirk-for-host-controllers-that-don-t-updat.patch [1]

Manually rebased:
bcm27xx/patches-5.10/950-0355-xhci-quirks-add-link-TRB-quirk-for-VL805.patch
bcm53xx/patches-5.10/180-usb-xhci-add-support-for-performing-fake-doorbell.patch

Note: although automatically rebaseable, the last patch has been edited to avoid
conflicting bit definitions.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-5.10.y&id=b6f32897af190d4716412e156ee0abcc16e4f1e5

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-10-30 21:17:20 +02:00
Christian Lamparter
6102f883ce bcm53xx: MR32: replace i2c-gpio with SoC's i2c
During review of the MR32, Florian Fainelli pointed out that the
SoC has a real I2C-controller. Furthermore, the connected pins
(SDA and SCL) would line up perfectly for use. This patch swaps
out the the bitbanged i2c-gpio with the real deal.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2021-10-30 15:00:22 +02:00
Rafał Miłecki
a2f5a83af8 bcm53xx: backport patch fixing pinctrl driver
This switches pinctrl driver to use the old & good DT binding. There is
no more need to adjust upstream DTS file.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-10-29 15:30:47 +02:00
Rafał Miłecki
b8e682ac74 bcm53xx: bridge all LAN ports on Linksys EA9500
External switch ports need to be bridged too.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-10-22 13:46:22 +02:00
Rafał Miłecki
e9672b1a8f bcm53xx: switch to the upstream DSA-based b53 driver
1. Drop swconfig
2. Simplify network setup
3. Verify network config
4. Disable Buffalo WZR-900DHP for now - it misses ports definition

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Reviewed-By: Christian Lamparter <chunkeey@gmail.com>
2021-10-21 17:38:17 +02:00
Rafał Miłecki
287257d676 bcm53xx: enable Linksys EA6300 & EA9200 builds
Both should be supported since:
1. Adding NVMEM driver for NVRAM
2. Using NVRAM info for determining active firmware partition

Linksys EA9500 uses very similar design and works fine.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-10-18 16:09:36 +02:00
Rafał Miłecki
fd71ef34b7 kernel: backport bgmac upstream commits from 5.15 / for 5.16
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-10-07 11:30:18 +02:00
Hauke Mehrtens
50f456b46c kernel: bump 5.4 to 5.4.150
Manually rebased:
  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:
  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>
2021-10-02 16:45:56 +02:00
Rui Salvaterra
b4cee3b63f kernel: bump 5.10 to 5.10.70
Deleted (upstreamed):
bcm53xx/patches-5.10/181-Revert-USB-bcma-Add-a-check-for-devm_gpiod_get.patch

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-09-30 22:29:33 +01:00
Rui Salvaterra
2bf320a5e5 kernel: bump 5.10 to 5.10.69
Patches automatically refreshed.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-09-30 22:29:33 +01:00
Rui Salvaterra
3a2c16d1d2 kernel: bump 5.10 to 5.10.65
Manually refreshed:
generic/pending-5.10/800-bcma-get-SoC-device-struct-copy-its-DMA-params-to-th.patch
bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch
bcm27xx/patches-5.10/950-0087-firmware-raspberrypi-Add-backward-compatible-get_thr.patch

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-09-30 22:29:33 +01:00
Christian Lamparter
608baf44c6 bcm53xx: MR32: read mac-address from eeprom
Meraki wrote the ethernet MAC-address of the device
onto the eeprom (AT24C64) at the fixed location 0x66
to 0x6C. Let's fetch it from there.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2021-09-23 20:50:58 +02:00
Damien Mascord
fd67908647 scripts: mkits.sh: Allow legacy @ mode for dts creation
commit 5ec60cbe9d ("scripts: mkits.sh: replace @ with - in nodes")
broke support for Meraki MR32 and this patch makes the replacement
configurable allowing for specifying the @ or - or whatever character
that is desired to retain backwards compatibility with existing devices.

For example, this patch includes the fix for the Meraki MR32 in
target/linux/bcm53xx/image for meraki_mr32:

  DEVICE_DTS_DELIMITER := @
  DEVICE_DTS_CONFIG := config@1

Fixes: 5ec60cbe9d ("scripts: mkits.sh: replace @ with - in nodes")
Signed-off-by: Damien Mascord <tusker@tusker.org>
[Added tags, checkpatch.pl fixes, noted that this is for old stuff]
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2021-09-23 20:49:32 +02:00
Rafał Miłecki
366be2183e bcm53xx: backport early DT patches queued for 5.16
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-09-23 07:55:55 +02:00
Rafał Miłecki
a46fa5c3a7 bcm53xx: drop DTS based workaround for serial support in procd
Specifying serial in bootargs is not needed since the commit
ffeb37047e ("procd: update to git HEAD"). It's thanks to the procd
commit 2cfc26f8456a ("inittab: detect active console from kernel if no
console= specified").

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-09-16 07:59:50 +02:00
John Audia
a88b32bf6e kernel: bump 5.4 to 5.4.145
Removed upstreamed:
  generic-backport/040-ARM-8918-2-only-build-return_address-if-needed.patch

All other patches automatically rebased.

Build system: x86_64
Build-tested: ipq806x/R7800

Signed-off-by: John Audia <graysky@archlinux.us>
2021-09-13 17:08:17 +02:00
John Audia
5fb4cb07e2 kernel: bump 5.10 to 5.10.64
All patches automatically rebased.

Build system: x86_64
Build-tested: bcm2711/RPi4B, ipq806x/R7800
Run-tested: bcm2711/RPi4B, ipq806x/R7800

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
2021-09-13 17:08:17 +02:00
Rafał Miłecki
ae33ce2af2 bcm53xx: specify switch ports for more devices
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-09-07 13:23:16 +02:00
Rafał Miłecki
f55f1dbaad bcm53xx: switch to the kernel 5.10
With PCI and USB regressions fixed it should be safe to switch now.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-08-31 11:41:09 +02:00
Rafał Miłecki
9b40346328 bcm53xx: fix kmod-i2c-bcm-iproc for kernel 5.10
I2C_BCM_IPROC selects I2C_SLAVE which in turn makes two new symbols
available: I2C_SLAVE_EEPROM and I2C_SLAVE_TESTUNIT. That was causing:

I2C support (I2C) [M/n/y/?] m
  Enable compatibility bits for old user-space (I2C_COMPAT) [N/y/?] n
  I2C device interface (I2C_CHARDEV) [M/n/?] m
  I2C bus multiplexing support (I2C_MUX) [N/m/?] n
  Autoselect pertinent helper modules (I2C_HELPER_AUTO) [N/y/?] n
    SMBus-specific protocols (I2C_SMBUS) [N/m/?] n
  I2C/SMBus Test Stub (I2C_STUB) [N/m/?] n
  I2C slave support (I2C_SLAVE) [Y/?] y
    I2C eeprom slave driver (I2C_SLAVE_EEPROM) [N/m/?] n
    I2C eeprom testunit driver (I2C_SLAVE_TESTUNIT) [N/m/?] (NEW)

Ideally I2C_SLAVE should probably be packaged as kmod-i2c-slabe. For now
just modify kmod-i2c-bcm-iproc to fix kernel compilation.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-08-31 11:41:04 +02:00
Rafał Miłecki
62465c75be bcm53xx: fix USB in kernel 5.10
This makes USB controller driver work with USBs that are always powered
on (don't require toggling any GPIO).

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-08-31 09:34:40 +02:00
Rafał Miłecki
8a4d4d4243 bcm53xx: backport missed DT patch cleaning up CRU block
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-08-30 09:00:28 +02:00
Rafał Miłecki
bce00f47e5 bcm53xx: backport the latest upstream DT changes
This includes:
1. BCM5301X changes from 5.14 and queued 5.15 stuff
2. NSP changes from 5.11 - 5.15 for kernel 5.10

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-08-29 22:57:13 +02:00
Rui Salvaterra
505b7a2d08 kernel: move two symbols to the generic kconfigs
CONFIG_RCU_{NEED_SEGCBLIST,STALL_COMMON} are set basically everywhere. Move them
to the generic kconfigs. And resort the generic kconfigs while at it.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-08-29 17:07:19 +02:00
Rui Salvaterra
39d12b0155 kernel: bump 5.10 to 5.10.55
No deleted or manually refreshed patches.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-08-08 17:57:34 +02:00
John Audia
bd3cb93034 kernel: bump 5.4 to 5.4.136
All patches automatically rebased.

Build system: x86_64
Build-tested: ipq806x/R7800
Run-tested: ipq806x/R7800

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
2021-07-31 19:13:00 +02:00
Rafał Miłecki
e88ab3b629 bcm53xx: refresh kernel 5.10 config
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-07-29 14:56:14 +02:00
Rafał Miłecki
d8e8a2a8db bcm53xx: add testing support for kernel 5.10
It still requires fixing PCIe support:
[    6.644699] pcie_iproc_bcma bcma0:7: host bridge /axi@18000000/pcie@12000 ranges:
[    6.652217] pcie_iproc_bcma bcma0:7:   No bus range found for /axi@18000000/pcie@12000, using [bus 00-ff]
[    6.661833] OF: /axi@18000000/pcie@12000: Missing device_type
[    6.667622] pcie_iproc_bcma: probe of bcma0:7 failed with error -12
[    6.673985] pcie_iproc_bcma bcma0:8: host bridge /axi@18000000/pcie@13000 ranges:
[    6.681514] pcie_iproc_bcma bcma0:8:   No bus range found for /axi@18000000/pcie@13000, using [bus 00-ff]
[    6.691137] pcie_iproc_bcma: probe of bcma0:8 failed with error -12
[    6.697522] pcie_iproc_bcma bcma0:9: host bridge /axi@18000000/pcie@14000 ranges:
[    6.705048] pcie_iproc_bcma bcma0:9:   No bus range found for /axi@18000000/pcie@14000, using [bus 00-ff]
[    6.714669] pcie_iproc_bcma: probe of bcma0:9 failed with error -12

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-07-29 14:56:14 +02:00
John Audia
3e1c92f9e1 kernel: bump 5.4 to 5.4.118
Manually rebased:
  ath79/patches-5.4/0033-spi-ath79-drop-pdata-support.patch

Removed uneeded patch:
  ath79/patches-5.4/0050-spi-ath79-remove-spi-master-setup-and-cleanup-assign.patch

All other patches automatically rebased.

Build system: x86_64
Build-tested: ipq806x/R7800
Run-tested: ipq806x/R7800

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
2021-05-23 15:09:06 +02:00
Rui Salvaterra
3326b5e75c treewide: switch the timer frequency to 100 Hz
Some targets select HZ=100, others HZ=250. There's no reason to select a higher
timer frequency (and 100 Hz are available in every architecture), so change all
targets to 100 Hz.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-04-21 10:31:10 +01:00
Rui Salvaterra
27b5bae2ec treewide: remove redundant ubifs kconfig symbols
For the targets which enable ubifs, these symbols are already part of the
generic kconfigs. Drop them from the target kconfigs.

Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
2021-04-21 10:31:07 +01:00
Rafał Miłecki
53546c3e94 bcm53xx: fix Luxul XWR-3150 LAN ports numbering
Port numbers were reverted.

Fixes: c459a6bf48 ("bcm53xx: add support for Luxul FullMAC WiFi devices")
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-04-21 07:35:10 +02:00
Rafał Miłecki
a3c7633ddc bcm53xx: add pending TRX patch for "firmware" partition
This fixes partitioning on Linksys EA9500. With this change only the
currently used firmware MTD partition gets parsed.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-04-14 08:27:30 +02:00
Vivek Unune
209c5918b5 bcm53xx: enhance support for Linksys EA9500
1. Add leds and configs
2. Add network configs
3. Add script to clear partial boot flag
4. Hack to use port 5 as cpu port as port 8 connected to eth2
   wont pass any frames
5. Enable EA9500 image generation

Hardware Info:

- Processor - Broadcom BCM4709C0KFEBG dual-core @ 1.4 GHz
- Switch - BCM53012 in BCM4709C0KFEBG & external BCM53125
- DDR3 RAM - 256 MB
- Flash - 128 MB (Toshiba TC58BVG0S3HTA00)
- 2.4GHz - BCM4366 4×4 2.4/5G single chip 802.11ac SoC
- Power Amp - Skyworks SE2623L 2.4 GHz power amp (x4)
- 5GHz x 2 - BCM4366 4×4 2.4/5G single chip 802.11ac SoC
- Power Amp - PLX Technology PEX8603 3-lane, 3-port PCIe switch
- Ports - 8 Ports, 1 WAN Ports
- Antennas - 8 Antennas
- Serial Port - @j6 [GND,TX,RX] (VCC NC) 115200 8n1

Flashing Instructions:

1. Connect a USB-TTL table to J6 on the router as well as a
   ethernet cable to a lan port and your PC.
2. Power-on the router.
3. Use putty or a serial port program to view the terminal.
   Hit Ctrl+C and interrupt the CFE terminal terminal.
4. Setup a TFTP server on your local machine at setup you
   local IP to 192.168.1.2
5. Start the TFTP Server
6. Run following commands at the CFE terminal

   flash -noheader 192.168.1.2:/openwrt.trx nflash0.trx
   flash -noheader 192.168.1.2:/openwrt.trx nflash0.trx2
   nvram set bootpartition=0 && nvram set partialboots=0 && nvram commit

7. Reboot router to be presented by OpenWrt

Note: Only installation method via serial cable is supported at the moment.
The trx firmware has to be flashed to both the partitions using following
commands from CFE prompt. This will cover US and Non-US variants.

Signed-off-by: Vivek Unune <npcomplete13@gmail.com>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-04-01 08:58:14 +02:00
Rafał Miłecki
22369ad788 bcm53xx: use upstream Linksys EA9500 fixes
One fix was accepted, one was added.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-04-01 07:12:42 +02:00
Rafał Miłecki
f8669c174e bcm53xx: fix Linksys EA9500 partitions
Use proper DT binding.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-03-29 09:29:16 +02:00
Rafał Miłecki
3fd0a4222b kernel: backport 5.13 mtd partitioning changes
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>
2021-03-29 08:46:17 +02:00
John Audia
2c81b16964 kernel: bump 5.4 to 5.4.106
Ran update_kernel.sh in a fresh clone without any existing toolchains.

Manually rebased:
  bcm27xx/950-0993-xhci-quirks-add-link-TRB-quirk-for-VL805.patch
  layerscape/701-net-0231-enetc-Use-DT-protocol-information-to-set-up-the-port.patch

Build system: x86_64
Build-tested: ipq806x/R7800
Run-tested: ipq806x/R7800

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
[remove accidental whitespace edit]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-03-21 22:45:20 +01:00
Rafał Miłecki
98d456a14e bcm53xx: backport first 5.13 DTS changes
This adds NVMEM bindings that are needed for proper booting on Linksys
devices.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-03-14 19:11:05 +01:00
Rafał Miłecki
baf04eed02 bcm53xx: initialize NVRAM from NVMEM driver
NVRAM access may be needed early in boot process. Reading it using mtd
happens quite late in the init process. Add NVRAM initialization to the
NVMEM driver which comes up early and depends on IO mapping only.

This is required by Linksys devices which use NVRAM content for proper
partitioning (detecting current firmware partition).

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-03-12 18:22:18 +01:00
Rafał Miłecki
01b1b37528 bcm53xx: backport NVMEM NVRAM driver
It supports NVRAM access described using DT binding. Right now NVRAM
data is exposed using /sys/bus/nvmem/ only.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-03-10 23:23:47 +01:00
Rafał Miłecki
af8a49a4be Revert "bcm53xx: add support for reading NVRAM based on DT mapping"
This reverts commit b0376462c1. Those
changes were rejected and were replaced with an NVMEM driver.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-03-10 22:29:15 +01:00
Adrian Schmutzler
85b1f4d8ca treewide: remove execute bit and shebang from board.d files
So far, board.d files were having execute bit set and contained a
shebang. However, they are just sourced in board_detect, with an
apparantly unnecessary check for execute permission beforehand.

Replace this check by one for existance and make the board.d files
"normal" files, as would be expected in /etc anyway.

Note:

This removes an apparantly unused '#!/bin/sh /etc/rc.common' in
target/linux/bcm47xx/base-files/etc/board.d/01_network

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-03-06 11:30:06 +01:00
Rafał Miłecki
b0376462c1 bcm53xx: add support for reading NVRAM based on DT mapping
This is required for devices that use NVRAM data for detecting currently
used firmware partition (e.g. Linksys devices).

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-03-02 09:07:46 +01:00
Rafał Miłecki
8078d89a53 bcm53xx: backport more upstream dts stuff from kernel 5.11
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-02-25 21:17:38 +01:00
Vivek Unune
39ed2265dd bcm53xx: backport Linksys Panamera (EA9500) patches
These patches have been already accepted.

302-ARM-dts-BCM5301X-Update-Northstar-pinctrl-binding.patch had to
be updated.

[rmilecki: use actual upstream accepted patches
           replace v5.10 with v5.11 to match actual upstream kernel
           recover dropped part of the pinctrl compatible patch
           update filenames
           refresh patches]

Signed-off-by: Vivek Unune <npcomplete13@gmail.com>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-02-25 21:17:38 +01:00
Rafał Miłecki
d0ee398c36 bcm53xx: group dts backports by upstream kernel version
It's a simple renaming thing.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2021-02-25 21:17:38 +01:00
Adrian Schmutzler
ef2cb8572b treewide: rename IMAGE_PREFIX/IMAGE_NAME to DEVICE_IMG_*
We so far had two variables IMG_PREFIX and IMAGE_PREFIX with
different content. Since these names are obviously quite
confusing, this patch renames the latter to DEVICE_IMG_PREFIX,
as it's a device-dependent variable, while IMG_PREFIX is only
(sub)target-dependent.

For consistency, also rename IMAGE_NAME to DEVICE_IMG_NAME, as
that's a device-dependent variable as well.

Cc: Paul Spooren <mail@aparcar.org>
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-02-25 18:11:06 +01:00
John Audia
e95b1b23f1 kernel: bump 5.4 to 5.4.97
Ran update_kernel.sh in a fresh clone without any existing toolchains.

Manually rebased:
 bcm27xx
  950-0267-xhci-add-quirk-for-host-controllers-that-don-t-updat.patch
 bcm53xx
  180-usb-xhci-add-support-for-performing-fake-doorbell.patch
 layerscape
  302-dts-0008-arm64-dts-ls1046a-accumulated-change-to-ls1046a-boar.patch
  820-usb-0016-MLK-16735-usb-host-add-XHCI_CDNS_HOST-flag.patch
  820-usb-0018-MLK-18794-1-usb-host-xhci-add-.bus_suspend-override.patch

Build system: x86_64
Build-tested: bcm27xx/bcm2711, ipq806x/R7800
Run-tested: ipq806x/R7800

No dmesg regressions/everything functional.

Signed-off-by: John Audia <graysky@archlinux.us>
[remove quilt comment, fix/adjust 820-usb-* layerscape patches]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-02-11 16:08:28 +01:00
Adrian Schmutzler
598b29585e target: use SPDX license identifiers on Makefiles
Use SPDX license tags to allow machines to check licenses.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-02-10 15:47:18 +01:00
Adrian Schmutzler
4571ef48d8 bcm53xx: use default SUPPORTED_DEVICES for Meraki MR32
Since the new global SUPPORTED_DEVICES are now available in bcm53xx
as well, we do not need to specify an explicit value for the MR32
anymore.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-01-23 23:42:47 +01:00
Sungbo Eo
583e39e3d5 kernel: drop empty kmod-ledtrig-* packages
The following four led triggers are enabled in generic config.

* kmod-ledtrig-default-on
* kmod-ledtrig-heartbeat
* kmod-ledtrig-netdev
* kmod-ledtrig-timer

Drop the packages and remove them from DEVICE_PACKAGES.
There's no other package depending on them in this repo.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
2021-01-15 18:24:31 +01:00
Adrian Schmutzler
9b1b89229f kernel: bump 5.4 to 5.4.86
Removed upstreamed patches:
  pending-5.4/499-mtd-parser-cmdline-Fix-parsing-of-part-names-with-co.patch

Manually merged:
  pending-5.4/611-netfilter_match_bypass_default_table.patch
  layerscape/302-dts-0112-arm64-dts-fsl-ls1028a-prepare-dts-for-overlay.patch

Build-tested: ipq806x/R7800, bcm27xx/bcm2711, ath79/{generic,tiny},
              ipq40xx, octeon, ramips/mt7621, realtek, x86/64
Run-tested: ipq806x/R7800, realtek

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Tested-by: John Audia <graysky@archlinux.us>
Tested-by: Stijn Segers <foss@volatilesystems.org>
2021-01-01 17:07:28 +01:00
Aleksander Jan Bajkowski
77575d4c02 kernel: move some disabled symbols to generic
Move some disabled config options found in lantiq target to generic.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
2020-12-22 19:11:50 +01:00
Moritz Warning
d69ec61f7d bcm53xx: use correct case for TP-Link in DEVICE_VENDOR
Adjust spelling of vendor names to what is used in other places.

Signed-off-by: Moritz Warning <moritzwarning@web.de>
[improve commit title/message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-12-19 19:42:00 +01:00
Christian Lamparter
c29f6121fd bcm53xx: MR32: fix DEVICE_VENODR typo
DEVICE_VENDOR was misspelled as DEVICE_VENODR.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-12-13 17:16:36 +01:00
John Audia
a47279154e kernel: bump 5.4 to 5.4.75
Manually rebased patches:
  bcm27xx:
    patches-5.4/950-0267-xhci-add-quirk-for-host-controllers-that-don-t-updat.patch
  bcm53xx:
    patches-5.4/180-usb-xhci-add-support-for-performing-fake-doorbell.patch
  layerscape:
    patches-5.4/802-can-0025-can-flexcan-add-LPSR-mode-support-for-i.MX7D.patch
    patches-5.4/808-i2c-0002-MLK-10893-i2c-imx-add-irqf_no_suspend.patch
    patches-5.4/820-usb-0016-MLK-16735-usb-host-add-XHCI_CDNS_HOST-flag.patch

Removed since could be reverse-applied by quilt:
  mediatek:
    patches-5.4/0700-arm-dts-mt7623-add-missing-pause-for-switchport.patch

All modifications made by update_kernel.sh

Build system: x86_64
Build-tested: ipq806x/R7800, ath79/generic, bcm27xx/bcm2711, x86_64
Run-tested: ipq806x/R7800, x86_64

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
Tested-by: Curtis Deptuck <curtdept@me.com> [x86_64]

Rebase of 802-can-0025-can-flexcan-add-LPSR-mode-support-for-i.MX7D.patch
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
2020-11-10 13:11:32 +01:00
Adrian Schmutzler
2785126650 kernel: remove support for kernel 4.19
We use 5.4 on all targets by default, and 4.19 has never been released
in a stable version. There is no reason to keep it.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-10-30 19:29:59 +01:00
Daniel Golle
37ef2197e6 kernel: move kmod-i2c-bcm-iproc to I2C menu
A typo resulted in that module having it's own menu.
Move it into the I2C menu as it was most likely intended.

Fixes: 1291274335 ("kernel: package bcm53xx i2c module")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2020-10-30 15:47:52 +00:00
John Audia
d6a9a92e32 kernel: bump 5.4 to 5.4.69
Seemingly unneeded based on new upstream code so manually deleted:
 layerscape:
  820-usb-0007-usb-dwc3-gadget-increase-timeout-value-for-send-ep-c.patch

Manually merged:
 generic-hack:
  251-sound_kconfig.patch

All other modifications made by update_kernel.sh

Build system: x86_64
Build-tested: ipq806x/R7800, ath79/generic, bcm27xx/bcm2711
Run-tested: ipq806x/R7800, lantiq/Easybox 904 xDSL

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
[add lantiq test report, minor commit message clarification]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-10-02 22:02:26 +02:00
Christian Lamparter
0e4092cbad bcm53xx: add Cisco Meraki MR32
This patch adds support for Cisco Meraki MR32.
The unit was donated by Chris Blake. Thank you!

WARNING:
Only the 1x1:1 abgn Air Marshal WIPS wifi is currently supported by b43:
 b43-phy2: Found PHY: Analog 9, Type 4 (N), Revision 16
 b43-phy2: Found Radio: Manuf 0x17F, ID 0x2057, Revision 9, Version 1
 b43-phy2: Loading firmware version 784.2 (2012-08-15 21:35:19)
 and only as 802.11ABG!

while WIFI1 and WIFI2 (both BCM4352) are not:
 b43-phy0: Broadcom 4352 WLAN found (core revision 42)
 b43-phy0 ERROR: FOUND UNSUPPORTED PHY (Analog 12, Type 11 (AC), Revision 1)

Hardware Highlights:

SoC:	Broadcom BCM53016A1 (1 GHz, 2 cores)
RAM:	128 MiB
NAND:	128 MiB Spansion S34ML01G2 (~114 MiB useable)
ETH:	1GBit Ethernet Port - PoE
WIFI1:	Broadcom BCM43520 an+ac (2x2:2 - id: 0x4352)
WIFI2:	Broadcom BCM43520 bgn (2x2:2 - id: 0x4352)
WIFI3:	Broadcom BCM43428 abgn (1x1:1 - id: 43428)

BLE:	Broadcom BCM20732 (ttyS1)
LEDS:   1 x Programmable RGB Status LED (driven by a PWM)
	1 x White LED (GPIO)
	1 x Orange LED Fault Indicator (GPIO)
	2 x LAN Activity / Speed LEDs (On the RJ45 Port)
BUTTON: one Reset button
MISC:   AT24C64 8KiB EEPROM (i2c - stores Ethernet MAC + Serial#!)
	ina219 hardware monitor (i2c)
	Kensington Lock

SERIAL:
	WARNING: The serial port needs a TTL/RS-232 3V3 level converter!
	The Serial setting is 115200-8-N-1. The board has a populated
	right angle 1x4 0.1" pinheader.
	The pinout is: VCC, RX, TX, GND. (Use a multimeter)

Flashing needs a serial adaptor (due to the lack of a working dropbear on
the original firmware).

This flashing procedure for the MR32 was tested with firmware:
"r23-149867:150252-aacharya".

0. Create a seperate Ethernet LAN which does not have access to the internet.
   Ideally use 192.168.1.2 for your PC. Make sure to reserve 192.168.1.1 it
   will be used later on by the OpenWrt firmware. The original Meraki firmware
   will likely try to setup the network via DHCP Discovery, so make sure your
   PC is running a DHCP-Server (i.e.: dnsmasq)
   '# dnsmasq -i eth# -F 192.168.1.5,192.168.1.50
   Furthermore, the PC needs a supported ssh/http/ftp server in order to
   retrieve the initramfs + dtb file

1. Disassemble the MR32 device by removing all screws (4 screws are located
   under the 4 rubber feets!) and prying open the plastic covers without
   breaking the plastic retention clips. Once inside, remove all the screws
   on the outer metal shielding to get to the PCB. It's not necessary to
   remove the antennas!

2. Connect the serial cable to the serial header.

3. Partially reassemble the outer metal shielding to ensure that the SoC
   has a proper heat sink.

4. Connect the Ethernet patch cable to the device and the power cable.

5. Wait for the device to boot and enter the root shell.
   (rooting is not discussed in detail here please refer to
   Chris Blake - "pwning the meraki mr18" blog post:
   <https://servernetworktech.com/2016/02/pwning-the-meraki-mr18/>
   (The same method works with the MR32's r23-149867:150252-aacharya)

   Wait for the MR32 to enter the "<Meraki>" prompt and enter:
   <Meraki> odm serial_num read
   (Verify that it matches what's on the S/N Sticker on the back!)
   <Meraki> odm serial_num write Q2XX-XXXX-XXXV
   <Meraki> odm serial_num read
   (Verify that the S/N has changed - and the LED start to flash)

   now to flash the firmware:
   <Meraki> odm firmware part.safe "http://192.168.1.2/mr32-initramfs.bin"

Once OpenWrt booted use sysupgrade to permanently install
OpenWrt. To do this: Download the latest sysupgrade.bin file
for the MR32 to the device and use sysupgrade *sysupgrade.bin
to install it.

WARNING: DO NOT DELETE the "storage" ubi volume!

To flash later MR32 Firmwares like r25-201804051805-G885d6d78-dhow-rel
requires in-circut-i2c tools to access the I2C EEPROM AT24C64 next to
the SoC. The idea is pretty much the same as from Step 5 from above:
Change the serial number to Q2XXXXXXXXXV (should be around 0x7c), then
attach a serial cable, ethernet (but make sure the device can't reach
the internet!) hit "s" (the small s!) during boot to enter the root-shell
and add the following commands to the /storage/config there:

serial_allow_odm true
serial_access_enabled true
serial_access_check false
valid_config true

and then hit exit to let it finish booting.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-09-25 19:32:34 +02:00
Christian Lamparter
1291274335 kernel: package bcm53xx i2c module
The BCM5301x SoCs do have i2c. Since this is only
being used by the Meraki MR32, this will be packaged
as a module.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-09-25 19:32:34 +02:00
Christian Lamparter
5f610ec4b8 bcm53xx: backport uart2 and pcie2 device-nodes
These have made their way into -next. This patch
also includes the portion of the bcm53xx kernel
patch refreshes as the hunks in
302-ARM-dts-BCM5301X-Update-Northstar-pinctrl-binding.patch
moved slightly due to the added nodes.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-09-25 19:32:34 +02:00
Christian Lamparter
c6d9a2ac59 bcm53xx: enable PWM for bcm53xx
The Meraki MR32 (BCM53016A1) uses the pwm to drive the
tricolor LED. The driver has been available in upstream
for a long time. Only the Device-Tree definition was
missing, but it has been queued recently.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-09-25 19:32:33 +02:00
Petr Štetiar
a14f5bb4bd treewide: use wpad-basic-wolfssl as default
In order to support SAE/WPA3-Personal in default images. Replace almost
all occurencies of wpad-basic and wpad-mini with wpad-basic-wolfssl for
consistency. Keep out ar71xx from the list as it won't be in the next
release and would only make backports harder.

Build-tested (build-bot settings):
ath79: generic, ramips: mt7620/mt76x8/rt305x, lantiq: xrx200/xway,
sunxi: a53

Signed-off-by: Petr Štetiar <ynezz@true.cz>
[rebase, extend commit message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-08-20 14:19:39 +02:00
John Audia
da98603597 kernel: bump 5.4 to 5.4.58
This PR is a blend of several kernel bumps authored by ldir taken from his
staging tree w/ some further adjustments made by me and update_kernel.sh

Summary:
Deleted upstreamed patches:
  generic:
    742-v5.5-net-sfp-add-support-for-module-quirks.patch
    743-v5.5-net-sfp-add-some-quirks-for-GPON-modules.patch
  bcm63xx:
    022-v5.8-mtd-rawnand-brcmnand-correctly-verify-erased-pages.patch
    024-v5.8-mtd-rawnand-brcmnand-fix-CS0-layout.patch
  mediatek:
    0402-net-ethernet-mtk_eth_soc-Always-call-mtk_gmac0_rgmii.patch

Deleted patches applied differently upstream:
  generic:
    641-sch_cake-fix-IP-protocol-handling-in-the-presence-of.patch

Manually merged patches:
  generic:
    395-v5.8-net-sch_cake-Take-advantage-of-skb-hash-where-appropriate.patch
  bcm27xx:
    950-0132-lan78xx-Debounce-link-events-to-minimize-poll-storm.patch
  layerscape:
    701-net-0231-enetc-Use-DT-protocol-information-to-set-up-the-port.patch

Build system: x86_64
Build-tested: ath79/generic, bcm27xx/bcm2708, bcm27xx/bcm2711,
  imx6, mvebu/cortexa9, sunxi/a53
Run-tested: Netgear R7800 (ipq806x)

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
Tested-By: Lucian Cristian <Lucian.cristian@gmail.com> [mvebu]
Tested-By: Curtis Deptuck <curtdept@me.com> [x86/64]
[do not remove 395-v5.8-net-sch_cake-Take-advantage-... patch,
adjust and refresh patches, adjust commit message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Tested-By: John Audia <graysky@archlinux.us> [ipq806x]
2020-08-18 18:14:54 +02:00
Adrian Schmutzler
5388c72517 Revert "bcm53xx: remove useless echo in 02_network"
This reverts commit b1f6a5d9df.

In this particular case, the echo command was _not_ useless, but
converted the newlines back to spaces.

Add a comment into the code to make that obvious for the next one
looking at it like me.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-08-18 11:46:59 +02:00
Adrian Schmutzler
b1f6a5d9df bcm53xx: remove useless echo in 02_network
The output is already produced in the inner $() brackets, no need
to catch and echo it again.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-08-17 23:16:58 +02:00
Adrian Schmutzler
92b4f16bab kernel: add CGROUPS and IOSCHED_BFQ back to config
After those symbols have been removed from generic kernel config,
they were added to the target config during every kernel config
refresh. As that's not desirable, add them back to the generic
config.

Fixes: d1a8217d87 ("kernel: clean-up build-configurable kernel config symbols")
Fixes: cfe235c436 ("kernel: modules: add package kmod-iosched-bfq")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-08-12 14:03:17 +02:00
Adrian Schmutzler
683bcbdce1 bcm53xx: use vendor_model scheme for device/image names
Most targets have been updated to consistently use the vendor_model
scheme for device definitions and thus, image names.

Apply this to bcm53xx as well. This does _not_ apply any other
specific naming changes.

Cc: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-08-12 11:08:05 +02:00
Felix Fietkau
b0f7ea2853 kernel: unify CONFIG_GPIO_SYSFS in kernel configs
Enable it for all platforms

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2020-08-06 12:37:04 +02:00
Rafał Miłecki
7125323b81 bcm53xx: switch to kernel 5.4
Switch, USB, WiFi, buttons tested on BCM47094.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2020-08-04 13:28:56 +02:00
Rafał Miłecki
36c53e0dd2 bcm53xx: set HW_RANDOM_BCM2835=y
This enables Random Number Generator support on Northstar (described in
DT with brcm,bcm5301x-rng).

It's also a workaround for OpenWrt bug with kernel config causing:
Broadcom BCM2835/BCM63xx Random Number Generator support (HW_RANDOM_BCM2835) [Y/n/m/?] (NEW)

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2020-08-04 13:27:19 +02:00
Rafał Miłecki
c8c9876607 bcm53xx: update kernel 5.4 DTS to upstream 5.9 state
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2020-08-04 13:27:19 +02:00
Rafał Miłecki
b9cd55b88e bcm53xx: update kernel 5.4 config
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
2020-08-04 13:27:19 +02:00
Petr Štetiar
e9f7923a1d treewide: mark devices as BROKEN instead of commenting out
This adds the newly introduced BROKEN flag to a bunch of devices
that previously just had TARGET_DEVICES commented out. By this, we
can select them in make menuconfig when BROKEN developer config option
is selected, instead of having to edit the code.

In contrast to DEFAULT := n, this is meant to cover devices that
don't boot or don't compile at all.

ath25: np25g, wpe53g
  both disabled during kernel bump 3.18->4.4 without reason given
  f89a20a89a ("ath25: update kernel from 3.18 to 4.4")

bcm53xx: linksys-ea6300-v1, linksys-ea9200, linksys-ea9500
  broken due to insufficient/broken TRX support
  55ff15cfd5 ("bcm53xx: disable building Linksys EA6300 V1 image")
  cd0f9900a4 ("bcm53xx: parepare for building more Linksys images")

bcm63xx: tplink-archer-c5-v2, tplink-archer-c9-v1
  disabled when kernel 5.4 support was added, probably broken
  50c6938b95 ("bcm53xx: add v5.4 support")

Signed-off-by: Petr Štetiar <ynezz@true.cz>
[limit to subset of devices, use BROKEN, adjust commit message/title]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-07-30 21:49:22 +02:00
Petr Štetiar
504000d520 treewide: use DEFAULT := n to disable non-broken devices
This uses DEFAULT := n on a bunch of devices that previously were
"disabled" by commenting out TARGET_DEVICES. This will allow to
build them without having to modify the code, but they will not
be selected for default build or buildbots.

The change is applied to all devices that are not "broken", but suffer
from image site limitations or similar, or have been added in the past
but never confirmed to run on the device properly:

at91: at91-q5xr5:
  kernel image too big
  31aeae0774 ("at91: do not build image for at91-q5xr5")

bcm47xx: asus-rt-ac66u:
  disabled since it was added in 2015
  69aefc771f ("brcm47xx: build images for Asus devices")

bcm47xx: netgear-wndr3400-vcna, netgear-wnr3500u, netgear-wnr3500-v2-vc
  added disabled in 2012, but never confirmed to work on devices
  5dec9dd3b2 ("brcm47xx: add code to generate images for some netgear
    devices")

bcm53xx: netgear-r8500
  added disabled: "start working on Netgear R8500"
  3b76c7cf0b ("bcm53xx: start working on Netgear R8500")

Signed-off-by: Petr Štetiar <ynezz@true.cz>
[limit to subset of devices, adjust commit message/title]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-07-30 21:48:38 +02:00
Hauke Mehrtens
6062d85892 kernel: Update kernel 4.19 to version 4.19.131
Fixes:
- CVE-2020-10757

The "mtd: rawnand: Pass a nand_chip object to nand_release()" commit was
backported which needed some adaptations to other code.

Run tested: ath79
Build tested: ath79

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2020-07-04 21:12:42 +02:00
Adrian Schmutzler
48c1fdd046 treewide: drop shebang from non-executable target files
This drops the shebang from all target files for /lib and
/etc/uci-defaults folders, as these are sourced and the shebang
is useless.

While at it, fix the executable flag on a few of these files.

This does not touch ar71xx, as this target is just used for
backporting now and applying cosmetic changes would just complicate
things.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-06-16 14:26:33 +02:00
Petr Štetiar
e5aa498acb kernel: bump 5.4 to 5.4.45
Fixes CVE-2020-10757 via upstream commit df4988aa1c96 ("mm: Fix mremap
not considering huge pmd devmap").

Resolved merge conflict in the following patches:

 bcm27xx: 950-0128-gpiolib-Don-t-prevent-IRQ-usage-of-output-GPIOs.patch

Refreshed patches, removed upstreamed patch:

 generic: 751-v5.8-net-dsa-mt7530-set-CPU-port-to-fallback-mode.patch
 generic: 754-v5.7-net-dsa-mt7530-fix-roaming-from-DSA-user-ports.patch

Run tested: qemu-x86-64
Build tested: x86/64, imx6, sunxi/a53

Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-06-09 16:59:33 +02:00