1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-02-04 17:15:50 +00:00

There is no need for 'start_emulating()' and 'stop_emulating()' to be defined

in <machine/cpufunc.h> so remove them from there.

Obtained from:	NetApp
This commit is contained in:
Neel Natu 2013-01-04 02:49:12 +00:00
parent 5f0677d392
commit 014a52f3a6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/projects/bhyve/; revision=245021
2 changed files with 2 additions and 19 deletions

View File

@ -705,23 +705,6 @@ intr_disable(void)
return (rflags);
}
#ifndef CR0_TS
/* Defined in <machine/specialreg.h> */
#define CR0_TS 0x00000008
#endif
static __inline void
start_emulating(void)
{
__asm __volatile("smsw %%ax; orb %0,%%al; lmsw %%ax"
: : "n" (CR0_TS) : "ax");
}
static __inline void
stop_emulating(void)
{
__asm __volatile("clts");
}
static __inline void
intr_restore(register_t rflags)
{

View File

@ -145,8 +145,8 @@ static struct vmm_ops *ops;
#define VMSETCAP(vmi, vcpu, num, val) \
(ops != NULL ? (*ops->vmsetcap)(vmi, vcpu, num, val) : ENXIO)
#define fpu_start_emulating() start_emulating()
#define fpu_stop_emulating() stop_emulating()
#define fpu_start_emulating() load_cr0(rcr0() | CR0_TS)
#define fpu_stop_emulating() clts()
static MALLOC_DEFINE(M_VM, "vm", "vm");
CTASSERT(VMM_MSR_NUM <= 64); /* msr_mask can keep track of up to 64 msrs */