Home
last modified time | relevance | path

Searched refs:vm (Results 1 – 25 of 144) sorted by relevance

123456

/illumos-gate/usr/src/uts/intel/io/vmm/sys/
H A Dvmm_kernel.h55 struct vm;
81 typedef void * (*vmi_init_func_t)(struct vm *vm);
139 int vm_create(uint64_t flags, struct vm **retvm);
140 void vm_destroy(struct vm *vm);
141 int vm_reinit(struct vm *vm, uint64_t);
142 uint16_t vm_get_maxcpus(struct vm *vm);
143 void vm_get_topology(struct vm *vm, uint16_t *sockets, uint16_t *cores,
145 int vm_set_topology(struct vm *vm, uint16_t sockets, uint16_t cores,
148 int vm_pause_instance(struct vm *);
149 int vm_resume_instance(struct vm *);
[all …]
H A Dvmm_instruction_emul.h68 void vie_cs_info(const struct vie *vie, struct vm *vm, int vcpuid,
74 int vie_emulate_mmio(struct vie *vie, struct vm *vm, int vcpuid);
75 int vie_emulate_inout(struct vie *vie, struct vm *vm, int vcpuid);
76 int vie_emulate_other(struct vie *vie, struct vm *vm, int vcpuid);
83 int vie_fetch_instruction(struct vie *vie, struct vm *vm, int cpuid,
94 int vm_gla2gpa(struct vm *vm, int vcpuid, struct vm_guest_paging *paging,
101 int vm_gla2gpa_nofault(struct vm *vm, int vcpuid,
105 int vie_verify_gla(struct vie *vie, struct vm *vm, int cpuid, uint64_t gla);
118 int vie_decode_instruction(struct vie *vie, struct vm *vm, int cpuid, int csd);
/illumos-gate/usr/src/common/ficl/
H A Dprimitives.c70 markBranch(ficlDictionary *dictionary, ficlVm *vm, char *tag) in markBranch() argument
72 ficlStackPushPointer(vm->dataStack, dictionary->here); in markBranch()
73 ficlStackPushPointer(vm->dataStack, tag); in markBranch()
77 markControlTag(ficlVm *vm, char *tag) in markControlTag() argument
79 ficlStackPushPointer(vm->dataStack, tag); in markControlTag()
83 matchControlTag(ficlVm *vm, char *wantTag) in matchControlTag() argument
87 FICL_STACK_CHECK(vm->dataStack, 1, 0); in matchControlTag()
89 tag = (char *)ficlStackPopPointer(vm->dataStack); in matchControlTag()
96 ficlVmThrowError(vm, in matchControlTag()
107 resolveBackBranch(ficlDictionary *dictionary, ficlVm *vm, char *tag) in resolveBackBranch() argument
[all …]
H A Dtools.c62 static void ficlPrimitiveStepIn(ficlVm *vm);
63 static void ficlPrimitiveStepOver(ficlVm *vm);
64 static void ficlPrimitiveStepBreak(ficlVm *vm);
93 ficlVmSetBreak(ficlVm *vm, ficlBreakpoint *pBP) in ficlVmSetBreak() argument
95 ficlWord *pStep = ficlSystemLookup(vm->callback.system, "step-break"); in ficlVmSetBreak()
96 FICL_VM_ASSERT(vm, pStep); in ficlVmSetBreak()
98 pBP->address = vm->ip; in ficlVmSetBreak()
99 pBP->oldXT = *vm->ip; in ficlVmSetBreak()
100 *vm->ip = pStep; in ficlVmSetBreak()
138 ficlPrimitiveHashSummary(ficlVm *vm) in ficlPrimitiveHashSummary() argument
[all …]
H A Dfileaccess.c12 pushIor(ficlVm *vm, int success) in pushIor() argument
19 ficlStackPushInteger(vm->dataStack, ior); in pushIor()
24 ficlFileOpen(ficlVm *vm, char *writeMode) in ficlFileOpen() argument
26 int fam = ficlStackPopInteger(vm->dataStack); in ficlFileOpen()
27 int length = ficlStackPopInteger(vm->dataStack); in ficlFileOpen()
28 void *address = (void *)ficlStackPopPointer(vm->dataStack); in ficlFileOpen()
39 ficlStackPushPointer(vm->dataStack, NULL); in ficlFileOpen()
40 ficlStackPushInteger(vm->dataStack, EINVAL); in ficlFileOpen()
58 ficlStackPushPointer(vm->dataStack, NULL); in ficlFileOpen()
63 ficlStackPushPointer(vm->dataStack, ff); in ficlFileOpen()
[all …]
H A Dsearch.c56 ficlPrimitiveDefinitions(ficlVm *vm) in ficlPrimitiveDefinitions() argument
58 ficlDictionary *dictionary = ficlVmGetDictionary(vm); in ficlPrimitiveDefinitions()
60 FICL_VM_ASSERT(vm, dictionary); in ficlPrimitiveDefinitions()
62 ficlVmThrowError(vm, "DEFINITIONS error - empty search order"); in ficlPrimitiveDefinitions()
77 ficlPrimitiveForthWordlist(ficlVm *vm) in ficlPrimitiveForthWordlist() argument
79 ficlHash *hash = ficlVmGetDictionary(vm)->forthWordlist; in ficlPrimitiveForthWordlist()
80 ficlStackPushPointer(vm->dataStack, hash); in ficlPrimitiveForthWordlist()
90 ficlPrimitiveGetCurrent(ficlVm *vm) in ficlPrimitiveGetCurrent() argument
92 ficlDictionary *dictionary = ficlVmGetDictionary(vm); in ficlPrimitiveGetCurrent()
94 ficlStackPushPointer(vm->dataStack, dictionary->compilationWordlist); in ficlPrimitiveGetCurrent()
[all …]
H A Dvm.c57 #define FICL_VM_CHECK(vm) \ argument
58 FICL_VM_ASSERT(vm, (*(vm->ip - 1)) == vm->runningWord)
60 #define FICL_VM_CHECK(vm) argument
67 ficlVmBranchRelative(ficlVm *vm, int offset) in ficlVmBranchRelative() argument
69 vm->ip += offset; in ficlVmBranchRelative()
79 ficlVmCreate(ficlVm *vm, unsigned nPStack, unsigned nRStack) in ficlVmCreate() argument
81 if (vm == NULL) { in ficlVmCreate()
82 vm = (ficlVm *)ficlMalloc(sizeof (ficlVm)); in ficlVmCreate()
83 FICL_ASSERT(NULL, vm); in ficlVmCreate()
84 memset(vm, 0, sizeof (ficlVm)); in ficlVmCreate()
[all …]
H A Dextras.c15 ficlPrimitiveSystem(ficlVm *vm) in ficlPrimitiveSystem() argument
17 ficlCountedString *counted = (ficlCountedString *)vm->pad; in ficlPrimitiveSystem()
19 (void) ficlVmGetString(vm, counted, '\n'); in ficlPrimitiveSystem()
24 (void) sprintf(vm->pad, "System call returned %d\n", in ficlPrimitiveSystem()
26 ficlVmTextOut(vm, vm->pad); in ficlPrimitiveSystem()
27 ficlVmThrow(vm, FICL_VM_STATUS_QUIT); in ficlPrimitiveSystem()
30 ficlVmTextOut(vm, "Warning (system): nothing happened\n"); in ficlPrimitiveSystem()
43 ficlPrimitiveLoad(ficlVm *vm) in ficlPrimitiveLoad() argument
54 (void) ficlVmGetString(vm, counted, '\n'); in ficlPrimitiveLoad()
57 ficlVmTextOut(vm, "Warning (load): nothing happened\n"); in ficlPrimitiveLoad()
[all …]
H A Dfloat.c56 ficlPrimitiveFConstant(ficlVm *vm) in ficlPrimitiveFConstant() argument
58 ficlDictionary *dictionary = ficlVmGetDictionary(vm); in ficlPrimitiveFConstant()
59 ficlString name = ficlVmGetWord(vm); in ficlPrimitiveFConstant()
61 FICL_STACK_CHECK(vm->floatStack, 1, 0); in ficlPrimitiveFConstant()
65 ficlDictionaryAppendCell(dictionary, ficlStackPop(vm->floatStack)); in ficlPrimitiveFConstant()
94 ficlPrimitiveF2Constant(ficlVm *vm) in ficlPrimitiveF2Constant() argument
96 ficlDictionary *dictionary = ficlVmGetDictionary(vm); in ficlPrimitiveF2Constant()
97 ficlString name = ficlVmGetWord(vm); in ficlPrimitiveF2Constant()
99 FICL_STACK_CHECK(vm->floatStack, 2, 0); in ficlPrimitiveF2Constant()
103 ficlDictionaryAppendCell(dictionary, ficlStackPop(vm->floatStack)); in ficlPrimitiveF2Constant()
[all …]
H A Dficl.h864 ficlVm *vm; /* used for debugging */ member
873 ficlStackCreate(ficlVm *vm, char *name, unsigned nCells);
929 typedef void (*ficlPrimitive)(ficlVm *vm);
948 ficlVm *vm; member
960 (*ficlCompatibilityOutputFunction)(ficlVm *vm, char *text, int newline);
1054 FICL_PLATFORM_EXTERN void ficlVmBranchRelative(ficlVm *vm, int offset);
1056 ficlVmCreate(ficlVm *vm, unsigned nPStack, unsigned nRStack);
1057 FICL_PLATFORM_EXTERN void ficlVmDestroy(ficlVm *vm);
1058 FICL_PLATFORM_EXTERN ficlDictionary *ficlVmGetDictionary(ficlVm *vm);
1060 ficlVmGetString(ficlVm *vm, ficlCountedString *spDest, char delimiter);
[all …]
/illumos-gate/usr/src/uts/intel/io/vmm/
H A Dvmm.c99 struct vm *vtc_vm;
194 struct vm { struct
275 #define VMINIT(vm) ((*ops->vminit)(vm)) argument
308 static void vm_free_memmap(struct vm *vm, int ident);
309 static bool sysmem_mapping(struct vm *vm, struct mem_map *mm);
311 static bool vcpu_sleep_bailout_checks(struct vm *vm, int vcpuid);
312 static int vcpu_vector_sipi(struct vm *vm, int vcpuid, uint8_t vector);
313 static bool vm_is_suspended(struct vm *, struct vm_exit *);
354 vcpu_cleanup(struct vm *vm, int i, bool destroy) in vcpu_cleanup() argument
356 struct vcpu *vcpu = &vm->vcpu[i]; in vcpu_cleanup()
[all …]
H A Dvmm_lapic.h44 struct vm;
47 int lapic_rdmsr(struct vm *vm, int cpu, uint_t msr, uint64_t *rval);
48 int lapic_wrmsr(struct vm *vm, int cpu, uint_t msr, uint64_t wval);
50 int lapic_mmio_read(struct vm *vm, int cpu, uint64_t gpa, uint64_t *rval,
52 int lapic_mmio_write(struct vm *vm, int cpu, uint64_t gpa, uint64_t wval,
59 int lapic_set_intr(struct vm *vm, int cpu, int vector, bool trig);
64 lapic_intr_level(struct vm *vm, int cpu, int vector) in lapic_intr_level() argument
67 return (lapic_set_intr(vm, cpu, vector, LAPIC_TRIG_LEVEL)); in lapic_intr_level()
71 lapic_intr_edge(struct vm *vm, int cpu, int vector) in lapic_intr_edge() argument
74 return (lapic_set_intr(vm, cpu, vector, LAPIC_TRIG_EDGE)); in lapic_intr_edge()
[all …]
H A Dvmm_instruction_emul.c470 static int vie_mmio_read(struct vie *vie, struct vm *vm, int cpuid,
472 static int vie_mmio_write(struct vie *vie, struct vm *vm, int cpuid,
536 vie_read_bytereg(struct vie *vie, struct vm *vm, int vcpuid, uint8_t *rval) in vie_read_bytereg() argument
543 error = vm_get_register(vm, vcpuid, reg, &val); in vie_read_bytereg()
557 vie_write_bytereg(struct vie *vie, struct vm *vm, int vcpuid, uint8_t byte) in vie_write_bytereg() argument
564 error = vm_get_register(vm, vcpuid, reg, &origval); in vie_write_bytereg()
577 error = vm_set_register(vm, vcpuid, reg, val); in vie_write_bytereg()
583 vie_update_register(struct vm *vm, int vcpuid, enum vm_reg_name reg, in vie_update_register() argument
592 error = vm_get_register(vm, vcpuid, reg, &origval); in vie_update_register()
607 error = vm_set_register(vm, vcpuid, reg, val); in vie_update_register()
[all …]
/illumos-gate/usr/src/uts/intel/io/vmm/io/
H A Dppt.h32 void ppt_unassign_all(struct vm *vm);
33 int ppt_map_mmio(struct vm *vm, int pptfd, vm_paddr_t gpa, size_t len,
35 int ppt_unmap_mmio(struct vm *vm, int pptfd, vm_paddr_t gpa, size_t len);
36 int ppt_setup_msi(struct vm *vm, int vcpu, int pptfd, uint64_t addr,
38 int ppt_setup_msix(struct vm *vm, int vcpu, int pptfd, int idx, uint64_t addr,
40 int ppt_disable_msix(struct vm *vm, int pptfd);
41 int ppt_assigned_devices(struct vm *vm);
42 boolean_t ppt_is_mmio(struct vm *vm, vm_paddr_t gpa);
43 int ppt_get_limits(struct vm *vm, int pptfd, int *msilimit, int *msixlimit);
49 int ppt_assign_device(struct vm *vm, int pptfd);
[all …]
H A Dvioapic.h48 struct vioapic *vioapic_init(struct vm *vm);
51 int vioapic_assert_irq(struct vm *vm, int irq);
52 int vioapic_deassert_irq(struct vm *vm, int irq);
53 int vioapic_pulse_irq(struct vm *vm, int irq);
55 int vioapic_mmio_write(struct vm *vm, int vcpuid, uint64_t gpa, uint64_t wval,
57 int vioapic_mmio_read(struct vm *vm, int vcpuid, uint64_t gpa, uint64_t *rval,
60 int vioapic_pincount(struct vm *vm);
61 void vioapic_process_eoi(struct vm *vm, int vcpuid, int vector);
H A Dvatpic.h37 struct vatpic *vatpic_init(struct vm *vm);
47 int vatpic_assert_irq(struct vm *vm, int irq);
48 int vatpic_deassert_irq(struct vm *vm, int irq);
49 int vatpic_pulse_irq(struct vm *vm, int irq);
50 int vatpic_set_irq_trigger(struct vm *vm, int irq,
53 void vatpic_pending_intr(struct vm *vm, int *vecptr);
54 void vatpic_intr_accepted(struct vm *vm, int vector);
/illumos-gate/usr/src/contrib/ast/src/lib/libast/vmalloc/
H A Dvmdebug.c81 static void vmdbwarn(Vmalloc_t* vm, char* mesg, int n) in vmdbwarn() argument
83 static void vmdbwarn(vm, mesg, n) in vmdbwarn()
84 Vmalloc_t* vm; in vmdbwarn()
89 reg Vmdata_t* vd = vm->data;
98 static void dbwarn(Vmalloc_t* vm, Void_t* data, int where, in dbwarn() argument
101 static void dbwarn(vm, data, where, file, line, func, type) in dbwarn()
102 Vmalloc_t* vm; /* region holding the block */ in dbwarn()
132 bufp = (*_Vmstrcpy)(bufp, (*_Vmitoa)(VLONG(vm), 0), ':');
182 vmdbwarn(vm,buf,(int)(bufp-buf));
187 static void dbwatch(Vmalloc_t* vm, Void_t* data, in dbwatch() argument
[all …]
H A Dvmpool.c42 static Void_t* poolalloc(Vmalloc_t* vm, reg size_t size, int local) in poolalloc() argument
44 static Void_t* poolalloc(vm, size, local ) in poolalloc()
45 Vmalloc_t* vm; in poolalloc()
53 reg Vmdata_t *vd = vm->data;
64 SETLOCK(vm, local);
80 if((tp = (*_Vmextend)(vm,ROUND(size,vd->incr),NIL(Vmsearch_f))) )
106 (*_Vmtrace)(vm,NIL(Vmuchar_t*),(Vmuchar_t*)tp,vd->pool,0);
108 CLRLOCK(vm, local);
114 static long pooladdr(Vmalloc_t* vm, reg Void_t* addr, int local) in pooladdr() argument
116 static long pooladdr(vm, addr, local) in pooladdr()
[all …]
H A Dvmprofile.c36 #define PFVM(pf) ((pf)->data.data.vm)
54 Vmalloc_t* vm; /* region alloc from */ member
76 static Pfobj_t* pfsearch(Vmalloc_t* vm, char* file, int line) in pfsearch() argument
78 static Pfobj_t* pfsearch(vm, file, line) in pfsearch()
79 Vmalloc_t* vm; /* region allocating from */ in pfsearch()
101 h = line + (((Vmulong_t)vm)>>4);
106 if(PFLINE(pf) == line && PFVM(pf) == vm && strcmp(PFFILE(pf),file) == 0)
137 if(vm >= PFVM(pfvm))
139 if(!pfvm || PFVM(pfvm) > vm)
153 PFVM(pfvm) = vm;
[all …]
H A Dvmwalk.c36 int vmwalk(Vmalloc_t* vm, int(*segf)(Vmalloc_t*, Void_t*, size_t, Vmdisc_t*, Void_t*), Void_t* hand… in vmwalk() argument
38 int vmwalk(vm, segf, handle) in vmwalk()
39 Vmalloc_t* vm; in vmwalk()
47 if(!vm)
49 for(vm = Vmheap; vm; vm = vm->next)
50 { SETLOCK(vm, 0);
51 for(seg = vm->data->seg; seg; seg = seg->next)
52 if((rv = (*segf)(vm, seg->addr, seg->extent, vm->disc, handle)) < 0 )
54 CLRLOCK(vm, 0);
59 { SETLOCK(vm, 0);
[all …]
H A Dvmlast.c36 static Void_t* lastalloc(Vmalloc_t* vm, size_t size, int local) in lastalloc() argument
38 static Void_t* lastalloc(vm, size, local) in lastalloc()
39 Vmalloc_t* vm; in lastalloc()
47 Vmdata_t *vd = vm->data;
50 SETLOCK(vm, local);
65 if((tp = (*_Vmextend)(vm,size,NIL(Vmsearch_f))) )
83 (*_Vmtrace)(vm, NIL(Vmuchar_t*), (Vmuchar_t*)tp, orgsize, 0);
86 CLRLOCK(vm, local);
92 static int lastfree(Vmalloc_t* vm, reg Void_t* data, int local ) in lastfree() argument
94 static int lastfree(vm, data, local) in lastfree()
[all …]
H A Dvmprivate.c40 static Block_t* _vmextend(reg Vmalloc_t* vm, size_t size, Vmsearch_f searchf ) in _vmextend() argument
42 static Block_t* _vmextend(vm, size, searchf ) in _vmextend()
43 reg Vmalloc_t* vm; /* region to increase in size */ in _vmextend()
52 reg Vmdata_t* vd = vm->data;
67 if(size > 2*vd->incr && vm->disc->round < vd->incr)
73 { addr = (Vmuchar_t*)(*vm->disc->memoryf)(vm,seg->addr,seg->extent,
74 seg->extent+size,vm->disc);
81 { if(!(addr = (Vmuchar_t*)(*vm->disc->memoryf)(vm, NIL(Void_t*), 0, size, vm->disc)) )
82 { if(vm->disc->exceptf) /* announce that no more memory is available */
84 CLRLOCK(vm, 0);
[all …]
H A Dvmclose.c35 int vmclose(Vmalloc_t* vm) in vmclose() argument
37 int vmclose(vm) in vmclose()
38 Vmalloc_t* vm; in vmclose()
43 Vmdata_t* vd = vm->data;
44 Vmdisc_t* disc = vm->disc;
47 if(vm == Vmheap) /* the heap is never freed */
50 if(vm->disc->exceptf && /* announcing closing event */
51 (rv = (*vm->disc->exceptf)(vm,VM_CLOSE,(Void_t*)1,vm->disc)) < 0 )
57 (*_Vmpfclose)(vm);
62 { if(v == vm)
[all …]
H A Dmalloc.c378 Vmalloc_t *vm; in clrfreelist() local
388 if(vm = regionof((Void_t*)list)) in clrfreelist()
389 { if(asocasint(&vm->data->lock, 0, 1) == 0) /* can free this now */ in clrfreelist()
390 { (void)(*vm->meth.freef)(vm, (Void_t*)list, 1); in clrfreelist()
391 vm->data->lock = 0; in clrfreelist()
404 static int regexcept(Vmalloc_t* vm, int type, Void_t* data, Vmdisc_t* disc) in regexcept() argument
416 Vmalloc_t *vm; in getregion() local
464 if((vm = vmopen(&Regdisc.disc, Vmbest, VM_SHARE)) != NIL(Vmalloc_t*) ) in getregion()
465 { vm->data->lock = 1; /* lock new region now */ in getregion()
468 return (Region[p] = vm); in getregion()
[all …]
/illumos-gate/usr/src/contrib/ast/src/lib/libast/include/
H A Dvmalloc.h210 #define _VM_(vm) ((Vmalloc_t*)(vm)) argument
216 #define _VMFILE_(vm) (_VM_(vm)->file = (char*)__FILE__) argument
218 #define _VMFILE_(vm) (_VM_(vm)->file = (char*)0)
222 #define _VMLINE_(vm) (_VM_(vm)->line = __LINE__) argument
224 #define _VMLINE_(vm) (_VM_(vm)->line = 0)
228 #define _VMFUNC_(vm) (_VM_(vm)->func = (char*)__FUNCTION__) argument
230 #define _VMFUNC_(vm) (_VM_(vm)->func = (char*)0)
233 #define _VMFL_(vm) (_VMFILE_(vm), _VMLINE_(vm), _VMFUNC_(vm)) argument
235 #define vmalloc(vm,sz) (_VMFL_(vm), \ argument
236 (*(_VM_(vm)->meth.allocf))((vm),(sz),0) )
[all …]

123456