Hi Leo,
<snip>
If there's a way we can switch to using that for this case, that would be great as well - although this path also does energy diff.
I think you are suggesting the modification like below patch; please
No actually I was just referring to using a unified CPU selection logic in mainline code for Case B and C as well, instead of doing the find_best_target. I guess it is more difficult to do than I think since mainline tries to spread tasks for perf reasons, than pack them so may be it has to be separate after all for a separate "energy saving" selection logic..
note below patch has two issues, first one issue I have replied in another email that capacity_of() cannot update RT pressure for every
Ok, I'll reply to this in that thread.
call, another issue is for WALT signal the RT pressure has been counted twice (one is from capacity_of(), another is from cpu_util() which natually includes RT + CFS util).
Yes, I see this too. At the moment I was trying to do it from mainline perspective - and Rohit doesn't use EAS/WALT anyway. For my testing of capacity_of in capacity_spare_wake, I turn off WALT for the very reason you mention. With WALT capacity_spare_wake already has RT pressure included.
The below patch looks good in principle to me, but I think its a good idea to add a new abstraction 'capacity_spare' which can prevents the double accounting for WALT case capacity spare. And for PELT, just do the regular thing, and then make use of that in find_best_target. So for WALT the new capacity_spare() would return (capacity_orig_of - cpu_util) and for PELT it would return (capacity_of - cpu_util). What do you think?
thanks,
- Joel
<snip>