lkml.org 
[lkml]   [2021]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] sched/uclamp: Fix getting unreasonable ucalmp_max when rq is idle
Date
On 30/06/21 09:24, Xuewen Yan wrote:
> On Tue, Jun 29, 2021 at 9:50 PM Valentin Schneider
> <valentin.schneider@arm.com> wrote:
>> + min_util = max_t(unsigned long, min_util, READ_ONCE(rq->uclamp[UCLAMP_MIN].value));
>> + max_util = max_t(unsigned long, max_util, READ_ONCE(rq->uclamp[UCLAMP_MAX].value));
>
> Is it necessary to use max_t here? although it is not the main problem...
>

I got comparison warnings when using a regular max() - the RQ clamp values
are unsigned int, whereas the local variable is unsigned long.

>> +out:
>> /*
>> * Since CPU's {min,max}_util clamps are MAX aggregated considering
>> * RUNNABLE tasks with _different_ clamps, we can end up with an
>
> Thanks!
> xuewen

\
 
 \ /
  Last update: 2021-06-30 13:32    [W:0.367 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site