7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases/*
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * CDDL HEADER START
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases *
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * The contents of this file are subject to the terms of the
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * Common Development and Distribution License (the "License").
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * You may not use this file except in compliance with the License.
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases *
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * or http://www.opensolaris.org/os/licensing.
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * See the License for the specific language governing permissions
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * and limitations under the License.
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases *
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * When distributing Covered Code, include this CDDL HEADER in each
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * If applicable, add the following below this CDDL HEADER, with the
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * fields enclosed by brackets "[]" replaced with your own identifying
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * information: Portions Copyright [yyyy] [name of copyright owner]
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases *
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * CDDL HEADER END
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases */
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases/*
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases */
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#ifndef _APIX_IRM_IMPL_H
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#define _APIX_IRM_IMPL_H
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#include <sys/types.h>
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#include <sys/ddi_intr_impl.h>
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#include <sys/psm_types.h>
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#include <sys/apix.h>
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#ifdef __cplusplus
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayasesextern "C" {
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#endif
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#define APIX_IRM_DEBUG(args) DDI_INTR_IRMDBG(args)
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayasestypedef struct apix_irm_info {
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases int apix_ncpus; /* # of available CPUs (boot time) */
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases int apix_per_cpu_vectors; /* # of available vectors per CPU */
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases int apix_ioapic_max_vectors; /* max # of vectors used by IOAPICs */
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases int apix_vectors_allocated; /* # of vectors (pre) allocated */
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases} apix_irm_info_t;
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayasesextern apix_irm_info_t apix_irminfo;
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayasesextern int apix_system_max_vectors;
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayasesextern int apix_irm_cpu_factor;
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayasesextern ddi_irm_pool_t *apix_irm_pool_p;
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#ifdef __cplusplus
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases}
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#endif
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases
7ff178cd8db129d385d3177eb20744d3b6efc59bJimmy Vetayases#endif /* _APIX_IRM_IMPL_H */