Thread (4 messages) flat view 4 messages, 4 authors, 2021-09-07
STALE1823d

[PATCH] pci/hotplug/pnv-php: Remove probable double put

From: Xu Wang <hidden>
Date: 2021-09-07 09:15:22
Also in: linux-pci, lkml
Subsystem: linux for powerpc (32-bit and 64-bit), pci subsystem, the rest · Maintainers: Madhavan Srinivasan, Bjorn Helgaas, Linus Torvalds

Device node iterators put the previous value of the index variable,
so an explicit put causes a double put.

Signed-off-by: Xu Wang <redacted>
---
 drivers/pci/hotplug/pnv_php.c | 1 -
 1 file changed, 1 deletion(-)
diff --git a/drivers/pci/hotplug/pnv_php.c b/drivers/pci/hotplug/pnv_php.c
index 04565162a449..ed4d1a2c3f22 100644
--- a/drivers/pci/hotplug/pnv_php.c
+++ b/drivers/pci/hotplug/pnv_php.c
@@ -158,7 +158,6 @@ static void pnv_php_detach_device_nodes(struct device_node *parent)
 	for_each_child_of_node(parent, dn) {
 		pnv_php_detach_device_nodes(dn);
 
-		of_node_put(dn);
 		of_detach_node(dn);
 	}
 }
-- 
2.17.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help