Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
net: dsa: sja1105: add error handling in sja1105_setup()
commit cec279a upstream. If any of sja1105_static_config_load(), sja1105_clocking_setup() or sja1105_devlink_setup() fails, we can't just return in the middle of sja1105_setup() or memory will leak. Add a cleanup path. Fixes: 0a7bdbc ("net: dsa: sja1105: move devlink param code to sja1105_devlink.c") Fixes: 8aa9ebc ("net: dsa: Introduce driver for NXP SJA1105 5-port L2 switch") Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
- Loading branch information