[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <384a9be4-8123-3b3a-3be7-c549c8126fc8@arm.com>
Date: Wed, 13 Dec 2023 18:05:06 +0000
From: James Morse <james.morse@....com>
To: Reinette Chatre <reinette.chatre@...el.com>, x86@...nel.org,
linux-kernel@...r.kernel.org
Cc: Fenghua Yu <fenghua.yu@...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,
D Scott Phillips OS <scott@...amperecomputing.com>,
carl@...amperecomputing.com, lcherian@...vell.com,
bobo.shaobowang@...wei.com, tan.shaopeng@...itsu.com,
baolin.wang@...ux.alibaba.com, Jamie Iles <quic_jiles@...cinc.com>,
Xin Hao <xhao@...ux.alibaba.com>, peternewman@...gle.com,
dfustini@...libre.com, amitsinght@...vell.com
Subject: Re: [PATCH v7 09/24] x86/resctrl: Use __set_bit()/__clear_bit()
instead of open coding
Hi Reinette,
On 09/11/2023 17:44, Reinette Chatre wrote:
> On 10/25/2023 11:03 AM, James Morse wrote:
>> The resctrl CLOSID allocator uses a single 32bit word to track which
>> CLOSID are free. The setting and clearing of bits is open coded.
>>
>> A subsequent patch adds closid_allocated(), which adds more open
>
> (Note use of "A subsequent patch ")
Yup, I've dropped this paragraph.
>> coded bitmaps operations. These will eventually need changing to use
>> the bitops helpers so that a CLOSID bitmap of the correct size can be
>> allocated dynamically.
>>
>> Convert the existing open coded bit manipulations of closid_free_map
>> to use __set_bit() and friends. These don't need to be atomic as this
>> list is protected by the mutex.
>> diff --git a/arch/x86/kernel/cpu/resctrl/rdtgroup.c b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> index 9864cb49d58c..f6051a3e7262 100644
>> --- a/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> +++ b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>> @@ -131,7 +131,7 @@ static void closid_init(void)
>> closid_free_map = BIT_MASK(rdt_min_closid) - 1;
>>
>> /* CLOSID 0 is always reserved for the default group */
>
> Seems appropriate for the comment to be updated to the new define also.
Sure,
> With that addressed you can add:
> Reviewed-by: Reinette Chatre <reinette.chatre@...el.com>
Thanks!
James
Powered by blists - more mailing lists