blob: f23b90b02898a4474e55bcc2582516da7272977e [file] [log] [blame]
Greg Kroah-Hartmanb2441312017-11-01 15:07:57 +01001/* SPDX-License-Identifier: GPL-2.0 */
Ingo Molnar102d8322007-02-19 14:37:47 +02002#ifndef __LINUX_KVM_PARA_H
3#define __LINUX_KVM_PARA_H
4
David Howells607ca462012-10-13 10:46:48 +01005#include <uapi/linux/kvm_para.h>
Anthony Liguori7aa81cc2007-09-17 14:57:50 -05006
Marcelo Tosatti0cf1bfd2008-02-22 12:21:36 -05007
Yaowei Bai08ff0d52015-11-14 11:21:07 +08008static inline bool kvm_para_has_feature(unsigned int feature)
Anthony Liguori7aa81cc2007-09-17 14:57:50 -05009{
Yaowei Bai08ff0d52015-11-14 11:21:07 +080010 return !!(kvm_arch_para_features() & (1UL << feature));
Anthony Liguori7aa81cc2007-09-17 14:57:50 -050011}
Wanpeng Lia4429e52018-02-13 09:05:40 +080012
13static inline bool kvm_para_has_hint(unsigned int feature)
14{
15 return !!(kvm_arch_para_hints() & (1UL << feature));
16}
Christian Borntraeger5f432382007-10-11 15:34:17 +020017#endif /* __LINUX_KVM_PARA_H */