瀏覽代碼

ARM: mvebu: add missing of_node_put()

This node pointer is returned by of_find_compatible_node() in this
function.  It should be put before exitting this function.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
Masahiro Yamada 9 年之前
父節點
當前提交
7d8f9ac162
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      arch/arm/mach-mvebu/platsmp.c

+ 1 - 0
arch/arm/mach-mvebu/platsmp.c

@@ -140,6 +140,7 @@ static void __init armada_xp_smp_prepare_cpus(unsigned int max_cpus)
 		panic("Cannot find 'marvell,bootrom' compatible node");
 
 	err = of_address_to_resource(node, 0, &res);
+	of_node_put(node);
 	if (err < 0)
 		panic("Cannot get 'bootrom' node address");