net: dsa: mv88e6xxx: call _mv88e6xxx_stats_wait with SMI lock held
authorVivien Didelot <vivien.didelot@savoirfairelinux.com>
Mon, 3 Aug 2015 13:17:44 +0000 (09:17 -0400)
committerDavid S. Miller <davem@davemloft.net>
Mon, 3 Aug 2015 22:46:09 +0000 (15:46 -0700)
commit24751e29fe313105c9dd5f9d1f27028c553381f6
tree7d33adae616121265e969337ea9f0eea853813f9
parente44deb2f0cce9183ca94d14effd4170a35eec31d
net: dsa: mv88e6xxx: call _mv88e6xxx_stats_wait with SMI lock held

At switch setup, _mv88e6xxx_stats_wait was called without holding the
SMI mutex. Fix this by requesting the lock for this call.

Also, return the _mv88e6xxx_stats_wait code, since it may fail.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/mv88e6xxx.c