Date: Tue, 12 Mar 2013 13:13:01 +0000 (UTC) From: "Cherry G. Mathew" <cherry@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r248203 - in projects/amd64_xen_pv/sys/amd64: include/xen xen Message-ID: <201303121313.r2CDD1jT087169@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: cherry Date: Tue Mar 12 13:13:00 2013 New Revision: 248203 URL: http://svnweb.freebsd.org/changeset/base/248203 Log: Add a function to set a descriptor entry within a descriptor table. Approved by: gibbs (implicit) Modified: projects/amd64_xen_pv/sys/amd64/include/xen/xenpmap.h projects/amd64_xen_pv/sys/amd64/xen/mm.c Modified: projects/amd64_xen_pv/sys/amd64/include/xen/xenpmap.h ============================================================================== --- projects/amd64_xen_pv/sys/amd64/include/xen/xenpmap.h Tue Mar 12 13:10:51 2013 (r248202) +++ projects/amd64_xen_pv/sys/amd64/include/xen/xenpmap.h Tue Mar 12 13:13:00 2013 (r248203) @@ -34,10 +34,13 @@ #ifndef _XEN_XENPMAP_H_ #define _XEN_XENPMAP_H_ +struct segment_descriptor; /* Forward declaration */ + void _xen_queue_pt_update(vm_paddr_t, vm_paddr_t, char *, int); void xen_pt_switch(vm_paddr_t); void xen_pt_user_switch(vm_paddr_t); void xen_set_ldt(vm_paddr_t, unsigned long); +void xen_set_descriptor(vm_paddr_t, uint64_t *); void xen_pgdir_pin(vm_paddr_t); void xen_pgdir_unpin(vm_paddr_t); void xen_pgdpt_pin(vm_paddr_t); Modified: projects/amd64_xen_pv/sys/amd64/xen/mm.c ============================================================================== --- projects/amd64_xen_pv/sys/amd64/xen/mm.c Tue Mar 12 13:10:51 2013 (r248202) +++ projects/amd64_xen_pv/sys/amd64/xen/mm.c Tue Mar 12 13:13:00 2013 (r248203) @@ -329,6 +329,12 @@ xen_set_ldt(vm_paddr_t ptr, unsigned lon PANIC_IF(HYPERVISOR_mmuext_op(&op, 1, NULL, DOMID_SELF) < 0); } +void +xen_set_descriptor(vm_paddr_t dte_ma, uint64_t *dte_ptr) +{ + PANIC_IF(HYPERVISOR_update_descriptor(dte_ma, *dte_ptr) < 0); +} + void xen_tlb_flush(void) { struct mmuext_op op;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201303121313.r2CDD1jT087169>