Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ravb: Add support for RZ/V2M

RZ/V2M Ethernet is very similar to R-Car Gen3 Ethernet-AVB, though
some small parts are the same as R-Car Gen2.
Other differences to R-Car Gen3 and Gen2 are:
* It has separate data (DI), error (Line 1) and management (Line 2) irqs
rather than one irq for all three.
* Instead of using the High-speed peripheral bus clock for gPTP, it has a
separate gPTP reference clock.

Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com>
Reviewed-by: Biju Das <biju.das.jz@bp.renesas.com>
Reviewed-by: Sergey Shtylyov <s.shtylyov@omp.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Phil Edworthy and committed by
David S. Miller
e1154be7 72069a7b

+26
+26
drivers/net/ethernet/renesas/ravb_main.c
··· 2460 2460 .magic_pkt = 1, 2461 2461 }; 2462 2462 2463 + static const struct ravb_hw_info ravb_rzv2m_hw_info = { 2464 + .rx_ring_free = ravb_rx_ring_free_rcar, 2465 + .rx_ring_format = ravb_rx_ring_format_rcar, 2466 + .alloc_rx_desc = ravb_alloc_rx_desc_rcar, 2467 + .receive = ravb_rx_rcar, 2468 + .set_rate = ravb_set_rate_rcar, 2469 + .set_feature = ravb_set_features_rcar, 2470 + .dmac_init = ravb_dmac_init_rcar, 2471 + .emac_init = ravb_emac_init_rcar, 2472 + .gstrings_stats = ravb_gstrings_stats, 2473 + .gstrings_size = sizeof(ravb_gstrings_stats), 2474 + .net_hw_features = NETIF_F_RXCSUM, 2475 + .net_features = NETIF_F_RXCSUM, 2476 + .stats_len = ARRAY_SIZE(ravb_gstrings_stats), 2477 + .max_rx_len = RX_BUF_SZ + RAVB_ALIGN - 1, 2478 + .tccr_mask = TCCR_TSRQ0 | TCCR_TSRQ1 | TCCR_TSRQ2 | TCCR_TSRQ3, 2479 + .rx_max_buf_size = SZ_2K, 2480 + .multi_irqs = 1, 2481 + .err_mgmt_irqs = 1, 2482 + .gptp = 1, 2483 + .gptp_ref_clk = 1, 2484 + .nc_queues = 1, 2485 + .magic_pkt = 1, 2486 + }; 2487 + 2463 2488 static const struct ravb_hw_info gbeth_hw_info = { 2464 2489 .rx_ring_free = ravb_rx_ring_free_gbeth, 2465 2490 .rx_ring_format = ravb_rx_ring_format_gbeth, ··· 2512 2487 { .compatible = "renesas,etheravb-rcar-gen2", .data = &ravb_gen2_hw_info }, 2513 2488 { .compatible = "renesas,etheravb-r8a7795", .data = &ravb_gen3_hw_info }, 2514 2489 { .compatible = "renesas,etheravb-rcar-gen3", .data = &ravb_gen3_hw_info }, 2490 + { .compatible = "renesas,etheravb-rzv2m", .data = &ravb_rzv2m_hw_info }, 2515 2491 { .compatible = "renesas,rzg2l-gbeth", .data = &gbeth_hw_info }, 2516 2492 { } 2517 2493 };