net: stmmac: Run HWIF Quirks after getting HW caps
authorJose Abreu <[email protected]>
Fri, 15 Jun 2018 15:17:27 +0000 (16:17 +0100)
committerDavid S. Miller <[email protected]>
Fri, 15 Jun 2018 16:38:52 +0000 (09:38 -0700)
commit7cfde0af731c14664e3882c7ba77ace1059f2c5e
tree596207da1c3aba8a6cd0cb7e22065aeaed1faa62
parentf6a6f203d507aae3a06a8de79c6f0ecc4658b81c
net: stmmac: Run HWIF Quirks after getting HW caps

Currently we were running HWIF quirks before getting HW capabilities.
This is not right because some HWIF callbacks depend on HW caps.

Lets save the quirks callback and use it in a later stage.

This fixes Altera socfpga.

Signed-off-by: Jose Abreu <[email protected]>
Fixes: 5f0456b43140 ("net: stmmac: Implement logic to automatically select HW Interface")
Reported-by: Dinh Nguyen <[email protected]>
Cc: David S. Miller <[email protected]>
Cc: Joao Pinto <[email protected]>
Cc: Vitor Soares <[email protected]>
Cc: Giuseppe Cavallaro <[email protected]>
Cc: Alexandre Torgue <[email protected]>
Cc: Dinh Nguyen <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
drivers/net/ethernet/stmicro/stmmac/hwif.c
drivers/net/ethernet/stmicro/stmmac/stmmac.h
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c