// SPDX-License-Identifier: GPL-2.0-only /* * vMTRR implementation * * Copyright (C) 2006 Qumranet, Inc. * Copyright 2010 Red Hat, Inc. and/or its affiliates. * Copyright(C) 2015 Intel Corporation. * * Authors: * Yaniv Kamay <[email protected]> * Avi Kivity <[email protected]> * Marcelo Tosatti <[email protected]> * Paolo Bonzini <[email protected]> * Xiao Guangrong <[email protected]> */ #define pr_fmt(fmt) … #include <linux/kvm_host.h> #include <asm/mtrr.h> #include "cpuid.h" static u64 *find_mtrr(struct kvm_vcpu *vcpu, unsigned int msr) { … } static bool valid_mtrr_type(unsigned t) { … } static bool kvm_mtrr_valid(struct kvm_vcpu *vcpu, u32 msr, u64 data) { … } int kvm_mtrr_set_msr(struct kvm_vcpu *vcpu, u32 msr, u64 data) { … } int kvm_mtrr_get_msr(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata) { … }