1 /* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9 * or http://www.opensolaris.org/os/licensing. 10 * See the License for the specific language governing permissions 11 * and limitations under the License. 12 * 13 * When distributing Covered Code, include this CDDL HEADER in each 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15 * If applicable, add the following below this CDDL HEADER, with the 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 /* 22 * Copyright 2006 Sun Microsystems, Inc. All rights reserved. 23 * Use is subject to license terms. 24 */ 25 /* 26 * Copyright (c) * Copyright (c) 2001 Tadpole Technology plc 27 * All rights reserved. 28 */ 29 30 #ifndef _SYS_CARDBUS_CFG_H 31 #define _SYS_CARDBUS_CFG_H 32 33 #pragma ident "%Z%%M% %I% %E% SMI" 34 35 #ifdef __cplusplus 36 extern "C" { 37 #endif 38 39 /* 40 * Cardbus device identifiers 41 */ 42 #define CBUS_ID(vend, dev) ((uint32_t)(((uint32_t)(vend) << 16) | (dev))) 43 44 #define CB_PPD_CODE 0x2441 45 46 struct cardbus_parent_private_data { 47 struct ddi_parent_private_data ppd; /* this format for prtconf */ 48 uint16_t code; /* == CB_PPD_CODE */ 49 /* pci_regspec_t *regs; */ 50 }; 51 52 extern kmutex_t cardbus_list_mutex; 53 extern int cardbus_latency_timer; 54 55 extern int cardbus_configure(cbus_t *cbp); 56 extern int cardbus_unconfigure(cbus_t *cbp); 57 extern int cardbus_teardown_device(dev_info_t *); 58 extern int cardbus_primary_busno(dev_info_t *dip); 59 #ifdef sparc 60 extern int cardbus_get_class_pil(dev_info_t *rdip); 61 #endif 62 63 #ifdef DEBUG 64 extern void cardbus_dump_children(dev_info_t *dip, int level); 65 extern void cardbus_dump_family_tree(dev_info_t *dip); 66 #endif 67 68 #ifdef __cplusplus 69 } 70 #endif 71 72 #endif /* _SYS_CARDBUS_CFG_H */ 73