mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-03 23:58:05 +00:00
mfd: core: Set fwnode for created devices
[ Upstream commit c176c6d7e9
]
The logic for setting the of_node on devices created by mfd did not set
the fwnode pointer to match, which caused fwnode-based APIs to
malfunction on these devices since the fwnode pointer was null. Fix
this.
Signed-off-by: Robert Hancock <hancock@sedsystems.ca>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
dab80aa013
commit
2ea30596cd
1 changed files with 1 additions and 0 deletions
|
@ -179,6 +179,7 @@ static int mfd_add_device(struct device *parent, int id,
|
|||
for_each_child_of_node(parent->of_node, np) {
|
||||
if (of_device_is_compatible(np, cell->of_compatible)) {
|
||||
pdev->dev.of_node = np;
|
||||
pdev->dev.fwnode = &np->fwnode;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue