10Sstevel@tonic-gate /* 20Sstevel@tonic-gate * CDDL HEADER START 30Sstevel@tonic-gate * 40Sstevel@tonic-gate * The contents of this file are subject to the terms of the 53249Sgovinda * Common Development and Distribution License (the "License"). 63249Sgovinda * You may not use this file except in compliance with the License. 70Sstevel@tonic-gate * 80Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 90Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 100Sstevel@tonic-gate * See the License for the specific language governing permissions 110Sstevel@tonic-gate * and limitations under the License. 120Sstevel@tonic-gate * 130Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 140Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 150Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 160Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 170Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 180Sstevel@tonic-gate * 190Sstevel@tonic-gate * CDDL HEADER END 200Sstevel@tonic-gate */ 21881Sjohnny 220Sstevel@tonic-gate /* 23*10923SEvan.Yan@Sun.COM * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 24881Sjohnny * Use is subject to license terms. 250Sstevel@tonic-gate */ 260Sstevel@tonic-gate 270Sstevel@tonic-gate #ifndef _SYS_HOTPLUG_PCI_PCICFG_H 280Sstevel@tonic-gate #define _SYS_HOTPLUG_PCI_PCICFG_H 290Sstevel@tonic-gate 300Sstevel@tonic-gate #ifdef __cplusplus 310Sstevel@tonic-gate extern "C" { 320Sstevel@tonic-gate #endif 330Sstevel@tonic-gate 34*10923SEvan.Yan@Sun.COM typedef enum pcicfg_flags { 35*10923SEvan.Yan@Sun.COM /* No probing; used in case of virtual hotplug */ 36*10923SEvan.Yan@Sun.COM PCICFG_FLAG_READ_ONLY = 0x1, 37*10923SEvan.Yan@Sun.COM /* Enable ARI; used in case of boot case */ 38*10923SEvan.Yan@Sun.COM PCICFG_FLAG_ENABLE_ARI = 0x2 39*10923SEvan.Yan@Sun.COM } pcicfg_flags_t; 40*10923SEvan.Yan@Sun.COM 410Sstevel@tonic-gate /* 420Sstevel@tonic-gate * Interfaces exported by PCI configurator module, kernel/misc/pcicfg. 430Sstevel@tonic-gate */ 44*10923SEvan.Yan@Sun.COM int pcicfg_configure(dev_info_t *, uint_t, uint_t, pcicfg_flags_t); 45*10923SEvan.Yan@Sun.COM int pcicfg_unconfigure(dev_info_t *, uint_t, uint_t, pcicfg_flags_t); 460Sstevel@tonic-gate 470Sstevel@tonic-gate #define PCICFG_SUCCESS DDI_SUCCESS 480Sstevel@tonic-gate #define PCICFG_FAILURE DDI_FAILURE 490Sstevel@tonic-gate 50*10923SEvan.Yan@Sun.COM #define PCICFG_ALL_FUNC 0xffffffff 51*10923SEvan.Yan@Sun.COM 520Sstevel@tonic-gate /* 530Sstevel@tonic-gate * The following subclass definition for Non Transparent bridge should 540Sstevel@tonic-gate * be moved to pci.h. 550Sstevel@tonic-gate */ 560Sstevel@tonic-gate #define PCI_BRIDGE_STBRIDGE 0x9 570Sstevel@tonic-gate 580Sstevel@tonic-gate #define PCICFG_CONF_INDIRECT_MAP 1 590Sstevel@tonic-gate #define PCICFG_CONF_DIRECT_MAP 0 600Sstevel@tonic-gate 610Sstevel@tonic-gate #ifdef __cplusplus 620Sstevel@tonic-gate } 630Sstevel@tonic-gate #endif 640Sstevel@tonic-gate 650Sstevel@tonic-gate #endif /* _SYS_HOTPLUG_PCI_PCICFG_H */ 66