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

Commit d208169b authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "sysctl: Limit sched_upmigrate/sched_downmigrate tunables range"

parents 840689a8 e738aab7
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -3327,7 +3327,11 @@ static int do_proc_douintvec_capacity_conv(bool *negp, unsigned long *lvalp,
					   int *valp, int write, void *data)
{
	if (write) {
		if (*negp || *lvalp == 0)
		/*
		 * The sched_upmigrate/sched_downmigrate tunables are
		 * accepted in percentage. Limit them to 100.
		 */
		if (*negp || *lvalp == 0 || *lvalp > 100)
			return -EINVAL;
		*valp = SCHED_FIXEDPOINT_SCALE * 100 / *lvalp;
	} else {