• John Crispin's avatar
    net-next: mediatek: add support for MT7623 ethernet · 656e7052
    John Crispin authored
    Add ethernet support for MediaTek SoCs from the MT7623 family. These have
    dual GMAC. Depending on the exact version, there might be a built-in
    Gigabit switch (MT7530). The core does not have the typical DMA ring setup.
    Instead there is a linked list that we add descriptors to. There is only
    one linked list that both MACs use together. There is a special field
    inside the TX descriptors called the VQID. This allows us to assign packets
    to different internal queues. By using a separate id for each MAC we are
    able to get deterministic results for BQL. Additionally we need to
    provide the core with a block of scratch memory that is the same size as
    the RX ring and data buffer. This is really needed to make the HW datapath
    work. Although the driver does not support this yet, we still need to
    assign the memory and tell the core about it for RX to work.
    Signed-off-by: default avatarFelix Fietkau <nbd@openwrt.org>
    Signed-off-by: default avatarMichael Lee <igvtee@gmail.com>
    Signed-off-by: default avatarJohn Crispin <blogic@openwrt.org>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    656e7052
mtk_eth_soc.h 12.3 KB