提交 230a5a1c 编写于 作者: M Mark Brown

regulator: Fix double free in devm_regulator_put()

Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
上级 8b96de31
......@@ -1461,9 +1461,7 @@ void devm_regulator_put(struct regulator *regulator)
rc = devres_release(regulator->dev, devm_regulator_release,
devm_regulator_match, regulator);
if (rc == 0)
regulator_put(regulator);
else
if (rc != 0)
WARN_ON(rc);
}
EXPORT_SYMBOL_GPL(devm_regulator_put);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册