lkml.org 
[lkml]   [2018]   [Nov]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [Patch v5 08/16] smt: Create cpu_smt_enabled static key for SMT specific code
Date
Thomas,


>>
>> +#ifdef CONFIG_SCHED_SMT
>> +
>> +extern struct static_key_false sched_smt_present;
>> +
>> +static inline bool cpu_smt_present(void)
>> +{
>> + if (static_branch_unlikely(&sched_smt_present))
>> + return true;
>> + else
>> + return false;
>
> What's wrong with
>
> return static_branch_unlikely(&sched_smt_present);
>
> ???
>
> But that's just a stylistic nitpick. The real issue is that you prevent the
> mitigation when CONFIG_SCHED_SMT=n.
>

Right. The sched_smt_present is just a scheduler construct and the sibling
cpu will still be brought online. Scratch this.

Tim

\
 
 \ /
  Last update: 2018-11-19 20:26    [W:1.121 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site