Move p2m_mem_access_sanity_check() from the asm-x86/mem_access.h
header, where it currently is declared inline, to
arch/x86/mm/mem_access.c. This allows source code that includes it
directly, or indirectly (such as xen/mem_access.h), to not worry
about also including sched.h for is_hvm_domain(). Including
xen/mem_access.h is useful for code wanting to use p2m_access_t.
Signed-off-by: Razvan Cojocaru <rcojocaru@bitdefender.com>
Acked-by: Tamas K Lengyel <tamas@tklengyel.com>
#endif
}
+bool p2m_mem_access_sanity_check(struct domain *d)
+{
+ return is_hvm_domain(d) && cpu_has_vmx && hap_enabled(d);
+}
+
/*
* Local variables:
* mode: C
const vm_event_response_t *rsp);
/* Sanity check for mem_access hardware support */
-static inline bool p2m_mem_access_sanity_check(struct domain *d)
-{
- return is_hvm_domain(d) && cpu_has_vmx && hap_enabled(d);
-}
+bool p2m_mem_access_sanity_check(struct domain *d);
#endif /*__ASM_X86_MEM_ACCESS_H__ */