Return-Path: Received: from mail.linuxfoundation.org ([140.211.169.12]:59532 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754434AbeDIUER (ORCPT ); Mon, 9 Apr 2018 16:04:17 -0400 Subject: Patch "mdio: mux: fix device_node_continue.cocci warnings" has been added to the 4.9-stable tree To: julia.lawall@lip6.fr, alexander.levin@microsoft.com, davem@davemloft.net, fengguang.wu@intel.com, gregkh@linuxfoundation.org, jon.mason@broadcom.com Cc: , From: Date: Mon, 09 Apr 2018 21:58:40 +0200 Message-ID: <152330392038220@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org List-ID: This is a note to let you know that I've just added the patch titled mdio: mux: fix device_node_continue.cocci warnings to the 4.9-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-mux-fix-device_node_continue.cocci-warnings.patch and it can be found in the queue-4.9 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >From foo@baz Mon Apr 9 17:09:24 CEST 2018 From: Julia Lawall Date: Fri, 12 May 2017 22:54:23 +0800 Subject: mdio: mux: fix device_node_continue.cocci warnings From: Julia Lawall [ Upstream commit 8c977f5a856a7276450ddf3a7b57b4a8815b63f9 ] Device node iterators put the previous value of the index variable, so an explicit put causes a double put. In particular, of_mdiobus_register can fail before doing anything interesting, so one could view it as a no-op from the reference count point of view. Generated by: scripts/coccinelle/iterators/device_node_continue.cocci CC: Jon Mason Signed-off-by: Julia Lawall Signed-off-by: Fengguang Wu Signed-off-by: David S. Miller Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/net/phy/mdio-mux.c | 1 - 1 file changed, 1 deletion(-) --- a/drivers/net/phy/mdio-mux.c +++ b/drivers/net/phy/mdio-mux.c @@ -169,7 +169,6 @@ int mdio_mux_init(struct device *dev, if (r) { mdiobus_free(cb->mii_bus); devm_kfree(dev, cb); - of_node_put(child_bus_node); } else { cb->next = pb->children; pb->children = cb; Patches currently in stable-queue which might be from julia.lawall@lip6.fr are queue-4.9/mdio-mux-fix-device_node_continue.cocci-warnings.patch