vmm_dev.c (266393) | vmm_dev.c (267393) |
---|---|
1/*- 2 * Copyright (c) 2011 NetApp, Inc. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * | 1/*- 2 * Copyright (c) 2011 NetApp, Inc. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * |
26 * $FreeBSD: stable/10/sys/amd64/vmm/vmm_dev.c 266393 2014-05-18 04:33:24Z jhb $ | 26 * $FreeBSD: stable/10/sys/amd64/vmm/vmm_dev.c 267393 2014-06-12 13:13:15Z jhb $ |
27 */ 28 29#include <sys/cdefs.h> | 27 */ 28 29#include <sys/cdefs.h> |
30__FBSDID("$FreeBSD: stable/10/sys/amd64/vmm/vmm_dev.c 266393 2014-05-18 04:33:24Z jhb $"); | 30__FBSDID("$FreeBSD: stable/10/sys/amd64/vmm/vmm_dev.c 267393 2014-06-12 13:13:15Z jhb $"); |
31 32#include <sys/param.h> 33#include <sys/kernel.h> 34#include <sys/queue.h> 35#include <sys/lock.h> 36#include <sys/mutex.h> 37#include <sys/malloc.h> 38#include <sys/conf.h> --- 274 unchanged lines hidden (view full) --- 313 case VM_IOAPIC_DEASSERT_IRQ: 314 ioapic_irq = (struct vm_ioapic_irq *)data; 315 error = vioapic_deassert_irq(sc->vm, ioapic_irq->irq); 316 break; 317 case VM_IOAPIC_PULSE_IRQ: 318 ioapic_irq = (struct vm_ioapic_irq *)data; 319 error = vioapic_pulse_irq(sc->vm, ioapic_irq->irq); 320 break; | 31 32#include <sys/param.h> 33#include <sys/kernel.h> 34#include <sys/queue.h> 35#include <sys/lock.h> 36#include <sys/mutex.h> 37#include <sys/malloc.h> 38#include <sys/conf.h> --- 274 unchanged lines hidden (view full) --- 313 case VM_IOAPIC_DEASSERT_IRQ: 314 ioapic_irq = (struct vm_ioapic_irq *)data; 315 error = vioapic_deassert_irq(sc->vm, ioapic_irq->irq); 316 break; 317 case VM_IOAPIC_PULSE_IRQ: 318 ioapic_irq = (struct vm_ioapic_irq *)data; 319 error = vioapic_pulse_irq(sc->vm, ioapic_irq->irq); 320 break; |
321 case VM_IOAPIC_PINCOUNT: 322 *(int *)data = vioapic_pincount(sc->vm); 323 break; |
|
321 case VM_MAP_MEMORY: 322 seg = (struct vm_memory_segment *)data; 323 error = vm_malloc(sc->vm, seg->gpa, seg->len); 324 break; 325 case VM_GET_MEMORY_SEG: 326 seg = (struct vm_memory_segment *)data; 327 seg->len = 0; 328 (void)vm_gpabase2memseg(sc->vm, seg->gpa, seg); --- 242 unchanged lines hidden --- | 324 case VM_MAP_MEMORY: 325 seg = (struct vm_memory_segment *)data; 326 error = vm_malloc(sc->vm, seg->gpa, seg->len); 327 break; 328 case VM_GET_MEMORY_SEG: 329 seg = (struct vm_memory_segment *)data; 330 seg->len = 0; 331 (void)vm_gpabase2memseg(sc->vm, seg->gpa, seg); --- 242 unchanged lines hidden --- |