Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 17c34c56 authored by Peter De Schrijver's avatar Peter De Schrijver Committed by Michael Turquette
Browse files

clk: aggregate return codes of notify chains



In case there are multiple notify chains for the same clocks (because they
were registered by different users), we need to propagate potential failure
of any single one of them to the caller. Otherwise we eg risk violating the
V/f curve when a notifier is used for DVFS.

Signed-off-by: default avatarPeter De Schrijver <pdeschrijver@nvidia.com>
Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
Signed-off-by: default avatarMichael Turquette <mturquette@baylibre.com>
parent 92031575
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -966,6 +966,8 @@ static int __clk_notify(struct clk_core *core, unsigned long msg,
			cnd.clk = cn->clk;
			ret = srcu_notifier_call_chain(&cn->notifier_head, msg,
					&cnd);
			if (ret & NOTIFY_STOP_MASK)
				return ret;
		}
	}