[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 01/12] x86/p2m: set_{foreign,mmio}_p2m_entry() are HVM-only



On 29.04.2021 15:17, Roger Pau Monné wrote:
> On Mon, Apr 12, 2021 at 04:05:41PM +0200, Jan Beulich wrote:
>> Extend a respective #ifdef from inside set_typed_p2m_entry() to around
>> all three functions. Add ASSERT_UNREACHABLE() to the latter one's safety
>> check path.
> 
> Wouldn't it be better to also move the prototypes in p2m.h into a
> CONFIG_HVM guarded region, so that it fails at compile time rather
> than link time?

In the header I'm fearing this ending up as spaghetti more than in
the .c file. I think where possible we may want to do so once we
have a clear / clean set of APIs which are generic vs such which
are HVM-specific (which I expect to be the case once p2m.c as a
whole becomes HVM-only).

Jan



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.