summaryrefslogtreecommitdiffstats
path: root/target/linux/mediatek/files/drivers
Commit message (Collapse)AuthorAgeFilesLines
* mediatek: remove macros for previous kernel versionsDaniel Golle2024-05-031-13/+0
| | | | | | | | Remove unnecessary 'if' macros for previous kernel versions. After removing kernel 6.1 the kernel is always >= 6.6 so the conditions are unnecessary. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: mt7622: rtl8367c: source code spell fixesPaul Donald2024-04-124-7/+7
| | | | | | Improves indexing and searches Signed-off-by: Paul Donald <newtwen+github@gmail.com>
* mediatek: mt7622: rtl8367c: source comment fixesPaul Donald2024-04-121-1/+1
| | | | | | | | Fix also some Chinese -> UTF8 encoding problems Improves indexing and searches Signed-off-by: Paul Donald <newtwen+github@gmail.com>
* mediatek: mt7622: rtl8367c: source comment fixesPaul Donald2024-04-121-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | Fix also some Chinese GB18030 -> UTF-8 encoding problems (translated the Chinese strings to English): 修改 -> modification port8~port10的设置在另外一个register -> port8~port10 setup is done in a separate register You are in the correct (UTF-8) encoding when you see: * $Date: 2017-03-08 15:13:58 +0800 (週三, 08 三月 2017) $ e.g. week 3, 08 third month, 2017 But not if you see: * $Date: 2017-03-08 15:13:58 +0800 (閫变笁, 08 涓夋湀 2017) $ rtl8367c/rtl8367c_asicdrv_lut.c should be read as UTF-8, despite having some earlier Chinese text lost to GB18030 encoding. Improves indexing and searches Signed-off-by: Paul Donald <newtwen+github@gmail.com>
* mediatek: mt7622: rtl8367c: source comment fixesPaul Donald2024-04-121-4/+4
| | | | | | | | Fix also some Chinese -> UTF8 encoding problems Improves indexing and searches Signed-off-by: Paul Donald <newtwen+github@gmail.com>
* mediatek: mt7622: rtl8367c: source comment fixesPaul Donald2024-04-1255-338/+338
| | | | | | Improves indexing and searches Signed-off-by: Paul Donald <newtwen+github@gmail.com>
* mediatek: add Airoha EN8801SC PHY driverRobert Marko2024-04-112-0/+1367
| | | | | | | | | | | Airoha EN8801SC PHY is a gigabit PHY used on Edgecore EAP111 so, include the MTK driver with some cleanups. Unfortunatelly, there is no specification sheet nor datasheet available in order to demistify the magic PBUS writes and work on upstreaming this driver. Signed-off-by: Robert Marko <robert.marko@sartura.hr>
* mediatek: leds-smartrg-system: fix build on Linux 6.6Daniel Golle2024-03-111-0/+5
| | | | | | Adapt to changed function pointer prototypes. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: mt7622: rtl8367c: add casts to fix compiler warningsDaniel Golle2024-03-012-5/+5
| | | | | | | | | Use type casts to prevent compiler warnings which are going to turn into errors when we switch to Linux 6.6. In the long run we should try to get rid of this downstream driver now that RTL8367S is support by the rtl8365mb DSA driver. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: import driver for Adtran SmartRG RGBW LEDDaniel Golle2023-12-101-0/+239
| | | | | | | Import driver for I2C-connected HolTek MCU controlling the RGBW LED found in Adtran SmartRG devices. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: prepare old rtk switch driver for use with Linux 6.1Daniel Golle2023-07-071-9/+6
| | | | | | | | | | The old RealTek RTL8367S switch driver which is used for some MT7622 devices needs to be modified to no longer free the GPIO after reset has completed. This is due to Linux 5.19 removing devm_gpio_free via commit 2b038e786f83 ("gpiolib: devres: Get rid of unused devm_gpio_free()") Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* mediatek: remove mt753x driverFelix Fietkau2023-04-2916-3970/+0
| | | | | | It is unused Signed-off-by: Felix Fietkau <nbd@nbd.name>
* generic: move ledbar driver from mediatek targetSven Wegener2022-09-111-255/+0
| | | | | | This moves the ledbar driver to generic, to be also used by the ramips target. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: add led countSven Wegener2022-09-111-1/+7
| | | | | | | | | The LEDs connected to the MCU are so-called smart LEDs and their signal is daisy-chained. Because of this, the MCU needs to be told how many LEDs are connected. It also means the LEDs could be individually controlled, if the MCU has a command for this. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: add initialization after resetSven Wegener2022-09-111-0/+14
| | | | | | | | During GPIO initialization the pin state flips and triggers a reset of the ledbar MCU. It needs to be moved through an initialization sequence before working correctly. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: add support for reset gpioSven Wegener2022-09-111-0/+26
| | | | | | | Some versions of the ledbar MCU have a reset pin. It needs to be correctly initialized or we might keep the MCU in reset state. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: support reading more than one byte of responseSven Wegener2022-09-111-7/+8
| | | | | | There are commands that return more than one byte of response. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: cast literal value to charSven Wegener2022-09-111-1/+1
| | | | | | | | | | Or the comparison against a signed char is always true, because the literal 0xaa is treated as an unsigned int, to which the signed char is casted during comparison. 0xaa is above the positive values of a signed char and negative signed char values result in values larger than 0xaa when casted to unsigned int. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: correctly log i2c responseSven Wegener2022-09-111-2/+2
| | | | | | | The read response is in the i2c_response variable. Also use %hhx format, because we're dealing with a single char. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: remove gpiod_direction_output()Sven Wegener2022-09-111-2/+0
| | | | | | It's already set to output with GPIOD_OUT_LOW. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: do not use gpiod_set_raw_value()Sven Wegener2022-09-111-2/+2
| | | | | | The polarity of the signal is set in the device dts. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
* mediatek: drop spi-nand driver from mtkChuanhong Guo2022-04-2810-3979/+0
| | | | Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
* mediatek: add patches for 5.15 and kernel config for mt7622Felix Fietkau2022-03-27152-0/+102071
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* mediatek: bump to v4.14John Crispin2018-02-147-3870/+0
| | | | | | | This drops support for all the !emmc EVB and adds banannaPi-R2 Also drop mtkhnat until the nftables offoad driver is ready Signed-off-by: John Crispin <john@phrozen.org>
* mediatek: update to latest kernel patchset from v4.13-rcJohn Crispin2017-08-187-0/+3870
Signed-off-by: Muciri Gatimu <muciri@openmesh.com> Signed-off-by: Shashidhar Lakkavalli <shashidhar.lakkavalli@openmesh.com> Signed-off-by: John Crispin <john@phrozen.org>