xref: /titanic_41/usr/src/uts/sun4/io/px/px_space.h (revision 9404882939d18ddd3c94a5bd3da7a0449c195a5d)
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 #ifndef	_SYS_PX_SPACE_H
27 #define	_SYS_PX_SPACE_H
28 
29 #pragma ident	"%Z%%M%	%I%	%E% SMI"
30 
31 #ifdef	__cplusplus
32 extern "C" {
33 #endif
34 
35 #define	PX_SPURINTR_MSG_DEFAULT -1ull
36 
37 extern char px_panic_hb_msg[];
38 extern char px_panic_rc_msg[];
39 extern char px_panic_rp_msg[];
40 extern char px_panic_fab_msg[];
41 
42 extern uint_t px_max_errorq_size;
43 extern ushort_t px_command_default;
44 extern uint_t px_set_latency_timer_register;
45 extern uint64_t px_perr_fatal;
46 extern uint64_t px_serr_fatal;
47 extern hrtime_t px_intrpend_timeout;
48 extern uint_t px_unclaimed_intr_max;
49 extern uint_t px_unclaimed_intr_block;
50 extern uint32_t px_spurintr_duration;
51 extern uint64_t px_spurintr_msgs;
52 extern uint_t px_stream_buf_enable;
53 extern uint_t px_stream_buf_exists;
54 extern uint_t px_use_contexts;
55 extern uint_t px_ctx_no_active_flush;
56 extern uint_t px_context_minpages;
57 
58 extern uint_t px_mmu_error_intr_enable;
59 extern uint_t px_rerun_disable;
60 
61 extern uint_t px_error_intr_enable;
62 extern uint_t px_dwsync_disable;
63 extern uint_t px_intsync_disable;
64 
65 extern uint_t px_intr_retry_intv;
66 extern uint8_t px_latency_timer;
67 extern uint_t px_panic_on_fatal_errors;
68 extern uint_t px_thermal_intr_fatal;
69 extern uint_t px_buserr_interrupt;
70 
71 extern uint64_t px_errtrig_pa;
72 
73 extern uint_t px_check_all_handlers;
74 extern uint_t px_lock_tlb;
75 
76 extern uint64_t px_dvma_debug_on;
77 extern uint64_t px_dvma_debug_off;
78 extern uint32_t px_dvma_debug_rec;
79 extern uint_t px_dvma_page_cache_entries;
80 extern uint_t px_dvma_page_cache_clustsz;
81 extern int px_dvma_sync_before_unmap;
82 #ifdef	PX_DMA_PROF
83 extern uint_t px_dvmaft_npages;
84 extern uint_t px_dvmaft_limit;
85 extern uint_t px_dvmaft_free;
86 extern uint_t px_dvmaft_success;
87 extern uint_t px_dvmaft_exhaust;
88 extern uint_t px_dvma_vmem_alloc;
89 extern uint_t px_dvma_vmem_xalloc;
90 extern uint_t px_dvma_vmem_free;
91 extern uint_t px_dvma_vmem_xfree;
92 #endif	/* PX_DMA_PROF */
93 extern uint_t px_disable_fdvma;
94 
95 extern uint_t px_iommu_ctx_lock_failure;
96 extern uint_t px_preserve_iommu_tsb;
97 extern uintptr_t px_kmem_clid;
98 
99 /* timeout length in micro seconds */
100 #define	PX_MSEC_TO_USEC	1000
101 #define	PX_PME_TO_ACK_TIMEOUT	(1000 * PX_MSEC_TO_USEC)
102 #define	PX_LUP_POLL_INTERVAL	(10 * PX_MSEC_TO_USEC)
103 #define	PX_LUP_POLL_TO		(10 * PX_LUP_POLL_INTERVAL)
104 
105 #define	PX_PWR_PIL		1
106 #define	PX_MAX_L1_TRIES		5
107 
108 extern uint64_t px_pme_to_ack_timeout;
109 extern uint64_t px_lup_poll_to;
110 extern uint64_t px_lup_poll_interval;
111 extern uint32_t	px_pwr_pil;
112 extern uint32_t px_max_l1_tries;
113 
114 /* Print and Log tunables */
115 extern uint32_t px_log;
116 extern uint32_t px_die;
117 
118 /* Fabric Error that should cause panics */
119 extern boolean_t px_fabric_die;
120 extern uint32_t px_fabric_die_rc_ce;
121 extern uint32_t px_fabric_die_rc_ue;
122 extern uint32_t px_fabric_forgive_rc_ce;
123 extern uint32_t px_fabric_forgive_rc_ue;
124 extern uint32_t px_fabric_die_ce;
125 extern uint32_t px_fabric_die_ue;
126 extern uint32_t px_fabric_die_ce_gos;
127 extern uint32_t px_fabric_die_ue_gos;
128 extern uint16_t px_fabric_die_bdg_sts;
129 extern uint16_t px_fabric_die_bdg_sts_gos;
130 extern uint16_t px_fabric_die_sw_sts;
131 extern uint16_t px_fabric_die_sw_sts_gos;
132 extern uint32_t px_fabric_die_sue;
133 extern uint32_t px_fabric_die_sue_gos;
134 
135 #ifdef	__cplusplus
136 }
137 #endif
138 
139 #endif	/* _SYS_PX_SPACE_H */
140