aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/realtek/files-5.4/drivers/net
Commit message (Collapse)AuthorAgeFilesLines
* realtek: Fix buffer length calculation on RTL8380 with CRC offloadBirger Koblitz2021-06-221-9/+7
| | | | | | | | | | | | | Fixes the buffer and packet length calculations for Ethernet TX on the RTL8380 SoC when CRC calculation offload is enabled. CRC-offload is always done by the SoC, but additional CRC calculation was previously done also by the kernel. It also fixes detection of the DSA tag for packets on RTL8390 SoCs for ports > 28. v2 has correct whitespace Signed-off-by: Birger Koblitz <mail@birger-koblitz.de>
* realtek: Fix VLAN issues introduced by multicast patchesBirger Koblitz2021-05-093-5/+5
| | | | | | | | | | This adds the CPU port to the unknown multicast flooding port mask, which fixes the VLAN issues introduced by the multicast group patches Tested-by: Russell Senior <russell@personaltelco.net> [Netgear GS108Tv3] Signed-off-by: Birger Koblitz <mail@birger-koblitz.de> Signed-off-by: Bjørn Mork <bjorn@mork.no> [whitespace fix] Signed-off-by: Petr Štetiar <ynezz@true.cz> [unknwon typo fix]
* realtek: Add support for Layer 2 MulticastBirger Koblitz2021-05-075-300/+1024
| | | | | | | | | | Adds support for Layer 2 multicast by implementing the DSA port_mdb_* callbacks. The Kernel bridge listens to IGMP/MLD messages trapped to the CPU-port, and calls the Multicast Forwarding Database updates. The updates manage the L2 forwarding entries and the multicast port-maps. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Setup all VLANs with default configurationsBirger Koblitz2021-05-075-0/+75
| | | | | | | | This sets up all VLANs with a default configuration on reset: - forward based on VLAN-ID and not the FID/MSTI - forward based on the inner VLAN-ID (not outer) Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add SoC-specific VLAN setup routineBirger Koblitz2021-05-074-114/+259
| | | | | | | | This adds SoC specific VLAN configuration routines, which alsoe sets up the portmask table entries that are referred to in the vlan profiles registers for unknown multicast flooding. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add support for clause45 PHYsBirger Koblitz2021-05-075-233/+541
| | | | | | | | This adds support for the MMD access registers the RTL-SoCs use to access clause 45 PHYs via mdio. This new interface is used to add EEE-support for the RTL8226 Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: improve EEE support for RTL8380/8390/9300Birger Koblitz2021-05-075-33/+301
| | | | | | | Clean up and fix bugs in the EEE support for RTL8380/90 Adds EEE support for RTL9300 Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add L2 hash bucket sizeBirger Koblitz2021-05-072-3/+5
| | | | | | | | Adds a hash-bucket size attribute for the different SoCs, in order to accomodate the buckets with 8 entries of the L2-forwarding tables on RTL93XX in contrast to only 4 on RTL83XX. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: remove unused FDB print routingBirger Koblitz2021-05-071-21/+0
| | | | | | remove fdb_dump debugging function Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: add IGMP/MLD snooping supportBirger Koblitz2021-05-072-4/+7
| | | | | | | This adds snooping support for IGMP and MLD on RTL8380/90/9300 by trapping IGMP and MLD packets to the CPU. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: enable CRC offloadingBirger Koblitz2021-05-071-24/+93
| | | | | | | | | | Enables CRC calculation offloading on RTL8380/8390/9300. Tested on Zyxel XGS1210-10 (RTL9302)/GS1900-48 (RTL8390)/GS1900-10HP (RTL8382) On the Zyxel GS1900-10HP, an increase of 5% in iperf3 send throughput and 11% in receive throughput is seen. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: enable SerDes NWAY and SGMII negotiationBjørn Mork2021-03-172-3/+42
| | | | | | | This allows copper SFPs to negotiate speeds lower than 1gig. Acked-by: Birger Koblitz <mail@birger-koblitz.de> Signed-off-by: Bjørn Mork <bjorn@mork.no>
* realtek: need to handle PHY_INTERFACE_MODE_NA for sfpsBjørn Mork2021-03-171-0/+1
| | | | | | | | | | From the validate docs in include/linux/phylink.h: When state->interface is PHY_INTERFACE_MODE_NA, phylink expects the MAC driver to return all supported link modes. Tested-by: Birger Koblitz <mail@birger-koblitz.de> Signed-off-by: Bjørn Mork <bjorn@mork.no>
* realtek: fix link-state interruptBjørn Mork2021-03-171-4/+3
| | | | | | | This bug was the root cause for the failing sfp driver. Acked-by: Birger Koblitz <mail@birger-koblitz.de> Signed-off-by: Bjørn Mork <bjorn@mork.no>
* realtek: drop ethtool log noiseBjørn Mork2021-03-122-15/+15
| | | | | | | | | | | | | Demote a number of debugging printk's to pr_debug to avoid log nosie. Several of these functions are called as a result of userspace activity. This can cause a lot of log noise when userspace does periodic polling. Most of this could probably be removed completely, but let's keep it for now since these drivers are still in development. Signed-off-by: Bjørn Mork <bjorn@mork.no> Tested-by: Stijn Tintel <stijn@linux-ipv6.be>
* realtek: add debugfs support for mirroringBirger Koblitz2021-01-261-14/+391
| | | | | | This adds debugfs support to monitor mirroring via debugfs Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: add API for the hw tables of RTL83XX/93XX SoCsBirger Koblitz2021-01-261-100/+436
| | | | | | | | Add a table API that has per accss register locking and uses register description information to handle all table access through a single set of api calls. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: add switch driver support for the RTL93XX based switchesBirger Koblitz2021-01-265-245/+1522
| | | | | | | Adds support for the RTL9300 and RTL9310 series of switches with 10GBit per port and up to 56 ports. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: add internal and external SDS/PHYs of RTL9300 devicesBirger Koblitz2021-01-262-28/+523
| | | | | | | | This adds support for the internal SerDes of the RTL9300 SoC and for the RTL8218D and RTL8226B phys found in combination with this SoC in switches. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: enable default rate limiting and qos settingsBirger Koblitz2021-01-261-64/+0
| | | | | | | Enable default rate limiting and QoS support. Remove previous storm control code. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: add QoS and rate controlBirger Koblitz2021-01-266-530/+1955
| | | | | | | | | This adds support for identifying QoS information in packets and use this and rate control information to submit to multiple egress queues. The ethernet driver is also made to support 2 egress and up to 32 egress queues. Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
* realtek: Add missing case in switch statementRafał Mikrut2020-12-111-0/+1
| | | | | | | | | | | | Cppcheck shows here duplicated break. Code `state->speed = SPEED_1000;` will be never executed because above it there is break statement. Almost identical statement is placed in another realtek driver https://github.com/openwrt/openwrt/blob/18a53d43d646290053eff4736ec852efcf6bf510/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c#L286-L294 Signed-off-by: Rafał Mikrut <mikrutrafal@protonmail.com>
* realtek: update the tree to the latest refactored versionJohn Crispin2020-11-2614-0/+6340
* rename the target to realtek * add refactored DSA driver * add latest gpio driver * lots of arch cleanups * new irq driver * additional boards Signed-off-by: Bert Vermeulen <bert@biot.com> Signed-off-by: Birger Koblitz <mail@birger-koblitz.de> Signed-off-by: Sander Vanheule <sander@svanheule.net> Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: John Crispin <john@phrozen.org>