of: overlay: do not break notify on NOTIFY_{OK|STOP}
[ Upstream commit5f756a2eaa] We should not break overlay notifications on NOTIFY_{OK|STOP} otherwise we might break on the first fragment. We should only stop notifications if a *real* errno is returned by one of the listeners. Fixes:a1d19bd4cf("of: overlay: pr_err from return NOTIFY_OK to overlay apply/remove") Signed-off-by: Nuno Sá <nuno.sa@analog.com> Signed-off-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220420130205.89435-1-nuno.sa@analog.com Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
f929416d5c
commit
cc68e53f9a
@@ -170,9 +170,7 @@ static int overlay_notify(struct overlay_changeset *ovcs,
|
|||||||
|
|
||||||
ret = blocking_notifier_call_chain(&overlay_notify_chain,
|
ret = blocking_notifier_call_chain(&overlay_notify_chain,
|
||||||
action, &nd);
|
action, &nd);
|
||||||
if (ret == NOTIFY_OK || ret == NOTIFY_STOP)
|
if (notifier_to_errno(ret)) {
|
||||||
return 0;
|
|
||||||
if (ret) {
|
|
||||||
ret = notifier_to_errno(ret);
|
ret = notifier_to_errno(ret);
|
||||||
pr_err("overlay changeset %s notifier error %d, target: %pOF\n",
|
pr_err("overlay changeset %s notifier error %d, target: %pOF\n",
|
||||||
of_overlay_action_name[action], ret, nd.target);
|
of_overlay_action_name[action], ret, nd.target);
|
||||||
|
|||||||
Reference in New Issue
Block a user