mshv.h 775 B

12345678910111213141516171819202122232425262728
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * Copyright (c) 2023, Microsoft Corporation.
  4. */
  5. #ifndef _MSHV_H_
  6. #define _MSHV_H_
  7. #include <linux/stddef.h>
  8. #include <linux/string.h>
  9. #include <hyperv/hvhdk.h>
  10. #define mshv_field_nonzero(STRUCT, MEMBER) \
  11. memchr_inv(&((STRUCT).MEMBER), \
  12. 0, sizeof_field(typeof(STRUCT), MEMBER))
  13. int hv_call_get_vp_registers(u32 vp_index, u64 partition_id, u16 count,
  14. union hv_input_vtl input_vtl,
  15. struct hv_register_assoc *registers);
  16. int hv_call_set_vp_registers(u32 vp_index, u64 partition_id, u16 count,
  17. union hv_input_vtl input_vtl,
  18. struct hv_register_assoc *registers);
  19. int hv_call_get_partition_property(u64 partition_id, u64 property_code,
  20. u64 *property_value);
  21. #endif /* _MSHV_H */