Commit Graph

32 Commits (9b68fe961ba9a8c753dfc61d65d9d42bae578eca)

Author SHA1 Message Date
John Crispin 570c35a599 lantiq: add phy led config support over devicetree bindings
This patch adds the posibility to config the led behaviour of the lantiq phys
over the devicetree bindings.It patches the 0023-NET-PHY-adds-driver-for-lantiq-PHY11G
for 3.18 and 4.1. I have also added a register description overview for
applicable values. This goes to the documentation folder in the linux kernel.

Signed-off-by: Florian Eckert <Eckert.Florian@googlemail.com>

SVN-Revision: 47566
9 years ago
John Crispin 0206a400cf lantiq: tweak DWC2 default parameters
This patch improves the default configuration of DWC2 on lantiq SoCs
somewhat:
 * Set maximum packet count to largest allowed value by the DWC2 (511)
 * Use 16-bit DMA bursts
 * Divide fifo buffers more evenly

Default fifo buffer sizes from original ltq-hcd driver seem really
irrational. For example according to DWC2 data book rxfifo size of 240
will not fit even a single full length USB packet. On the other hand
non-periodic tx fifo size of 240 is more than enough to fit one complete
packet.

Change the sizes around to improve the situation and to fix some issues
especially with isochronous USB transfers.

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>

SVN-Revision: 47563
9 years ago
John Crispin b7e4c8d3bf lantiq: Print the status register whenever an error occurs
This should help finding potential problems with the SPI driver.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 47209
9 years ago
John Crispin 2c7d536780 lantiq: Fixed reading the number of RX FIFOs in the SPI driver
Until now the SPI driver used the TX bits for the RX FIFO. This seems
uncritical for now since both are equals on my devices (VR9), but this
could cause problems on other SoCs.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 47208
9 years ago
John Crispin f2f50ad762 lantiq: fix ath_pci_fixup hang on bridged devices
Port of r41856.

In contrast to the brcm63xx target, it isn't sufficient to enable/disable
the bridge. The device needs to be enabled/disabled to fix the hang. The
bridge will be automatically enabled by the time the connected device is
enabled.

Fixes boot on TD-W8980.

Signed-off-by: Mathias Kresin <openwrt@kresin.me>
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 47129
9 years ago
John Crispin 404b183aa8 lantiq: Add AR9 compatibility bits to DWC2 driver
Add AR9 DTS definition to be recognized by the DWC2 driver.

The same driver parameters can be mostly used except that some boards
seem to erroneously report OTG HNP/SRP capability of the USB HCD.
Forcing the HNP/SRP off allows these boards to work with the DWC2 as well.

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>

SVN-Revision: 46915
9 years ago
John Crispin 1f4124ceb0 lantiq: Initialize USB on AR9 platform
Based on the ltq-hcd driver the AR9 USB can be initialized the same way
as the VR9 platform. Use the same initialization bits for both
platforms.

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>

SVN-Revision: 46913
9 years ago
Felix Fietkau 6c1adb3eec lantiq: Use the BAR0 base address in the ath PCI fixup code
Fixes support for AR9287 on TP-Link TD-W8980 and possibly other devices
which have an ath wifi chip at a PCI address other than 0xb8000000
(TD-W8980 for example has it's wifi chip at 0xbc000000).

Signed-off-by: Geoffrey McRae <geoff@spacevs.com>
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 46869
9 years ago
Jonas Gorski 7d6cff4882 kernel: update 3.18 to 3.18.21
Changelog:
 * https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.21

Signed-off-by: Jonas Gorski <jogo@openwrt.org>

SVN-Revision: 46768
9 years ago
John Crispin 4582d7e8f5 lantiq: Support newer versions of the PEF7071 ethernet PHYs
The BT Home Hub 5A uses three PEF7071 with PHY ID 0xd565a401. Daniel's
PHY driver (for his u-boot sources) already supports that PHY because
it uses a PHY ID mask of 0xfffffff8.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 46670
9 years ago
Hauke Mehrtens 29039f51b3 kernel: refresh patches on linux 3.18
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 46308
9 years ago
John Crispin 2748df1c98 lantiq: Silence the printk when a PCIe error interrupt arrives
Basically the only error I am seeing is "Correctable Error". Also newer
lantiq PCIe drivers have this message wrapped in a "if debug enabled"
block. So it should be safe to disable this warning.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 46222
9 years ago
John Crispin fa9e259729 lantiq: Change the data-type of mac address in ETOP driver
Make it consistent with the net_device struct and the xrx200 driver

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 46219
9 years ago
Jonas Gorski 901a7fa067 kernel: update 3.18 to 3.18.17
Changelog:
* https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.17

Signed-off-by: Jonas Gorski <jogo@openwrt.org>

SVN-Revision: 46150
9 years ago
Jonas Gorski 9a59b350b7 kernel: update 3.18 to 3.18.16
Changelogs:

* https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.15
* https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.16

Signed-off-by: Jonas Gorski <jogo@openwrt.org>

SVN-Revision: 46011
9 years ago
John Crispin 262f6869a2 lantiq: Backport gpio-stp-xway to fix the highest bits of the PHY LEDs
This fixes the LAN2 LED on Arcadyan VGV7510KW22.

SVN-Revision: 45899
9 years ago
John Crispin 230efe318f lantiq: Fix initialization of the PCI IRQs when PCIe is also enabled
There are already ifx_pcie_bios_{map_irq,plat_dev_init} hooks defined in
ifxmips_pcie.c. Instead of defining a new hook we simply re-use the
existing ones (this is basically what the lantiq BSP code does).

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 45718
9 years ago
John Crispin 390924e662 lantiq: Fix PCIe bus when PCI is also enabled.
The PCIe bus seems to require a hack/workaround when PCI is enabled as
well. Unfortunately this is guarded by an CONFIG_IFX_PCI ifdef, which is
only defined in lantiq's BSP code. The config symbol for the upstream
lantiq PCI driver is CONFIG_PCI_LANTIQ.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 45717
9 years ago
Jonas Gorski 76d079204d kernel: update 3.18 to 3.18.14
Changelogs:

* https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.12
* https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.13
* https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.14

Build tested on brcm63xx and ipq806x, runtested on brcm63xx.

Signed-off-by: Jonas Gorski <jogo@openwrt.org>

SVN-Revision: 45711
9 years ago
Imre Kaloz f86c07d8d4 The ability to read MAC addresses from MTD is useful for other targets besides ramips and lantiq as well.
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>

SVN-Revision: 45596
9 years ago
Felix Fietkau d8d9282372 lantiq: add a better fix to strip FCS from ethernet packets on XRX200
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 44771
9 years ago
John Crispin da3fd5dbf9 kenrel: refresh patches
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 44678
9 years ago
John Crispin d5c250b91a lantiq: make the new dwc2 support only work for vr9
danube needs to be added

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 44677
9 years ago
John Crispin 72822d0192 lantiq: Use platform endianness when accessing dwc2 registers
This patch switches calls to readl/writel to their
dwc2_readl/dwc2_writel equivalents which preserve platform endianness.

This patch is necessary to access dwc2 registers correctly on big
endian systems such as the mips based SoCs made by Lantiq. Then dwc2
can be used to replace ifx-hcd driver for Lantiq platforms found e.g.
in OpenWrt.

The patch was autogenerated with the following commands:
$EDITOR core.h
sed -i "s/\<readl\>/dwc2_readl/g" *.c hcd.h hw.h
sed -i "s/\<writel\>/dwc2_writel/g" *.c hcd.h hw.h

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>
Signed-off-by: Vincent Pelletier <plr.vincent@gmail.com>

SVN-Revision: 44675
9 years ago
John Crispin d77c857509 lantiq: Add sensible hw-defaults for dwc2
Lantiq driver does not work with autodetected fifo sizes so use ones
from original ltq-hcd driver in dwc2. Other values can be
autodetected.

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>
Signed-off-by: Vincent Pelletier <plr.vincent@gmail.com>

SVN-Revision: 44674
9 years ago
John Crispin 2ddcf4c46e lantiq: Configure gpio power output pin when initializing dwc2 usb
Port gpio code from original ltq-hcd driver to dwc2.

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>
Signed-off-by: Vincent Pelletier <plr.vincent@gmail.com>

SVN-Revision: 44673
9 years ago
John Crispin a23da431dc lantiq: Add usb initialization bits from ltq-hcd to platform init
Add VR9 specific usb initialization bits from ltq-hcd to platform
initialization.

This patch is more of a proof-of-concept than production quality
since the initialization registers are different on other lantiq
platforms.

Signed-off-by: Antti Seppälä <a.seppala@gmail.com>
Signed-off-by: Vincent Pelletier <plr.vincent@gmail.com>

SVN-Revision: 44672
9 years ago
John Crispin e07c4f2150 lantiq: disable buffered writes on Intel command set flash
Some Lantiq SoCs are not able to use buffered writes properly with
Intel command set flash due to the way NOR addresses on EBU are
manipulated. This patch disables buffered writes on those devices.
The only device affected at the moment is ARV4510PW, others use
AMD/Fujitsu command set.

Signed-off-by: Matti Laakso <malaakso@elisanet.fi>

SVN-Revision: 44451
10 years ago
John Crispin a15dd8ec78 lantiq: Fix flash for targets with NO_XIP
For targets with NO_XIP ltq_mtd->map[i].phys equals -1 and devm_ioremap fails.
Fix this by using pdev->resource[i].start instead.

Signed-off-by: Matti Laakso <malaakso@elisanet.fi>

SVN-Revision: 44450
10 years ago
John Crispin dbfb21ee90 lantiq: make m25p80 work again
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 44421
10 years ago
John Crispin 1eb616764e lantiq: fix mac addr assignment inside lantiq_etop
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 44420
10 years ago
John Crispin 826b461427 lantiq: add 3.18 support
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 44348
10 years ago