]> git.baikalelectronics.ru Git - kernel.git/commit
net: axienet: Enable more clocks
authorRobert Hancock <robert.hancock@calian.com>
Fri, 26 Mar 2021 00:04:38 +0000 (18:04 -0600)
committerDavid S. Miller <davem@davemloft.net>
Fri, 26 Mar 2021 22:17:17 +0000 (15:17 -0700)
commitc74d1394e20638ab228d7093712ba43b7439cca5
treecba9ceadaf439408c6d5e10fe8e4636ddb004d9e
parent268f22a7bd987954b1e353effde6e3fe6b31a555
net: axienet: Enable more clocks

This driver was only enabling the first clock on the device, regardless
of its name. However, this controller logic can have multiple clocks
which should all be enabled. Add support for enabling additional clocks.
The clock names used are matching those used in the Xilinx version of this
driver as well as the Xilinx device tree generator, except for mgt_clk
which is not present there.

For backward compatibility, if no named clocks are present, the first
clock present is used for determining the MDIO bus clock divider.

Reviewed-by: Radhey Shyam Pandey <radhey.shyam.pandey@xilinx.com>
Signed-off-by: Robert Hancock <robert.hancock@calian.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/xilinx/xilinx_axienet.h
drivers/net/ethernet/xilinx/xilinx_axienet_main.c
drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c