xref: /titanic_52/usr/src/uts/sun4u/sys/pci/pci_space.h (revision d58fda4376e4bf67072ce2e69f6f47036f9dbb68)
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, Version 1.0 only
6  * (the "License").  You may not use this file except in compliance
7  * with the License.
8  *
9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10  * or http://www.opensolaris.org/os/licensing.
11  * See the License for the specific language governing permissions
12  * and limitations under the License.
13  *
14  * When distributing Covered Code, include this CDDL HEADER in each
15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16  * If applicable, add the following below this CDDL HEADER, with the
17  * fields enclosed by brackets "[]" replaced with your own identifying
18  * information: Portions Copyright [yyyy] [name of copyright owner]
19  *
20  * CDDL HEADER END
21  */
22 /*
23  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
24  * Use is subject to license terms.
25  */
26 
27 #ifndef	_SYS_PCI_SPACE_H
28 #define	_SYS_PCI_SPACE_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI"
31 
32 #ifdef	__cplusplus
33 extern "C" {
34 #endif
35 
36 #define	PCI_SPURINTR_MSG_DEFAULT -1ull
37 
38 extern uint_t tomatillo_disallow_bypass;
39 
40 extern uint_t pci_interrupt_priorities_property;
41 extern uint_t pci_config_space_size_zero;
42 extern int pci_pbm_dma_sync_wait;
43 extern int pci_dvma_sync_before_unmap;
44 extern int pci_sync_lock;
45 extern int tomatillo_store_store_wrka;
46 extern uint_t tm_mtlb_maxpgs;
47 extern uint_t tm_mtlb_gc;
48 extern uint_t tm_mtlb_gc_manual;
49 extern uint32_t pci_spurintr_duration;
50 extern uint64_t pci_spurintr_msgs;
51 
52 
53 extern ushort_t pci_command_default;
54 extern uint_t pci_set_latency_timer_register;
55 extern uint_t pci_set_cache_line_size_register;
56 
57 #ifdef DEBUG
58 extern uint64_t pci_debug_flags;
59 extern uint_t pci_warn_pp0;
60 #endif
61 extern uint_t pci_disable_pass1_workarounds;
62 extern uint_t pci_disable_pass2_workarounds;
63 extern uint_t pci_disable_pass3_workarounds;
64 extern uint_t pci_disable_plus_workarounds;
65 extern uint_t pci_disable_default_workarounds;
66 extern uint_t ecc_error_intr_enable;
67 extern uint_t pci_sbh_error_intr_enable;
68 extern uint_t pci_mmu_error_intr_enable;
69 extern uint_t pci_stream_buf_enable;
70 extern uint_t pci_stream_buf_exists;
71 extern uint_t pci_rerun_disable;
72 extern uint_t pci_enable_periodic_loopback_dma;
73 extern uint_t pci_enable_retry_arb;
74 
75 extern uint_t pci_bus_parking_enable;
76 extern uint_t pci_error_intr_enable;
77 extern uint_t pci_retry_disable;
78 extern uint_t pci_retry_enable;
79 extern uint_t pci_dwsync_disable;
80 extern uint_t pci_intsync_disable;
81 extern uint_t pci_b_arb_enable;
82 extern uint_t pci_a_arb_enable;
83 extern uint_t pci_ecc_afsr_retries;
84 
85 extern uint_t pci_intr_retry_intv;
86 extern uint8_t pci_latency_timer;
87 extern uint_t pci_panic_on_sbh_errors;
88 extern uint_t pci_panic_on_fatal_errors;
89 extern uint_t pci_thermal_intr_fatal;
90 extern uint_t pci_buserr_interrupt;
91 extern uint_t pci_set_dto_value;
92 extern uint_t pci_dto_value;
93 extern uint_t pci_lock_sbuf;
94 extern uint_t pci_use_contexts;
95 extern uint_t pci_sc_use_contexts;
96 extern uint_t pci_context_minpages;
97 extern uint_t pci_ctx_flush_warn;
98 extern uint_t pci_ctx_unsuccess_count;
99 extern uint_t pci_ctx_no_active_flush;
100 extern uint_t pci_ctx_no_compat;
101 
102 extern uint_t pci_check_all_handlers;
103 extern uint_t pci_unclaimed_intr_max;
104 extern ulong_t pci_iommu_dvma_end;
105 extern uint_t pci_lock_tlb;
106 
107 extern uint64_t pci_dvma_debug_on;
108 extern uint64_t pci_dvma_debug_off;
109 extern uint32_t pci_dvma_debug_rec;
110 extern uint_t pci_dvma_page_cache_entries;
111 extern uint_t pci_dvma_page_cache_clustsz;
112 #ifdef PCI_DMA_PROF
113 extern uint_t pci_dvmaft_npages;
114 extern uint_t pci_dvmaft_limit;
115 extern uint_t pci_dvmaft_free;
116 extern uint_t pci_dvmaft_success;
117 extern uint_t pci_dvmaft_exhaust;
118 extern uint_t pci_dvma_vmem_alloc;
119 extern uint_t pci_dvma_vmem_xalloc;
120 extern uint_t pci_dvma_vmem_free;
121 extern uint_t pci_dvma_vmem_xfree;
122 #endif
123 extern uint_t pci_disable_fdvma;
124 
125 extern uint_t pci_iommu_ctx_lock_failure;
126 extern uint_t pci_preserve_iommu_tsb;
127 
128 extern uint64_t pci_perr_enable;
129 extern uint64_t pci_serr_enable;
130 extern uint64_t pci_perr_fatal;
131 extern uint64_t pci_serr_fatal;
132 extern hrtime_t pci_intrpend_timeout;
133 extern hrtime_t pci_sync_buf_timeout;
134 extern hrtime_t pci_cdma_intr_timeout;
135 extern uint32_t pci_cdma_intr_count;
136 
137 extern uint32_t pci_dto_fault_warn;
138 extern uint64_t pci_dto_intr_enable;
139 extern uint64_t pci_dto_count;
140 extern uint64_t pci_errtrig_pa;
141 
142 extern uintptr_t pci_kmem_clid;
143 extern uint_t pci_intr_dma_sync;
144 extern uint_t pci_xmits_sc_max_prf;
145 extern uint64_t xmits_error_intr_enable;
146 extern uint_t xmits_perr_recov_int_enable;
147 extern uint_t xmits_max_transactions;
148 extern uint_t xmits_max_read_bytes;
149 
150 extern int pci_dvma_remap_enabled;
151 extern kthread_t *pci_reloc_thread;
152 extern kmutex_t pci_reloc_mutex;
153 extern kcondvar_t pci_reloc_cv;
154 extern int pci_reloc_presuspend;
155 extern int pci_reloc_suspend;
156 extern id_t pci_dvma_cbid;
157 extern id_t pci_fast_dvma_cbid;
158 extern int pci_dma_panic_on_leak;
159 
160 #ifdef	__cplusplus
161 }
162 #endif
163 
164 #endif	/* _SYS_PCI_SPACE_H */
165