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

Commit 248d60c5 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "PM / OPP: Fix potential access to invalid list entry"

parents 6ec7d5c6 24e8b394
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -462,6 +462,9 @@ int dev_pm_opp_add(struct device *dev, unsigned long freq, unsigned long u_volt)
		else
			head = &opp->node;
	}
	/* new_opp is the largest */
	if (&opp->node == &dev_opp->opp_list)
		goto list_add;

	/* Duplicate OPPs ? */
	if (new_opp->rate == opp->rate) {