PM / Domains: Don't kfree() the virtual device in the error path
It's not correct to call kfree(dev) when device_register(dev) has failed. Fix this by calling put_device(dev) instead. Fixes: 3c095f32 ("PM / Domains: Add support for multi PM domains per device to genpd") Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Acked-by: NViresh Kumar <viresh.kumar@linaro.org> Acked-by: NNiklas Cassel <niklas.cassel@linaro.org> Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
Showing
想要评论请 注册 或 登录