From mboxrd@z Thu Jan 1 00:00:00 1970 From: Razvan Cojocaru Subject: Libxc code to get MTRR memory type for physical address pa Date: Thu, 13 Dec 2012 17:13:33 +0200 Message-ID: <50C9F09D.9080602@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Hello, what would be the libxc-based equivalent of get_mtrr_type(struct mtrr_state *m, paddr_t pa) (from xen/arch/x86/hvm/mtrr.c)? I've searched the source code and found this: struct hvm_hw_mtrr { #define MTRR_VCNT 8 #define NUM_FIXED_MSR 11 uint64_t msr_pat_cr; /* mtrr physbase & physmask msr pair*/ uint64_t msr_mtrr_var[MTRR_VCNT*2]; uint64_t msr_mtrr_fixed[NUM_FIXED_MSR]; uint64_t msr_mtrr_cap; uint64_t msr_mtrr_def_type; }; in xen/include/public/arch-x86/hvm/save.h. I can retrieve that using xc_domain_hvm_getcontext_partial(), but what would the the best way to get the uint8_t result, for a given 'pa', that get_mtrr_type() returns? Thanks, Razvan Cojocaru