lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 20 Oct 2014 16:47:48 +0200
From:	Javier Martinez Canillas <>
To:	Mark Brown <>
Cc:	Chanwoo Choi <>,
	Olof Johansson <>,
	Chris Zhong <>,
	Krzysztof Kozlowski <>,
	Abhilash Kesavan <>,,,,
	Javier Martinez Canillas <>
Subject: [PATCH v3 1/5] regulator: of: Decrement refcount for suspend state nodes

of_get_regulation_constraints() calls of_get_child_by_name() to find the
regulator-state-{mem,disk} child nodes for each regulator. This function
increments the device node reference counter but this is not decremented
once the function is done using the node.

Fix that by calling of_node_put() after finishing using the device node.

Signed-off-by: Javier Martinez Canillas <>
 drivers/regulator/of_regulator.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/regulator/of_regulator.c b/drivers/regulator/of_regulator.c
index b375ffe..f0d19fc 100644
--- a/drivers/regulator/of_regulator.c
+++ b/drivers/regulator/of_regulator.c
@@ -107,6 +107,7 @@ static void of_get_regulation_constraints(struct device_node *np,
 			suspend_state->disabled = true;
+		of_node_put(suspend_np);
 		suspend_state = NULL;
 		suspend_np = NULL;

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

Powered by blists - more mailing lists