]> git.baikalelectronics.ru Git - kernel.git/commit
net: stmmac: Implement logic to automatically select HW Interface
authorJose Abreu <Jose.Abreu@synopsys.com>
Mon, 23 Apr 2018 08:05:15 +0000 (09:05 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 23 Apr 2018 16:03:50 +0000 (12:03 -0400)
commit9079ee5ebab1ae30089edb15d09a97f51adc7494
tree2b6f84765c55bbe7b9ef2bf55ac050ad8f888550
parentf736d933ce97481df8c35fa487478b83bd4e6044
net: stmmac: Implement logic to automatically select HW Interface

Move all the core version detection to a common place ("hwif.c") and
implement a table which can be used to lookup the correct callbacks for
each IP version.

This simplifies the initialization flow of each IP version and eases
future implementation of new IP versions.

Signed-off-by: Jose Abreu <joabreu@synopsys.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Joao Pinto <jpinto@synopsys.com>
Cc: Vitor Soares <soares@synopsys.com>
Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Cc: Alexandre Torgue <alexandre.torgue@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/Makefile
drivers/net/ethernet/stmicro/stmmac/common.h
drivers/net/ethernet/stmicro/stmmac/dwmac1000.h
drivers/net/ethernet/stmicro/stmmac/dwmac1000_core.c
drivers/net/ethernet/stmicro/stmmac/dwmac100_core.c
drivers/net/ethernet/stmicro/stmmac/dwmac4.h
drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
drivers/net/ethernet/stmicro/stmmac/hwif.c [new file with mode: 0644]
drivers/net/ethernet/stmicro/stmmac/hwif.h
drivers/net/ethernet/stmicro/stmmac/stmmac.h
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c