Skip to content

Commit

Permalink
Merge branch 'powercap'
Browse files Browse the repository at this point in the history
Merge a Dynamic Thermal Power Management (DTPM) framework fix for
5.16-rc2.

* powercap:
  powercap: DTPM: Fix suspend failure and kernel warning
  • Loading branch information
Rafael J. Wysocki committed Nov 18, 2021
2 parents 0837441 + 4d1cd14 commit 47b577a
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions drivers/powercap/dtpm_cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,16 +166,13 @@ static struct dtpm_ops dtpm_ops = {

static int cpuhp_dtpm_cpu_offline(unsigned int cpu)
{
struct em_perf_domain *pd;
struct dtpm_cpu *dtpm_cpu;

pd = em_cpu_get(cpu);
if (!pd)
return -EINVAL;

dtpm_cpu = per_cpu(dtpm_per_cpu, cpu);
if (dtpm_cpu)
dtpm_update_power(&dtpm_cpu->dtpm);

return dtpm_update_power(&dtpm_cpu->dtpm);
return 0;
}

static int cpuhp_dtpm_cpu_online(unsigned int cpu)
Expand Down

0 comments on commit 47b577a

Please sign in to comment.