Commit Graph

78 Commits

Author SHA1 Message Date
Aleksander Jan Bajkowski
069bda0adb
lantiq: add rgmii delays on BT Home Hub 5A
This comit fixes warnings that occur on kernel 5.15:
...
[    2.269736] Intel XWAY PHY11G (PEF 7071/PEF 7072) v1.5 / v1.6 1e108000.switch-mii:00:
               PHY has delays (e.g. via pin strapping), but phy-mode = 'rgmii'
[    2.269736] Should be 'rgmii-id' to use internal delays txskew:1500 ps rxskew:1500 ps
...

Ref: be393dd685
Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
2022-10-21 13:45:37 +02:00
Martin Blumenstingl
2683cca592 lantiq: dts: vr9: Add missing properties to the CPU port on the switch
The CPU port should define the phy-mode and and a PHY phandle or
fixed-link to indicate how the CPU port is connected to the SoC's
Ethernet controller. On xRX200 this is all internal connection, so use
phy-mode = "internal" along with a fixed-link that matches the
definition inside &eth0.

Linux 6.0 shows a warning since upstream commit e09e9873152e3f ("net:
dsa: make phylink-related OF properties mandatory on DSA and CPU
ports"). when these properties are missing. Adding the properties
before OpenWrt is updated to Linux 6.0 is harmless.

Suggested-by: Martin Schiller <ms@dev.tdt.de>
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2022-10-10 21:51:05 +02:00
Daniel Kestrel
8756a04787 lantiq: fix lan port 3+4 phy-mode settings for Fritzbox 3390
There are forum reports that 2 LAN ports are still not working,
the phy-mode settings are adjusted to fix the problem.

Fixes: #10371
Signed-off-by: Daniel Kestrel <kestrel1974@t-online.de>
2022-08-05 14:10:42 +02:00
Daniel Kestrel
0f301b0b1d lantiq: fix network port GPIO settings for Fritzbox 3390
There are forum reports that 2 LAN ports are not working, the
GPIO settings are adjusted to fix the problem.

Signed-off-by: Daniel Kestrel <kestrel1974@t-online.de>
2022-07-22 22:05:23 +02:00
Martin Blumenstingl
9d06e5a773 lantiq: dts: td-w8980: Remove duplicate PCI properties
lantiq,bus-clock, interrupt-map-mask and interrupt-map are already
defined with these exact values in vr9.dtsi. Drop them from
vr9_tplink_tdw8980.dts to just have one place where these are
maintained.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2022-06-27 00:57:16 +02:00
Martin Blumenstingl
a1354accc0 lantiq: dts: fix reset controller reference on Danube and AR9
ar9.dtsi and danube.dtsi only have one reset controller and they are
naming it "reset". This is equivalent to "reset0" in vr9.dtsi. Fix the
references to the reset controller in the recently added PCI controller
reset line.

Fixes: 087f2cba26 ("lantiq: dts: Add the reset line for the PCI controller")
Reported-by: Christian Lamparter <chunkeey@gmail.com>
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2022-06-20 19:43:33 +02:00
Martin Blumenstingl
087f2cba26 lantiq: dts: Add the reset line for the PCI controller
The PCI controller has it's reset line wired up to bit 13 of RCU.
Describe this in our .dtsi files.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2022-06-19 12:31:02 +02:00
Martin Blumenstingl
56cd49bdc8 lantiq: fritz736x: Move GPIO resets to the inidvidual board.dts files
FRITZ!Box 7360 V2 and FRITZ!Box 7360 SL both use GPIOs 37 (for &phy0)
and GPIO 44 (for &phy1) to control the PHY's reset lines. FRITZ!Box 7362
SL however uses GPIO 45 (for &phy0) and GPIO 44 (for &phy1). Move the
GPIO reset definitions to each individual board .dts and while at it,
fix the GPIOs for the FRITZ!Box 7362 SL.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2022-04-16 14:02:11 +02:00
Jan Hoffmann
a622273876 lantiq: fritz7362sl: add partition subnode for SPI flash
Without a partition subnode ofpart_core still parses direct subnodes as
partitions, but it ignores nodes with a compatible property. Due to
this, the switch to nvmem-cells made the urlader partition inaccessible.
As a result, the wireless network was broken, as the calibration data
is read from that partition by a script.

Fixes: #8983
Signed-off-by: Jan Hoffmann <jan@3e8.eu>
2022-03-16 20:48:01 +01:00
Martin Blumenstingl
dadedd5580 lantiq: fritz7362sl: fix SPI flash node reg property
The &spi node has #address-cells = <1> and #size-cells = <0>. Drop the
extra 0 in the reg property from the SPI flash node to ensure it's
number of cells matches the definition in the parent node. This also
makes the reg property for the SPI flash node consistent with all other
VR9 boards.

Fixes: eae6cac6a3 ("lantiq: add support for AVM FRITZ!Box 7362 SL")
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2022-03-16 20:48:01 +01:00
David Bauer
3154537864 lantiq: flag FritzBox 7360 family buttons active-low
All buttons of the FritzBox 7360 family are active-low, not active-high.
Corrent the GPIO flag. This fixes release triggers upon push of a button.

Reported-by: Jan-Niklas Burfeind <git@aiyionpri.me>
Signed-off-by: David Bauer <mail@david-bauer.net>
2022-01-14 22:12:53 +01:00
Aleksander Jan Bajkowski
46468fc9d5 lantiq: replace patches with version accepted upstream
Replace recently added patches with version accepted upstream.

Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
2022-01-08 19:32:45 +01:00
Mathias Kresin
9764968bba lantiq: ar7: use okli loader for FRITZ!Box
With Kernel 5.10 the ar7 FRITZ!Box are not booting the initramfs nor the
sysupgrade image any more. Presumably due to the grown kernel.

Use the okli preloader to workaround the bootloader issue. No solution
so far for the initramfs.

Signed-off-by: Mathias Kresin <dev@kresin.me>
2021-11-27 21:40:12 +01:00
Aleksander Jan Bajkowski
0e561a2aea lantiq: improve ethernet performance
This commit contains a series of fixes for DMA. The burst length
patch significantly improves Ethernet performance. Patches were
tested on the xRX200 and xRX330.

Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
2021-11-15 23:17:32 +01:00
Mathias Kresin
683e9cf7d0 lantiq: fix mac address from nvmem-cells
The devicetree property mac-address is expected to be set by the
bootloader and has priority over the nvmem supplied one.

Drop the mac-address address property from the dtsi files, to let the
mac address from nvmem-cells get used.

Signed-off-by: Mathias Kresin <dev@kresin.me>
2021-11-14 20:18:17 +01:00
Christian Lamparter
4c8dd973ef ath9k: OF: qca,disable-(2|5)ghz => ieee80211-freq-limit
OpenWrt maintains two special out-of-tree DT properties:
"qca,disable-5ghz" and "qca,disable-2ghz". These are implemented
in a mac80211 ath9k patch "550-ath9k-disable-bands-via-dt.patch".

With the things being what they are, now might be a good
point to switch the devices to the generic and upstream
"ieee80211-freq-limit" property. This property is much
broader and works differently. Instead of disabling the
drivers logic which would add the affected band and
channels. It now disables all channels which are not
within the specified frequency range.

Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Tested-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> # HH5A
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2021-10-30 16:32:59 +02:00
Daniel Kestrel
ca1874437c lantiq: kernel: xway-nand: Move ECC engine setting to new DT binding
When trying to add support for another device with Micron NAND chips,
it was discovered that the default setting in the kernel source does
not work with Micron Chips, since the device trees setting is
overwritten and hard coded by the kernel xway_nand driver. This was
the original reason for this PR.
A kernel patch sets the default ECC mode to soft without overwriting
the device tree settings and the device tree for devices using it
are updated with new parameters because the old ones are deprecated
by torvalds/linux@533af69.
A patch for kernel 5.4 is provided to support the new settings
because kernel 5.4 does not support it.

Signed-off-by: Daniel Kestrel <kestrel1974@t-online.de>
2021-10-02 16:45:33 +02:00
Adrian Schmutzler
adb3e46616 lantiq: convert mtd-mac-address to nvmem for Fritz!Box 736x
Convert this series by moving the definitions to the individual
devices.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-08-20 18:13:55 +02:00
Ansuel Smith
939c0030db lantiq: convert mtd-mac-address to nvmem implementation
Define nvmem-cells and convert mtd-mac-address to nvmem implementation.
The conversion is done with an automated script.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2021-07-19 14:51:22 +02:00
Ansuel Smith
d284e6ef0f treewide: convert mtd-mac-address-increment* to generic implementation
Rework patch 681-NET-add-mtd-mac-address-support to implement
only the function to read the mac-address from mtd.
Generalize mtd-mac-address-increment function so it can be applied
to any source of of_get_mac_address.
Rename any mtd-mac-address-increment to mac-address-increment.
Rename any mtd-mac-address-increment-byte to mac-address-increment-byte.

This should make simplify the conversion of target to nvmem implementation.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2021-07-19 14:51:22 +02:00
Martin Blumenstingl
b1df48caac lantiq: xrx200: switch the subtarget to the mainline DSA driver
Enable the XRX200 PMAC, GSWIP DSA tag and GSIP DSA drivers in the 5.4
kernel config. Update the existing vr9_*.dts{,i} to use the new
Ethernet and switch drivers. Drop the swconfig package from the xrx200
target because swconfig doesn't manage DSA based switches.

The new /etc/config/network format for the DSA driver is not compatible
with the old (swconfig) based one. Show a message during sysupgrade
notifying users about this change and asking them to start with a fresh
config (or forcefully update and then migrate the config manually).

Failsafe mode can now automatically bring up the first lan interface
based on board.json including DSA based setups. Drop
05_set_preinit_iface_lantiq from the xRX200 sub-target as this is not
needed anymore. For now we are keeping it for the ase, xway and
xway_legacy until there's some confirmation that it can be dropped from
there as well.

While here, some boards also receive minor fixups:
- Use LAN1 as LAN1 (according to a photo this port can also be
  configured as WAN) on the Buffalo WBMR-300HPD. This makes it easier to
  read the port mapping because otherwise we would have LAN{2,3,4} and
  WAN (which was the case for the non-DSA version previously).
- vr9_avm_fritz3390.dts: move the "gpio" comment from port 0 and 1 to
  their corresponding PHYs
- vr9_tplink_vr200.dtsi: move the "gpio" comment from port 0 to PHY 0
- vr9_tplink_tdw89x0.dtsi: move the "gpio" comment from port 0 to PHY 0

Acked-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
Tested-by: Notupus <notpp46@googlemail.com> # TD-W9980/DM200/FRITZ 7430
Tested-by: Martin Schiller <ms@dev.tdt.de> # tested on TDT VR2020
Tested-by: Martin Schiller <ms@dev.tdt.de> # tested on TP-Link TD-W8980B
Tested-by: Martin Schiller <ms@dev.tdt.de> # tested on ZyXEL P-2812HNU-F1
Tested-by: Daniel Kestrel <kestrel1974@t-online.de> # tested on Fritzbox 7490
Tested-by: Daniel Kestrel <kestrel1974@t-online.de> # tested on Fritzbox 3490
Tested-by: @jospezial <jospezial@gmx.de> # tested on VGV7510KW22 (o2 Box 6431)
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2021-06-26 16:05:36 +02:00
Mathias Kresin
276c85825c lantiq: dts: mark PCI bridges as such
Use the device_type property to mark PCI host bridges as such. With
linux 5.10 it is mandatory, otherwise the PCI IO space is flages as PCI
memory and the PCI init fails.

Signed-off-by: Mathias Kresin <dev@kresin.me>
2021-04-12 23:23:09 +02:00
Andreas Böhler
73ec21cde2 lantiq: add basic support for AVM FRITZ!Box 3390
The FRITZ!Box 3390 actually contains two SoCs, one Lantiq with a
5GHz WiFi and one AR9342 with a 2.4GHz WiFi. Only the Lantiq
has access to the flash memory, the Atheros runs fully from RAM.

Specifications
--------------

  - Lantiq 500 MHz
  - 128MiB RAM
  - 128MiB NAND
  - 256k Flash
  - AR9580 5GHz WiFi
  - AR9342 560 MHz
  - 64MiB RAM
  - AR9328 2.4GHz WiFi

Remarks
-------

This commit only adds support for the Lantiq side of things and
prepares the drivers for communication with the Atheros SoC. Thus,
only 5GHz WiFi works by default, the 2.4GHz WiFi will be added via
another target.

Some kernel patches will be required to add support for the Atheros SoC.

Installation
------------

Use the eva_ramboot.py script to boot the initramfs image. Then, transfer
the sysupgrade image to the device and run sysupgrade to flash it to the
NAND.

Signed-off-by: Andreas Böhler <dev@aboehler.at>
Acked-by: Aleksander Jan Bajkowski A.Bajkowski@stud.elka.pw.edu.pl
Signed-off-by: Joachim Cerny <cocktail_yogi@web.de>
2021-04-03 18:56:51 +02:00
Joachim Cerny
754eb75a8c lantiq: VR9: fix gpio-hog by defining the GPIO ranges
defined gpio-ranges according to Reference: https://github.com/torvalds/linux/blob/master/drivers/pinctrl/pinctrl-xway.c#L864
This change is needed by gpio-hog on Fritzbox 3390
thx to @abajk

Acked-by: Aleksander Jan Bajkowski A.Bajkowski@stud.elka.pw.edu.pl
Signed-off-by: Andreas Böhler <dev@aboehler.at>
Signed-off-by: Joachim Cerny <cocktail_yogi@web.de>
2021-04-03 18:56:02 +02:00
Mathias Kresin
5662f5b114 lantiq: vr9: set the usb led trigger via devicetree
Assign the usbdev trigger via devicetree and drop the userspace
handling of the usb leds.

Drop the now unused userspace helper code as well.

Signed-off-by: Mathias Kresin <dev@kresin.me>
Acked-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-03-01 00:19:58 +01:00
Mathias Kresin
7995a93744 lantiq: ARV752DPW22: set the usb led trigger via devicetree
Assign the usbdev trigger via devicetree and drop the userspace
handling of the usb leds

Add the PCI attached usb controller as trigger sources for the usb led
as well.

Signed-off-by: Mathias Kresin <dev@kresin.me>
2021-03-01 00:19:58 +01:00
Mathias Kresin
ba07cc0cbb lantiq: fritz7320: enable USB power supply
The USB ports if a FRIZZ!Box 7320 do not supply power to connected
devices.

Add the GPIOs enabling USB power as regulator, to enable USB power
supply as soon as the USB driver is loaded.

Fixes FS#3624

Signed-off-by: Mathias Kresin <dev@kresin.me>
2021-02-18 08:43:08 +01:00
Aleksander Jan Bajkowski
c9619fe6a5 lantiq: change phy-mode to mii for FRITZ!Box 7412
FRITZ!Box 7412 loads the firmware for fast ethernet PHY and mii is
more accurate in this case.
Gmii is used by Gigabit ethernet PHYs.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
Reviewed-by: Mathias Kresin <dev@kresin.me>
[minor commit title/message adjustments]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-02-05 18:56:19 +01:00
Aleksander Jan Bajkowski
5c1f6853af lantiq: xrx200: remove redundant stp parameters
These parameters are the same as in vr9.dtsi. This patch removes
redundant parameters.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
2020-12-19 19:42:00 +01:00
Aleksander Jan Bajkowski
0f43961eef lantiq: xrx200: remove unused lan/wan labels from dts
These labels are not used anywhere and can be removed.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
2020-12-14 18:02:51 +01:00
Leon Maurice Adam
6c85a449a9 lantiq: add support for AVM FRITZ!Box 7430
Hardware:
- SoC: Lantiq VRX 220
- CPU: 2x MIPS 34Kc 500 MHz
- RAM: 128 MiB 250 MHz
- Flash: 128 MiB NAND
- Ethernet: Built-in Fast Ethernet switch, 4 ports used
- Wifi: Atheros AR9381-AL1A b/g/n with 2 pcb/internal and 1 external antennas
- USB: 1x USB 2.0
- DSL: Built-in A/VDSL2 modem
- DECT: Dialog SC14441
- LEDs: 1 two-color, 4 one-color
- Buttons: 1x DECT, 1x WIFI
- Telephone connectors: 1 FXS port via TAE or RJ11 connector

With the exception of FXS/DECT everything works
(there are no drivers for AVM's FXS or DECT implementation),
DSL is yet untested.

Installation:
Boot up the device and wait a few seconds. Run the eva_ramboot.py script
in scripts/flashing/ to load the initramfs image on the device:
$ ./scripts/flashing/eva_ramboot.py 192.168.178.1 <path to your initramfs image>
If the script fails to reach the device, maybe try 169.254.120.1.

Wait until booting is complete. You should now be able to reach your device
under the default ip address 192.168.1.1.

Before flashing, check if linux_fs_start is not set to 1 in the tffs partition:
$ fritz_tffs_nand -d /dev/mtd1 -n linux_fs_start
If linux_fs_start is 1, you will need to reset it to 0, either by FTP,
upgrading FritzOS or doing a recovery.

Now you should be able to flash the device using sysupgrade.

Signed-off-by: Leon Maurice Adam <leon.adam@aol.de>
Acked-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
[drop BOARD_NAME, use wpad-basic-wolfssl, drop 4.19, drop dts-v1,
remove model prefix from LED names]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-10-27 13:40:09 +01:00
Adrian Schmutzler
c19c15f330 lantiq: fix indent in vr9_avm_fritz7412.dts
Indent should be tabs.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-10-27 13:33:21 +01:00
Adrian Schmutzler
21cf17bb4c lantiq: remove support for kernel 4.19
The target uses 5.4 as default kernel since 06/2020.

Kernel 4.19 support is not really maintained anymore, it does not
seem to be needed and upcoming changes (mainly DSA) will break
backward-compatibility anyway.

Thus, make maintaining of old stuff and reviewing of new stuff
easier by removing support for kernel 4.19.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-10-19 15:57:40 +02:00
Mathias Kresin
005dedd348 lantiq: copy target to kernel 5.4
Duplicate kernel 4.19 config and patches for kernel 5.4.

Duplicate the devicetree source files as well, they need kernel 5.4
specific adjustments.

Signed-off-by: Mathias Kresin <dev@kresin.me>
2020-03-16 22:28:16 +01:00
Mathias Kresin
0270b1995b lantiq: vgv7510kw22: fix missing wireless
For some reason pin 7 (gphy0_led1_pins) need to be set to output prior
to loading the PCI driver. Otherwise the wireless doesn't appear on the
PCI bus. Of course, it doesn't make much sense, since pin 7 is used to
drive the LAN1 led.

It can either be done by setting the pins function to GPHY or GPIO +
direction output. However, the pinctrl driver doesn't provide a way to
switch a pin to GPIO. It is done indirectly by the pinctrl driver at the
time a GPIO is requested (requesting a GPIO always resets the function
to GPIO).

Do it via pinmux driver, as it is always loaded first. Use the GPHY
function as it's the pins intended purpose for this board.

Fixes: FS#2895

Signed-off-by: Mathias Kresin <dev@kresin.me>
2020-03-16 22:28:16 +01:00
Mathias Kresin
f2d976f06e lantiq: move mux for pins into subnodes
The mux need to be defined in a subnode to be considered by the pinctrl
framework. These muxes aren't set as expected and might cause not
working subsystems.

Fixes: 8e7b573b7a ("lantiq: dts: assign the PCI pins to the PCI controller node")
Fixes: dcb5e52209 ("lantiq: dts: assign the STP pins to the STP GPIO controller node")
Fixes: 660200e53d ("lantiq: dts: assign the GPHY LED pins to the Ethernet controller node")
Signed-off-by: Mathias Kresin <dev@kresin.me>
2020-03-15 21:38:05 +01:00
Kevin Schmidt
77e27e0f53 lantiq: enable 5ghz wifi on VR200/VR200v
Enable mt76 driver on VR200/VR200v.

Signed-off-by: Kevin Schmidt <kevin.patrick.schmidt@googlemail.com>
2019-12-23 00:04:18 +01:00
Adrian Schmutzler
e2eb6d5829 lantiq: move include to parent falcon_lantiq_easy98000.dtsi
This moves the include of lantiq.dtsi from the DTS files to the
parent falcon_lantiq_easy98000.dtsi.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2019-12-22 01:24:23 +01:00
Adrian Schmutzler
397aa5d37d lantiq: remove ar9_lantiq_easy50810.dts
This file seems to be orphaned, no device setup existing for it.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2019-12-22 01:24:23 +01:00
Adrian Schmutzler
c640370939 lantiq: use soc_vendor_device scheme on DTS file
This renames lantiq DTS(I) files to follow soc_vendor_device scheme.
This will make DTS files easier to maintain.

As a side effect, DTS file name can be derived from device node
names now, only having to specify a SOC variable in Makefiles.

While at it, move files to arch/mips/boot/dts/lantiq subfolder.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
4c88b3b5dc lantiq: dts: assign the ASC pins to the serial controller node
Assign the ASC pins to the serial controller node instead of using pin
hogging (where pins are assigned to the pin controller).
This is the preferred way of assigning pins upstream.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
8e7b573b7a lantiq: dts: assign the PCI pins to the PCI controller node
Assign the PCI pins to the PCI controller node instead of using pin
hogging (where pins are assigned to the pin controller).
This is the preferred way of assigning pins upstream.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
dcb5e52209 lantiq: dts: assign the STP pins to the STP GPIO controller node
Assign the STP pins to the STP GPIO controller node instead of using
pin hogging (where pins are assigned to the pin controller).
This is the preferred way of assigning pins upstream.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
660200e53d lantiq: dts: assign the GPHY LED pins to the Ethernet controller node
Assign the GPHY LED pins to the Ethernet controller node instead of
using pin hogging (where pins are assigned to the pin controller).
This is the preferred way of assigning pins upstream.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
7298c25f74 lantiq: dts: assign the NAND pins to the nand-controller node
Assign the NAND pins to the NAND controller node instead of using pin
hogging (where pins are assigned to the pin controller).
This is the preferred way of assigning pins upstream.

While here, define all NAND pins (CLE, ALE, read/RD, ready busy/RDY and
CE/CS1). This means that the pinctrl subsystem knows that these pins are
in use and cannot be re-assigned as GPIOs for example.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
edb0a936f0 lantiq: dts: define the SPI pins in {amazonse,ar9,vr9}.dtsi
Define the SPI pins in the corresponding SoCs.dtsi and assign them to
the SPI controller node. All known boards use CS4 and it's likely that
this is hardcoded in bootrom so this doesn't bother with having
per-board SPI pinmux settings.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Martin Blumenstingl
b3bdfd5df5 lantiq: dts: assign the MDIO pins to the gsw node
Assign the MDIO pins to the switch node instead of using pin hogging
(where pins are assigned to the pin controller).
This is the preferred way of assigning pins upstream.

This converts amazonse, ar9 and vr9. danube is skipped because the pin
controller doesn't define a pinmux for the MDIO pins (some of the SoC
pads may be hardwired to the MDIO pins instead of being configurable).

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
2019-12-22 01:24:23 +01:00
Adrian Schmutzler
231dc26867 treewide: remove dts-v1 identifier from DTSI files
The "/dts-v1/;" identifier is supposed to be put once at the beginning
of a device tree file. Thus, it makes no sense to provide it a second
time in to-be-included DTSI files.

This removes the identifier from all DTSI files in /target/linux.

Most of the DTS files in OpenWrt do contain the "/dts-v1/;". It is
missing for most of the following targets, though:
mvebu, ipq806x, mpc85xx, ipq40xx

This does not touch ipq806x for now, as the bump to 4.19 is close.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2019-12-08 16:44:06 +01:00
David Bauer
3032bf7f89 lantiq: unify Fritz!Box LED mappings
This commit unifies the LED mapping of the AVM Fritz!Box routers, which
have a combined Power/DSL LED.

With the stock firmware, the Power LED has the following
characteristics:

 - Blink when DSL sync is being established
 - Solid when DSL sync is present

We can't completely resemble this behavior in OpenWrt. Currently, the
Power LED is completely off, when DSL sync is missing. This is not
really helpful, as a user might have the impression, that he bricked his
device.

Instead, map the Info-LED to the state of the DSL connection.
There is no consistent behavior for the Info-LED in the stock
firmware, as the user can set it's function by himself. The DSL
connection state is one possible option for the Info LED there.

Also use the red Power LED to indicate a running upgrade, in case the
board has a two-color Power LED.

Signed-off-by: David Bauer <mail@david-bauer.net>
2019-08-15 14:25:51 +02:00
David Bauer
920abb9b58 lantiq: add led-upgrade alias for Fritz!Box 7412
This adds the led-upgrade alias for the AVM Fritz!Box 7412 to indicate a
running firmware upgrade.

Signed-off-by: David Bauer <mail@david-bauer.net>
2019-08-10 16:16:23 +02:00