Commit Graph

30 Commits (fbd4214bb0727268aa535af5b600d38939ec8dbc)

Author SHA1 Message Date
Felix Fietkau 431b177afa mediatek: fix mt7622-rfb1 board support
Make GPIO keys active-low.
Add DSA support

Signed-off-by: Felix Fietkau <nbd@nbd.name>
4 years ago
John Crispin 5a5031e70b mediatek: generate UBI images for the rev board
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
Petr Štetiar c7b750e7ac treewide: kernel: drop redundant USB_EHCI_HCD=n config symbol
Commit e53ec043ba ("kirkwood: move usb support to modules") has moved
this config symbol into generic configs, so it could be removed from
other configs.

Suggested-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
4 years ago
John Crispin ad39d06df7 mediatek: add mt7531 DSA support
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
John Crispin f72a2b004c mediatek: add bpi-r64 emmc support
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
Felix Fietkau 81b59efefd ramips/mediatek: select kmod-mt7615-firmware where kmod-mt7615e is selected
The new mt76 version splits out the firmware, because the driver can also be
used for MT7663/MT7613

Signed-off-by: Felix Fietkau <nbd@nbd.name>
4 years ago
John Crispin af5a17dbb2 mediatek: add support for rtl8367c
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
John Crispin 08df22e2ab mediatek: drop v4.14 support
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
John Crispin beb9820ed3 mediatek: consolidate partition names and settings
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
John Crispin 3a8dbcf5c2 mediatke: add support for elecom-wrc-2533gent
This commit adds support for the MT7622-based Elecom WRC-2533gent router,
with spi-nand storage and 512MB RAM.

The device has the following specifications:

* MT7622 (arm64 dual-core)
* 512MB RAM (DDR3)
* 4GB storage (spi-nand)
* 5x 1Gbps Ethernet (RTL8337C switch)
* 1x UART header
* 1x USB 3.0 port
* 5x LEDs
* 1x reset button
* 1x WPS button
* 1x slider switch
* 1x DC jack for main power (12V)

The following has been tested and is working:
* Ethernet switch
* 2.4g and 5g wifi
* USB 3.0 port
* sysupgrade
* buttons/leds

Not working:
* bluetooth firmware does not load even though it is present int he rootfs

Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
John Crispin d3f058db1c mediatek: more v5.4 mtd fixes
Signed-off-by: John Crispin <john@phrozen.org>
4 years ago
Chuanhong Guo ed7751f968 mediatek: move mt76 and wpad-bacic to mt7622 subtarget
mt76 is a target default package for mt7622-wmac only.
mt7623 doesn't have integrated wireless support and wifi drivers for
pcie cards should be added as device specific package.
mt7629-wmac isn't supported by mt76 yet.

Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
4 years ago
Yousong Zhou 860652f4b9 kernel: 5.4: move some kconfig options to generic
CONFIG_64BIT_TIME=y
	CONFIG_KASAN_STACK=1
	CONFIG_UBSAN_ALIGNMENT=y
	CONFIG_UNIX_SCM=y
	CONFIG_DMA_DECLARE_COHERENT=y
	CONFIG_OF_RESERVED_MEM=y

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
4 years ago
David Bauer 0d727f231f treewide: move commonly disabled symbols to generic config
Move new commonly disabled kernel 5.4 symbols to the generic kernel
configuration.

Signed-off-by: David Bauer <mail@david-bauer.net>
4 years ago
Mark-MC Lee (李明昌) 25d9df670b mediatek: add v5.4 support
Signed-off-by: Mark-MC Lee (李明昌) <Mark-MC.Lee@mediatek.com>
4 years ago
Adrian Schmutzler e845c094d5 mediatek: split base-files into subtargets
This splits some base-files across subtargets, as done previously
on ath79 and ramips and also introduced for mt7629 subtarget here
already. Most of the existing base-files content is specific to
mt7623.

While at it, apply the following fixes:
- Remove lots of trailing whitespaces
- Remove wildcard on unielec,u7623-02-emmc-512m
- Remove inconsistent quotation marks in cases

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: John Crispin <john@phrozen.org>
4 years ago
Petr Štetiar 3bbcffa0b6 treewide: kernel config: remove runtime options
Remove CC_HAS_ASM_GOTO, CC_IS_GCC and GCC_VERSION kernel config options
which are set at runtime and which should be ignored now.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
5 years ago
Sungbo Eo 68014f6d6e mediatek: remove unnecessary execute permission bit
kernel config and dts files do not need to be executable. 644 is enough.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
5 years ago
Lorenzo Bianconi 14054e2982 mediatek: enable mtk_efuse by default
Enable by default mtk_efuse driver since it needed by mtk_thermal driver
to read sensor calibration data

Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
5 years ago
John Crispin 66458c49aa mediatek: add v4.19 support
Bump the target to v4.19. Add a patch with additional eth driver
fixes/features that MTK provided aswell as the driver for the new mt7530
switch.

Signed-off-by: John Crispin <john@phrozen.org>
5 years ago
Hauke Mehrtens 46af22de16 kernel: Remove CONFIG_COMPAT
This removes support for executing old 32 bit applications on 64 bit ARM
and MIPS kernels.
On OpenWrt we normally compile all the user space applications on our
own and do not support third party binary only modules especial not 32
bit applications on 64 bit CPUs.

This reduces the attack surface on such systems and should also save
some memory.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 years ago
Hauke Mehrtens 32eb66881c kernel: Activate CONFIG_ARM64_SW_TTBR0_PAN
This activates "Emulate Privileged Access Never using TTBR0_EL1
switching" on ARM64.

This should prevent the kernel from reading code from user space in
kernel context.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 years ago
Stijn Tintel 77e3e706ce kernel: add missing ARM64_SSBD symbol
In 4.14.57, a new symbol for Spectre v4 mitigation was introduced for
ARM64. Add this symbol to all ARM64 targets using kernel 4.14.

This mitigates CVE-2018-3639 on ARM64.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
6 years ago
Mathias Kresin cf7154db07 kernel: only optimized for size if small_flash
Add a new config option to allow to select the default compile
optimization level for the kernel.

Select the optimization for size by default if the small_flash feature is
set. Otherwise "Optimize for performance" is set.

Add the small_flash feature flag to all (sub)targets which had the
optimization for size in their default kernel config.

Remove CC_OPTIMIZE_FOR_* symbols from all kernel configs to apply the new
setting.

Exceptions to the above are:

  - lantiq, where the optimization for size is only required for the
    xway_legacy subtarget but was set for the whole target
  - mediatek, ramips/mt7620 & ramips/mt76x8 where boards should have
    plenty of space and an optimization for size doesn't make much sense
  - rb532, which has 128MByte flash

Signed-off-by: Mathias Kresin <dev@kresin.me>
6 years ago
Hauke Mehrtens da6c09eff4 kernel: move CONFIG_USB_MTU3 to generic config
CONFIG_USB_MTU3 is not visible for the mediatek target by default, but
only when CONFIG_USB_GADGET is set. This will config option will be
remove with when running "make kernel_oldconfig", move this option to
the generic config to prevent this.

This fixes the build of the mt7623 subtarget of the mediatek target.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years ago
Hauke Mehrtens 6745af9a0d mediatek: mt7622: Do not deactivate CONFIG_BLK_DEV
zram.ko needs CONFIG_BLK_DEV activated and it is by default for all
other targets in OpenWrt.

This makes zram.ko compile again.
Compile tested only.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years ago
Hauke Mehrtens 10ce015c65 mediatek: mt7622: Do not set CPU_SUBTYPE for Cortex A53
Neon and vfpv4 are mandatory extensions in the ARM64 instruction set
now, do not activate them explicitly. GCC will make use of these
extension now by default.

This makes it possible to share the toolchain with other Cortex A53
SoCs.
Compile tested only.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years ago
John Crispin 55f3731002 mediatek: add missing symbols for mt7622
Signed-off-by: John Crispin <john@phrozen.org>
6 years ago
John Crispin de6162e832 mediatek: add missing symbols
Signed-off-by: John Crispin <john@phrozen.org>
6 years ago
John Crispin 51740777fb mediatek: add mt7622 subtarget
Signed-off-by: John Crispin <john@phrozen.org>
6 years ago