Re: [PATCH v7 09/15] x86/sgx: Charge mem_cgroup for per-cgroup reclamation

2024-02-02 Thread Haitao Huang
Hi Tim, On Fri, 02 Feb 2024 17:45:05 -0600, Tim Chen wrote: On Mon, 2024-01-22 at 09:20 -0800, Haitao Huang wrote: @@ -1047,29 +1037,38 @@ static struct mem_cgroup *sgx_encl_get_mem_cgroup(struct sgx_encl *encl) * @encl: an enclave pointer * @page_index:enclave page ind

Re: [PATCH v7 09/15] x86/sgx: Charge mem_cgroup for per-cgroup reclamation

2024-02-02 Thread Tim Chen
On Mon, 2024-01-22 at 09:20 -0800, Haitao Huang wrote: > > @@ -1047,29 +1037,38 @@ static struct mem_cgroup > *sgx_encl_get_mem_cgroup(struct sgx_encl *encl) > * @encl:an enclave pointer > * @page_index: enclave page index > * @backing: data for accessing backing storage for the pa

Re: [PATCH v7 09/15] x86/sgx: Charge mem_cgroup for per-cgroup reclamation

2024-01-26 Thread Haitao Huang
On Fri, 26 Jan 2024 08:37:25 -0600, Huang, Kai wrote: Signed-off-by: Haitao Huang Reported-by: Mikko Ylinen --- Non-technical staff: I believe checkpatch requires you to have a "Closes" tag after "Reported-by" otherwise it complains something like this: WARNING: Reported-by: shoul

Re: [PATCH v7 09/15] x86/sgx: Charge mem_cgroup for per-cgroup reclamation

2024-01-26 Thread Huang, Kai
> > Signed-off-by: Haitao Huang > Reported-by: Mikko Ylinen > --- Non-technical staff: I believe checkpatch requires you to have a "Closes" tag after "Reported-by" otherwise it complains something like this: WARNING: Reported-by: should be immediately followed by Closes: with a URL to th

Re: [PATCH v7 09/15] x86/sgx: Charge mem_cgroup for per-cgroup reclamation

2024-01-22 Thread Jarkko Sakkinen
On Mon Jan 22, 2024 at 7:20 PM EET, Haitao Huang wrote: > Enclave Page Cache(EPC) memory can be swapped out to regular system > memory, and the consumed memory should be charged to a proper > mem_cgroup. Currently the selection of mem_cgroup to charge is done in > sgx_encl_get_mem_cgroup(). But it

[PATCH v7 09/15] x86/sgx: Charge mem_cgroup for per-cgroup reclamation

2024-01-22 Thread Haitao Huang
Enclave Page Cache(EPC) memory can be swapped out to regular system memory, and the consumed memory should be charged to a proper mem_cgroup. Currently the selection of mem_cgroup to charge is done in sgx_encl_get_mem_cgroup(). But it only considers two contexts in which the swapping can be done: n