net: dsa: get master device at port parsing time
authorVivien Didelot <vivien.didelot@savoirfairelinux.com>
Fri, 27 Oct 2017 19:55:17 +0000 (15:55 -0400)
committerDavid S. Miller <davem@davemloft.net>
Wed, 1 Nov 2017 02:47:36 +0000 (11:47 +0900)
commitcbabb0ac01052f79cf96d7b7e3d3451ffd275864
tree069e44e90d97695dee2c5d211d680f25138e1b71
parent6d4e5c570c2d66c806ecc6bd851fcf881fe8a38e
net: dsa: get master device at port parsing time

Fetching the master device can be done directly when a port is parsed
from device tree or pdata, instead of waiting until dsa_dst_parse.

Now that -EPROBE_DEFER is returned before we add the switch to the tree,
there is no need to check for this error after dsa_dst_parse.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/dsa/dsa2.c