diff options
author | Jon Medhurst (Tixy) <tixy@linaro.org> | 2016-01-26 18:59:13 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2016-01-27 20:07:51 +0100 |
commit | 57480484f9f7631738ef28b952eca3c9081c4291 (patch) | |
tree | cd79993b4871964d8d8bef8206dde643d9c55c27 /Documentation/power | |
parent | component: fix crash on x86_64 with hda audio drivers (diff) | |
download | linux-57480484f9f7631738ef28b952eca3c9081c4291.tar.xz linux-57480484f9f7631738ef28b952eca3c9081c4291.zip |
component: Detach components when deleting master struct
component_master_add_with_match calls find_components which, if any
components already exist, it attaches to the master struct. However, if
we later encounter an error the master struct is deleted, leaving
components with a dangling pointer to it.
If the error was a temporary one, e.g. for probe deferral, then when
the master device is re-probed, it will fail to find the required
components as they appear to already be attached to a master.
Fix this by nulling components pointers to the master struct when it is
deleted. This code is factored out into a separate function so it can be
shared with component_master_del.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'Documentation/power')
0 files changed, 0 insertions, 0 deletions