diff options
author | Jon Mason <jon.mason@broadcom.com> | 2017-05-08 17:48:35 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-05-14 14:06:02 +0200 |
commit | 275e2edbb8f1d13a58320cf205d710df70733fb5 (patch) | |
tree | 37e5a3c06bb2c7a852c296bab0d56c95beb042af /tools/perf/util/scripting-engines/trace-event-perl.c | |
parent | ced12308e58cc95002404b584fdc756a233581ab (diff) | |
download | blackbird-op-linux-275e2edbb8f1d13a58320cf205d710df70733fb5.tar.gz blackbird-op-linux-275e2edbb8f1d13a58320cf205d710df70733fb5.zip |
net: mdio-mux: bcm-iproc: call mdiobus_free() in error path
[ Upstream commit 922c60e89d52730050c6ccca218bff40cc8bcd8e ]
If an error is encountered in mdio_mux_init(), the error path will call
mdiobus_free(). Since mdiobus_register() has been called prior to
mdio_mux_init(), the bus->state will not be MDIOBUS_UNREGISTERED. This
causes a BUG_ON() in mdiobus_free(). To correct this issue, add an
error path for mdio_mux_init() which calls mdiobus_unregister() prior to
mdiobus_free().
Signed-off-by: Jon Mason <jon.mason@broadcom.com>
Fixes: 98bc865a1ec8 ("net: mdio-mux: Add MDIO mux driver for iProc SoCs")
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-perl.c')
0 files changed, 0 insertions, 0 deletions