[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] x86: fix "xpti=" and "pv-l1tf=" yet again



>>> On 21.08.18 at 14:13, <jgross@xxxxxxxx> wrote:
> On 21/08/18 12:44, Jan Beulich wrote:
>> @@ -219,17 +216,13 @@ static int __init parse_spec_ctrl(const
>>  }
>>  custom_param("spec-ctrl", parse_spec_ctrl);
>>  
>> -int8_t __read_mostly opt_pv_l1tf = -1;
>> +uint8_t __read_mostly opt_pv_l1tf = OPT_PV_L1TF_DOMU_DEFAULT;
>>  
>>  static __init int parse_pv_l1tf(const char *s)
>>  {
>>      const char *ss;
>>      int val, rc = 0;
>>  
>> -    /* Inhibit the defaults as an explicit choice has been given. */
>> -    if ( opt_pv_l1tf == -1 )
>> -        opt_pv_l1tf = 0;
> 
> Wouldn't setting the default value (DOMU) here be enough? Same for
> xpti below?

No, because we want to defer default processing until we've
actually obtained the necessary data. While parsing we don't
know yet whether "default" means "on" or "off".

Or perhaps I don't understand what you mean?

>> @@ -250,13 +243,16 @@ static __init int parse_pv_l1tf(const ch
>>              break;
>>  
>>          default:
>> -            if ( (val = parse_boolean("dom0", s, ss)) >= 0 )
>> +            if ( !strcmp(s, "default") )
>> +                opt_xpti = OPT_PV_L1TF_DOMU_DEFAULT;
> 
> opt_pv_l1tf

Argh, again. And I've tried to be super careful... Thanks for
noticing!

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.