Re: [PATCH v4] x86/Hyper-V: Support for free page reporting

2021-03-22 Thread Wei Liu
On Fri, Mar 19, 2021 at 09:30:50PM +, Michael Kelley wrote: > From: Sunil Muthuswamy Sent: Friday, March 19, 2021 > 2:21 PM > > > > > What's the strategy for this flag in the unlikely event that the > > > hypercall fails? > > > It doesn't seem right to have hv_query_ext_cap() fail, but lea

RE: [PATCH v4] x86/Hyper-V: Support for free page reporting

2021-03-19 Thread Michael Kelley
From: Sunil Muthuswamy Sent: Friday, March 19, 2021 2:21 PM > > > What's the strategy for this flag in the unlikely event that the hypercall > > fails? > > It doesn't seem right to have hv_query_ext_cap() fail, but leave the > > static flag set to true. Just move that line down to after the s

RE: [PATCH v4] x86/Hyper-V: Support for free page reporting

2021-03-19 Thread Sunil Muthuswamy
> What's the strategy for this flag in the unlikely event that the hypercall > fails? > It doesn't seem right to have hv_query_ext_cap() fail, but leave the > static flag set to true. Just move that line down to after the status check > has succeeded? That call should not fail in any normal circ

RE: [PATCH v4] x86/Hyper-V: Support for free page reporting

2021-03-19 Thread Michael Kelley
From: Sunil Muthuswamy Sent: Thursday, March 18, 2021 1:14 PM > > Linux has support for free page reporting now (36e66c554b5c) for > virtualized environment. On Hyper-V when virtually backed VMs are > configured, Hyper-V will advertise cold memory discard capability, > when supported. This patch

[PATCH v4] x86/Hyper-V: Support for free page reporting

2021-03-18 Thread Sunil Muthuswamy
Linux has support for free page reporting now (36e66c554b5c) for virtualized environment. On Hyper-V when virtually backed VMs are configured, Hyper-V will advertise cold memory discard capability, when supported. This patch adds the support to hook into the free page reporting infrastructure and l