This is a note to let you know that I've just added the patch titled mdio-sun4i: oops in error handling in probe to the 4.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: mdio-sun4i-oops-in-error-handling-in-probe.patch and it can be found in the queue-4.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From 227f33beab746aeec4ef3305bd17b1d374df09e7 Mon Sep 17 00:00:00 2001 From: Dan Carpenter <dan.carpenter@xxxxxxxxxx> Date: Mon, 21 Mar 2016 12:02:31 +0300 Subject: mdio-sun4i: oops in error handling in probe From: Dan Carpenter <dan.carpenter@xxxxxxxxxx> commit 227f33beab746aeec4ef3305bd17b1d374df09e7 upstream. We could end up dereferencing an error pointer when we call regulator_disable(). Fixes: 4bdcb1dd9feb ('net: Add MDIO bus driver for the Allwinner EMAC') Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> Acked-by: Chen-Yu Tsai <wens@xxxxxxxx> Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- drivers/net/phy/mdio-sun4i.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) --- a/drivers/net/phy/mdio-sun4i.c +++ b/drivers/net/phy/mdio-sun4i.c @@ -134,6 +134,7 @@ static int sun4i_mdio_probe(struct platf } dev_info(&pdev->dev, "no regulator found\n"); + data->regulator = NULL; } else { ret = regulator_enable(data->regulator); if (ret) @@ -149,7 +150,8 @@ static int sun4i_mdio_probe(struct platf return 0; err_out_disable_regulator: - regulator_disable(data->regulator); + if (data->regulator) + regulator_disable(data->regulator); err_out_free_mdiobus: mdiobus_free(bus); return ret; Patches currently in stable-queue which might be from dan.carpenter@xxxxxxxxxx are queue-4.4/mips-rm7000-double-locking-bug-in-rm7k_tc_disable.patch queue-4.4/btrfs-clean-up-an-error-code-in-btrfs_init_space_info.patch queue-4.4/xprtrdma-checking-for-null-instead-of-is_err.patch queue-4.4/asoc-intel-pass-correct-parameter-in-sst_alloc_stream_mrfld.patch queue-4.4/mips-octeon-off-by-one-in-octeon_irq_gpio_map.patch queue-4.4/nfc-nci-memory-leak-in-nci_core_conn_create.patch queue-4.4/bpf-mips-fix-off-by-one-in-ctx-offset-allocation.patch queue-4.4/mdio-sun4i-oops-in-error-handling-in-probe.patch queue-4.4/x86-apic-uv-silence-a-shift-wrapping-warning.patch