lkml.org 
[lkml]   [2024]   [Feb]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v9 10/15] x86/sgx: Add EPC reclamation in cgroup try_charge()
From


On 27/02/2024 11:38 am, Dave Hansen wrote:
> On 2/26/24 14:34, Huang, Kai wrote:
>> So I am trying to get the actual downside of doing per-cgroup reclaim or
>> the full reason that we choose global reclaim.
>
> Take the most extreme example:
>
> while (hit_global_sgx_limit())
> reclaim_from_this(cgroup);
>
> You eventually end up with all of 'cgroup's pages gone and handed out to
> other users on the system who stole them all. Other users might cause
> you to go over the global limit. *They* should be paying part of the
> cost, not just you and your cgroup.

Yeah likely we will need another layer of logic to decide when to do
global reclaim. I agree that is downside and is unnecessary for this
patchset.

Thanks for the comments.

\
 
 \ /
  Last update: 2024-05-27 15:22    [W:0.094 / U:2.668 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site