• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/arch/s390/kvm/

Lines Matching defs:kvm

21 #include <linux/kvm.h>
31 #include "kvm-s390.h"
137 int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
146 struct kvm *kvm = filp->private_data;
157 r = kvm_s390_inject_vm(kvm, &s390int);
167 struct kvm *kvm_arch_create_vm(void)
169 struct kvm *kvm;
178 kvm = kzalloc(sizeof(struct kvm), GFP_KERNEL);
179 if (!kvm)
182 kvm->arch.sca = (struct sca_block *) get_zeroed_page(GFP_KERNEL);
183 if (!kvm->arch.sca)
186 sprintf(debug_name, "kvm-%u", current->pid);
188 kvm->arch.dbf = debug_register(debug_name, 8, 2, 8 * sizeof(long));
189 if (!kvm->arch.dbf)
192 spin_lock_init(&kvm->arch.float_int.lock);
193 INIT_LIST_HEAD(&kvm->arch.float_int.list);
195 debug_register_view(kvm->arch.dbf, &debug_sprintf_view);
196 VM_EVENT(kvm, 3, "%s", "vm created");
198 return kvm;
200 free_page((unsigned long)(kvm->arch.sca));
202 kfree(kvm);
210 clear_bit(63 - vcpu->vcpu_id, (unsigned long *) &vcpu->kvm->arch.sca->mcn);
211 if (vcpu->kvm->arch.sca->cpu[vcpu->vcpu_id].sda ==
213 vcpu->kvm->arch.sca->cpu[vcpu->vcpu_id].sda = 0;
220 static void kvm_free_vcpus(struct kvm *kvm)
225 kvm_for_each_vcpu(i, vcpu, kvm)
228 mutex_lock(&kvm->lock);
229 for (i = 0; i < atomic_read(&kvm->online_vcpus); i++)
230 kvm->vcpus[i] = NULL;
232 atomic_set(&kvm->online_vcpus, 0);
233 mutex_unlock(&kvm->lock);
236 void kvm_arch_sync_events(struct kvm *kvm)
240 void kvm_arch_destroy_vm(struct kvm *kvm)
242 kvm_free_vcpus(kvm);
243 kvm_free_physmem(kvm);
244 free_page((unsigned long)(kvm->arch.sca));
245 debug_unregister(kvm->arch.dbf);
246 cleanup_srcu_struct(&kvm->srcu);
247 kfree(kvm);
312 struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm,
328 BUG_ON(!kvm->arch.sca);
329 if (!kvm->arch.sca->cpu[id].sda)
330 kvm->arch.sca->cpu[id].sda = (__u64) vcpu->arch.sie_block;
331 vcpu->arch.sie_block->scaoh = (__u32)(((__u64)kvm->arch.sca) >> 32);
332 vcpu->arch.sie_block->scaol = (__u32)(__u64)kvm->arch.sca;
333 set_bit(63 - id, (unsigned long *) &kvm->arch.sca->mcn);
337 vcpu->arch.local_int.float_int = &kvm->arch.float_int;
338 spin_lock(&kvm->arch.float_int.lock);
339 kvm->arch.float_int.local_int[id] = &vcpu->arch.local_int;
342 spin_unlock(&kvm->arch.float_int.lock);
344 rc = kvm_vcpu_init(vcpu, kvm, id);
347 VM_EVENT(kvm, 3, "create cpu %d at %p, sie block at %p", id, vcpu,
361 /* kvm common code refers to this, but never calls it */
504 BUG_ON(vcpu->kvm->arch.float_int.local_int[vcpu->vcpu_id] == NULL);
535 /* intercept cannot be handled in-kernel, prepare kvm-run */
675 int kvm_arch_prepare_memory_region(struct kvm *kvm,
706 void kvm_arch_commit_memory_region(struct kvm *kvm,
715 kvm_for_each_vcpu(i, vcpu, kvm) {
722 void kvm_arch_flush_shadow(struct kvm *kvm)