Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'pm-4.19-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm

Pull power management fixes from Rafael Wysocki:
"These address a corner case in the menu cpuidle governor and fix error
handling in the PM core's generic clock management code.

Specifics:

- Make the menu cpuidle governor avoid stopping the scheduler tick if
the predicted idle duration exceeds the tick period length, but the
selected idle state is shallow and deeper idle states with high
target residencies are available (Rafael Wysocki).

- Make the PM core's generic clock management code use a proper data
type for one variable to make error handling work (Dan Carpenter)"

* tag 'pm-4.19-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
cpuidle: menu: Retain tick when shallow state is selected
PM / clk: signedness bug in of_pm_clk_add_clks()

+13 -2
+1 -1
drivers/base/power/clock_ops.c
··· 185 185 int of_pm_clk_add_clks(struct device *dev) 186 186 { 187 187 struct clk **clks; 188 - unsigned int i, count; 188 + int i, count; 189 189 int ret; 190 190 191 191 if (!dev || !dev->of_node)
+12 -1
drivers/cpuidle/governors/menu.c
··· 379 379 if (idx == -1) 380 380 idx = i; /* first enabled state */ 381 381 if (s->target_residency > data->predicted_us) { 382 - if (!tick_nohz_tick_stopped()) 382 + if (data->predicted_us < TICK_USEC) 383 383 break; 384 + 385 + if (!tick_nohz_tick_stopped()) { 386 + /* 387 + * If the state selected so far is shallow, 388 + * waking up early won't hurt, so retain the 389 + * tick in that case and let the governor run 390 + * again in the next iteration of the loop. 391 + */ 392 + expected_interval = drv->states[idx].target_residency; 393 + break; 394 + } 384 395 385 396 /* 386 397 * If the state selected so far is shallow and this