[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 20/36] xen/common: introduce buddy required reservation
- To: Marco Solieri <marco.solieri@xxxxxxxxxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Wed, 9 Mar 2022 15:47:45 +0100
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=T53xnU4a/GGcxOM16qpKB8AnLIKiqNrKNO5PjcXhuIY=; b=lLTSLFibPV0yVDnbMgXIP4WK2VQ5aI8Ndh7WYle0btDQS9lytWQS+1q6UrREM6zjiUDDgPaYjqBc/VMboE1pxM8yiGtAMFFGLv/iQHjhtCPRo4mVE+QUB6Pg0VvOoNGIvNtQu0zP10qd75gYuCBkaCF9yWdN76QSna+lISKbzKy7RRtmo5k6Z3f4dI5FFtmhT4cTJkSE/5A9OlDhhk5OenmRcQQmhTM1+Bj/Z26RnUqHf284KO2x7KEsxBa8sjmIIW/NTfTcBRnNH9NO3FccsvW6GUtAMdekGCO6CF5ROjOefKQJMrER/CTvSPanHExOC3jp0a6rrqW7gjoiJClfUw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fOVhtZMsCi/TqCHs7xZrcOthq0z6eG7egpJfhkcUXMJ/Xb9U3OR/C/Kptwrp0yx6Nbj+TU+lQvRGHidI6xHc6/JiL4pDON5Va5or+l4BRfsDJkHOcRRrT8WBkN3OJzv/YzH75N/AbQPxctCuC56hKKsliMiJTnBc2AUFzkuKq7ej8L3VtZpAqb/QqrZxKP5zoUUUOGvhrXTnu13Y5tl7fWdKA3l1uGCGd8tpzR722Hl1H55pUbjoHhOOVQ0FUoqADa5yOcLkmknpJexybWxb0QkI3nho7V1wDFcti5z6ABFT+Pqh2hez9KbOPh5nCAAelrcRVFPn7PgpgKpQPZwClg==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Marco Solieri <marco.solieri@xxxxxxxxxx>, Andrea Bastoni <andrea.bastoni@xxxxxxxxxxxxxxx>, Luca Miccio <lucmiccio@xxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
- Delivery-date: Wed, 09 Mar 2022 14:48:04 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 09.03.2022 15:45, Jan Beulich wrote:
> On 04.03.2022 18:46, Marco Solieri wrote:
>> --- a/xen/common/page_alloc.c
>> +++ b/xen/common/page_alloc.c
>> @@ -230,6 +230,13 @@ static bool __read_mostly scrub_debug;
>> #define scrub_debug false
>> #endif
>>
>> +#ifdef CONFIG_COLORING
>> +/* Minimum size required for buddy allocator to work with colored one */
>> +unsigned long buddy_required_size __read_mostly = MB(64);
>> +#else
>> +unsigned long buddy_required_size __read_mostly = 0;
>> +#endif
>
> Please avoid such redundancy when possible. Here perhaps easiest
> by having the value come from Kconfig. By giving that separate
> option a prompt, it would even become configurable at build time.
Oh, and: Why is this not static? And without seeing what it's going
to be used for it's quite hard to judge whether the initial value
chosen is actually sufficient. I could imagine that this would
rather want to be derived from total memory size.
Jan
|