ioapic.h revision 283927
1261268Sjhb/*- 2283927Sjhb * Copyright (c) 2014 Hudson River Trading LLC 3261268Sjhb * Written by: John H. Baldwin <jhb@FreeBSD.org> 4261268Sjhb * All rights reserved. 5261268Sjhb * 6261268Sjhb * Redistribution and use in source and binary forms, with or without 7261268Sjhb * modification, are permitted provided that the following conditions 8261268Sjhb * are met: 9261268Sjhb * 1. Redistributions of source code must retain the above copyright 10261268Sjhb * notice, this list of conditions and the following disclaimer. 11261268Sjhb * 2. Redistributions in binary form must reproduce the above copyright 12261268Sjhb * notice, this list of conditions and the following disclaimer in the 13261268Sjhb * documentation and/or other materials provided with the distribution. 14261268Sjhb * 15261268Sjhb * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 16261268Sjhb * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 17261268Sjhb * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 18261268Sjhb * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 19261268Sjhb * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20261268Sjhb * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21261268Sjhb * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22261268Sjhb * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23261268Sjhb * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24261268Sjhb * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25261268Sjhb * SUCH DAMAGE. 26261268Sjhb * 27261268Sjhb * $FreeBSD: stable/10/usr.sbin/bhyve/ioapic.h 283927 2015-06-02 19:20:39Z jhb $ 28261268Sjhb */ 29261268Sjhb 30261268Sjhb#ifndef _IOAPIC_H_ 31261268Sjhb#define _IOAPIC_H_ 32261268Sjhb 33261268Sjhb/* 34261268Sjhb * Allocate a PCI IRQ from the I/O APIC. 35261268Sjhb */ 36261268Sjhbvoid ioapic_init(struct vmctx *ctx); 37261268Sjhbint ioapic_pci_alloc_irq(void); 38261268Sjhb 39261268Sjhb#endif 40