[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen staging] x86/domain: Drop the only-written smap_check_policy infrastructure
commit b190f0c0c1dff13ce92c5f056a87d6c81d3ee8f9 Author: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> AuthorDate: Tue May 8 13:45:45 2018 +0100 Commit: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> CommitDate: Tue May 8 17:22:57 2018 +0100 x86/domain: Drop the only-written smap_check_policy infrastructure c/s 4c5d78a10d "x86/pagewalk: Re-implement the pagetable walker" dropped the consumer of smap_policy. Looking at c/s 31ae587e6f which introduced the smap_check logic, it exists only to work around a bug in guest_walk_tables() was resolved by the aformentioned commit. Remove the unused variables and associated infrastructure. Reported-by: Jason Andryuk <jandryuk@xxxxxxxxx> Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Reviewed-by: George Dunlap <george.dunlap@xxxxxxxxxx> Reviewed-by: Roger Pau Monné <roger.pau@xxxxxxxxxx> Release-acked-by: Juergen Gross <jgross@xxxxxxxx> --- xen/arch/x86/domain.c | 7 +------ xen/arch/x86/time.c | 3 +-- xen/include/asm-x86/domain.h | 13 ------------- 3 files changed, 2 insertions(+), 21 deletions(-) diff --git a/xen/arch/x86/domain.c b/xen/arch/x86/domain.c index 801ac33810..4ff3d2f3fe 100644 --- a/xen/arch/x86/domain.c +++ b/xen/arch/x86/domain.c @@ -217,13 +217,9 @@ void dump_pageframe_info(struct domain *d) void update_guest_memory_policy(struct vcpu *v, struct guest_memory_policy *policy) { - smap_check_policy_t old_smap_policy = v->arch.smap_check_policy; bool old_guest_mode = nestedhvm_is_n2(v); bool new_guest_mode = policy->nested_guest_mode; - v->arch.smap_check_policy = policy->smap_policy; - policy->smap_policy = old_smap_policy; - /* * When 'v' is in the nested guest mode, all guest copy * functions/macros which finally call paging_gva_to_gfn() @@ -1541,8 +1537,7 @@ void paravirt_ctxt_switch_to(struct vcpu *v) bool update_runstate_area(struct vcpu *v) { bool rc; - struct guest_memory_policy policy = - { .smap_policy = SMAP_CHECK_ENABLED, .nested_guest_mode = false }; + struct guest_memory_policy policy = { .nested_guest_mode = false }; void __user *guest_handle = NULL; if ( guest_handle_is_null(runstate_guest(v)) ) diff --git a/xen/arch/x86/time.c b/xen/arch/x86/time.c index 84c1c0c082..c342d00732 100644 --- a/xen/arch/x86/time.c +++ b/xen/arch/x86/time.c @@ -1106,8 +1106,7 @@ bool update_secondary_system_time(struct vcpu *v, struct vcpu_time_info *u) { XEN_GUEST_HANDLE(vcpu_time_info_t) user_u = v->arch.time_info_guest; - struct guest_memory_policy policy = - { .smap_policy = SMAP_CHECK_ENABLED, .nested_guest_mode = false }; + struct guest_memory_policy policy = { .nested_guest_mode = false }; if ( guest_handle_is_null(user_u) ) return true; diff --git a/xen/include/asm-x86/domain.h b/xen/include/asm-x86/domain.h index 8b66096e7f..197f8d62be 100644 --- a/xen/include/asm-x86/domain.h +++ b/xen/include/asm-x86/domain.h @@ -508,12 +508,6 @@ struct pv_vcpu struct vcpu_time_info pending_system_time; }; -typedef enum __packed { - SMAP_CHECK_HONOR_CPL_AC, /* honor the guest's CPL and AC */ - SMAP_CHECK_ENABLED, /* enable the check */ - SMAP_CHECK_DISABLED, /* disable the check */ -} smap_check_policy_t; - struct arch_vcpu { /* @@ -569,12 +563,6 @@ struct arch_vcpu * and thus should be saved/restored. */ bool_t nonlazy_xstate_used; - /* - * The SMAP check policy when updating runstate_guest(v) and the - * secondary system time. - */ - smap_check_policy_t smap_check_policy; - struct vmce vmce; struct paging_vcpu paging; @@ -595,7 +583,6 @@ struct arch_vcpu struct guest_memory_policy { - smap_check_policy_t smap_policy; bool nested_guest_mode; }; -- generated by git-patchbot for /home/xen/git/xen.git#staging _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |