
The RK3399 includes the Designware Gigabit Ethernet controller IP and requires similar configuration as the RK3288. However, the configuration register offsets (within GRF) and bit offsets (within the registers) differ.
This changeset refactors the gmac_rockchip.c driver to handle both RK3288 and RK3399 devices. It further adds the necessary pinctrl and clock support for GMAC capability on the RK3399.
Tested with a RK3399-Q7 (on-module KSZ9031 PHY) at 100MBit and 1GBit.
Philipp Tomsich (6): rockchip: pinctrl: rk3399: add GMAC (RGMII only) support rockchip: clk: rk3399: fix warnings for unused variables in SPL/non-SPL rockchip: clk: rk3399: add clocking support for Ethernet net: gmac_rockchip: Add support for the RK3399 GMAC dts: rk3399: add gmac for the rk3399 dts: rk3399-puma: add gmac for the RK3399-Q7
arch/arm/dts/rk3399-puma.dts | 30 +++++ arch/arm/dts/rk3399.dtsi | 55 ++++++++++ arch/arm/include/asm/arch-rockchip/grf_rk3288.h | 68 ++++++------ arch/arm/include/asm/arch-rockchip/grf_rk3399.h | 84 +++++++++++++- arch/arm/include/asm/arch-rockchip/periph.h | 1 + drivers/clk/rockchip/clk_rk3399.c | 9 ++ drivers/net/gmac_rockchip.c | 140 +++++++++++++++++++----- drivers/pinctrl/rockchip/pinctrl_rk3399.c | 42 +++++++ 8 files changed, 367 insertions(+), 62 deletions(-)