提交 f2dfab35 编写于 作者: M Mathieu Poirier 提交者: Greg Kroah-Hartman

coresight: release reference taken by 'bus_find_device()'

The reference count taken by function bus_find_device() needs
to be released if a child device is found, something this patch
is adding.
Reported-by: NRabin Vincent <rabin@rab.in>
Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 fae54158
......@@ -570,6 +570,8 @@ static void coresight_fixup_device_conns(struct coresight_device *csdev)
if (dev) {
conn->child_dev = to_coresight_device(dev);
/* and put reference from 'bus_find_device()' */
put_device(dev);
} else {
csdev->orphan = true;
conn->child_dev = NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册