Re: [Xen-devel] [PATCH v4 1/2] xen: replace complicated tlbflush check with an inline function

2016-09-15 Thread Jan Beulich
>>> On 15.09.16 at 08:47, wrote: >> > I rewrite the inline function in xen/include/xen/mm.h to: >> > >> > +#include >> > + >> > +static inline bool accumulate_tlbflush(bool need_tlbflush, >> > + const struct page_info *page, >> > +

Re: [Xen-devel] [PATCH v4 1/2] xen: replace complicated tlbflush check with an inline function

2016-09-15 Thread Dongli Zhang
> > I rewrite the inline function in xen/include/xen/mm.h to: > > > > +#include > > + > > +static inline bool accumulate_tlbflush(bool need_tlbflush, > > + const struct page_info *page, > > + uint32_t tlbflush_timestamp)

Re: [Xen-devel] [PATCH v4 1/2] xen: replace complicated tlbflush check with an inline function

2016-09-15 Thread Jan Beulich
>>> On 15.09.16 at 00:36, wrote: >> I don't think you should pass this into the function ... >> >> > +{ >> > +return page->u.free.need_tlbflush && >> > + page->tlbflush_timestamp <= tlbflush_current_time && >> >> ... and use tlbflush_current_time() here

Re: [Xen-devel] [PATCH v4 1/2] xen: replace complicated tlbflush check with an inline function

2016-09-14 Thread Dongli Zhang
> I don't think you should pass this into the function ... > > > +{ > > +return page->u.free.need_tlbflush && > > + page->tlbflush_timestamp <= tlbflush_current_time && > > ... and use tlbflush_current_time() here instead. I rewrite the inline function in xen/include/xen/mm.h to:

Re: [Xen-devel] [PATCH v4 1/2] xen: replace complicated tlbflush check with an inline function

2016-09-14 Thread Jan Beulich
>>> On 12.09.16 at 10:16, wrote: > This patch cleaned up the code by replacing complicated tlbflush check with > an inline function. We should use this inline function to avoid the long > and complicated to read tlbflush check when implementing TODOs left in > commit