lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <21e71153-a134-b553-785d-2264fa3f0327@arm.com>
Date:   Fri, 1 Oct 2021 17:01:32 +0100
From:   James Morse <james.morse@....com>
To:     "tan.shaopeng@...itsu.com" <tan.shaopeng@...itsu.com>,
        "'x86@...nel.org'" <x86@...nel.org>,
        "'linux-kernel@...r.kernel.org'" <linux-kernel@...r.kernel.org>
Cc:     'Fenghua Yu' <fenghua.yu@...el.com>,
        'Reinette Chatre' <reinette.chatre@...el.com>,
        'Thomas Gleixner' <tglx@...utronix.de>,
        'Ingo Molnar' <mingo@...hat.com>,
        'Borislav Petkov' <bp@...en8.de>,
        'H Peter Anvin' <hpa@...or.com>,
        'Babu Moger' <Babu.Moger@....com>,
        "'shameerali.kolothum.thodi@...wei.com'" 
        <shameerali.kolothum.thodi@...wei.com>,
        'Jamie Iles' <jamie@...iainc.com>,
        'D Scott Phillips OS' <scott@...amperecomputing.com>,
        "'lcherian@...vell.com'" <lcherian@...vell.com>,
        "'bobo.shaobowang@...wei.com'" <bobo.shaobowang@...wei.com>
Subject: Re: [PATCH v1 09/20] x86/resctrl: Abstract and use
 supports_mba_mbps()

Hi  Shaopeng Tan,

On 24/09/2021 07:23, tan.shaopeng@...itsu.com wrote:
>> To determine whether the mba_mbps option to resctrl should be supported,
>> resctrl tests the boot cpus' x86_vendor.
>>
>> This isn't portable, and needs abstracting behind a helper so this check can be
>> part of the filesystem code that moves to /fs/.
>>
>> Re-use the tests set_mba_sc() does to determine if the mba_sc is supported
>> on this system. An 'alloc_capable' test is added so that this property isn't
>> implied by 'linear'.

>> diff --git a/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> index e321ea5de562..4388685548a0 100644
>> --- a/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> +++ b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> @@ -2317,7 +2326,7 @@ static int rdt_parse_param(struct fs_context *fc,
>> struct fs_parameter *param)
>>  		ctx->enable_cdpl2 = true;
>>  		return 0;
>>  	case Opt_mba_mbps:
>> -		if (boot_cpu_data.x86_vendor != X86_VENDOR_INTEL)
>> +		if (supports_mba_mbps())
>>  			return -EINVAL;
> I think if(!supports_mba_mbps()) is correct, isn't it? 

Ooops!

(looks like I messed this up when fixing the name)


Thanks,

James

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ