Hi Jan 

> -----Original Message-----
> From: Jan Beulich <jbeul...@suse.com>
> Sent: Tuesday, May 18, 2021 7:25 PM
> To: Penny Zheng <penny.zh...@arm.com>
> Cc: Bertrand Marquis <bertrand.marq...@arm.com>; Wei Chen
> <wei.c...@arm.com>; nd <n...@arm.com>; xen-devel@lists.xenproject.org;
> sstabell...@kernel.org; jul...@xen.org
> Subject: Re: [PATCH 08/10] xen/arm: introduce reserved_page_list
> 
> On 18.05.2021 10:38, Penny Zheng wrote:
> > Hi Jan
> >
> >> -----Original Message-----
> >> From: Jan Beulich <jbeul...@suse.com>
> >> Sent: Tuesday, May 18, 2021 3:39 PM
> >> To: Penny Zheng <penny.zh...@arm.com>
> >> Cc: Bertrand Marquis <bertrand.marq...@arm.com>; Wei Chen
> >> <wei.c...@arm.com>; nd <n...@arm.com>; xen-
> de...@lists.xenproject.org;
> >> sstabell...@kernel.org; jul...@xen.org
> >> Subject: Re: [PATCH 08/10] xen/arm: introduce reserved_page_list
> >>
> >> On 18.05.2021 07:21, Penny Zheng wrote:
> >>> Since page_list under struct domain refers to linked pages as gueast
> >>> RAM allocated from heap, it should not include reserved pages of
> >>> static
> >> memory.
> >>>
> >>> The number of PGC_reserved pages assigned to a domain is tracked in
> >>> a new 'reserved_pages' counter. Also introduce a new
> >>> reserved_page_list to link pages of static memory. Let page_to_list
> >>> return reserved_page_list, when flag is PGC_reserved.
> >>>
> >>> Later, when domain get destroyed or restarted, those new values will
> >>> help relinquish memory to proper place, not been given back to heap.
> >>>
> >>> Signed-off-by: Penny Zheng <penny.zh...@arm.com>
> >>> ---
> >>>  xen/common/domain.c     | 1 +
> >>>  xen/common/page_alloc.c | 7 +++++--  xen/include/xen/sched.h | 5
> >>> +++++
> >>>  3 files changed, 11 insertions(+), 2 deletions(-)
> >>
> >> This contradicts the title's prefix: There's no Arm-specific change here at
> all.
> >> But imo the title is correct, and the changes should be Arm-specific.
> >> There's no point having struct domain fields on e.g. x86 which aren't used
> there at all.
> >>
> >
> > Yep, you're right.
> > I'll add ifdefs in the following changes.
> 
> As necessary, please. Moving stuff to Arm-specific files would be preferable.
> 

Sure, I'll add a new CONFIG_STATICMEM to include all related functions and 
variables. Thx

> Jan

Cheers

Penny Zheng

Reply via email to