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

Commit 657ad054 authored by Pavankumar Kondeti's avatar Pavankumar Kondeti
Browse files

cpu-hotplug: Fix false error message in cpu_up()



An error message is printed even when the task's scheduling class
is switched back successfully. Fix the error condition check and
print the error value in the message.

Change-Id: Ib75c4cfa22d58dd9309542e96096ac4e91f0c3db
Signed-off-by: default avatarPavankumar Kondeti <pkondeti@codeaurora.org>
parent 68e85fd7
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -1122,8 +1122,9 @@ static int do_cpu_up(unsigned int cpu, enum cpuhp_state target)

	if (!switch_err) {
		switch_err = switch_to_fair_policy();
		pr_err("Hotplug policy switch err. Task %s pid=%d\n",
					current->comm, current->pid);
		if (switch_err)
			pr_err("Hotplug policy switch err=%d Task %s pid=%d\n",
				switch_err, current->comm, current->pid);
	}

	return err;