From 7f938e1fb13464f6b279b2fa40f44852d6c86359 Mon Sep 17 00:00:00 2001 From: Andrin Bertschi Date: Fri, 19 Apr 2024 17:18:07 +0200 Subject: [PATCH] heckler: update sev-step user lib build --- userspace/sev-step/README.md | 6 ++++++ userspace/sev-step/sev-step-lib/sev_step_api.h | 10 +++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/userspace/sev-step/README.md b/userspace/sev-step/README.md index a973dd1..1a56680 100644 --- a/userspace/sev-step/README.md +++ b/userspace/sev-step/README.md @@ -9,6 +9,12 @@ make Ensure to have built heckler host kernel first. +``` +# Export kernel header files +cd ../../linux/host +make headers +``` + ### Credits This directory contains code snippets of sev-step, released under GPLv2. https://github.com/sev-step/sev-step-userland/ \ No newline at end of file diff --git a/userspace/sev-step/sev-step-lib/sev_step_api.h b/userspace/sev-step/sev-step-lib/sev_step_api.h index 6f580ec..e98f2f4 100644 --- a/userspace/sev-step/sev-step-lib/sev_step_api.h +++ b/userspace/sev-step/sev-step-lib/sev_step_api.h @@ -12,12 +12,20 @@ #define _SEV_STEP_API_H #include "linux/kvm.h" -#include "linux/sev-step/sev-step.h" +#include "linux/heckler/sev-step.h" #include #include +enum kvm_page_track_mode { + KVM_PAGE_TRACK_WRITE, + KVM_PAGE_TRACK_EXEC, // heckler: mark as nx + KVM_PAGE_TRACK_RESET_EXEC, // mark as !nx (not used for page track) + KVM_PAGE_TRACK_MAX, +}; + + #include "sev_step_error_codes.h" char* descriptive_perf_name(perf_ctl_config_t cfg);