aboutsummaryrefslogtreecommitdiffstats
path: root/cvmx-resources.config
blob: 772e17dff14a6d87b5a73b250c831419ceb4e05d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
/***********************license start***************
 * Copyright (c) 2003-2010  Cavium Inc. (support@cavium.com). All rights 
 * reserved.
 *
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 *
 *   * Redistributions of source code must retain the above copyright
 *     notice, this list of conditions and the following disclaimer.
 *
 *   * Redistributions in binary form must reproduce the above
 *     copyright notice, this list of conditions and the following
 *     disclaimer in the documentation and/or other materials provided
 *     with the distribution.

 *   * Neither the name of Cavium Inc. nor the names of
 *     its contributors may be used to endorse or promote products
 *     derived from this software without specific prior written
 *     permission.  

 * This Software, including technical data, may be subject to U.S. export  control
 * laws, including the U.S. Export Administration Act and its  associated
 * regulations, and may be subject to export or import  regulations in other
 * countries. 

 * TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS PROVIDED "AS IS" 
 * AND WITH ALL FAULTS AND CAVIUM INC. MAKES NO PROMISES, REPRESENTATIONS OR
 * WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY, OR OTHERWISE, WITH RESPECT TO
 * THE SOFTWARE, INCLUDING ITS CONDITION, ITS CONFORMITY TO ANY REPRESENTATION OR
 * DESCRIPTION, OR THE EXISTENCE OF ANY LATENT OR PATENT DEFECTS, AND CAVIUM
 * SPECIFICALLY DISCLAIMS ALL IMPLIED (IF ANY) WARRANTIES OF TITLE,
 * MERCHANTABILITY, NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, LACK OF
 * VIRUSES, ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION OR
 * CORRESPONDENCE TO DESCRIPTION. THE ENTIRE  RISK ARISING OUT OF USE OR
 * PERFORMANCE OF THE SOFTWARE LIES WITH YOU.
 ***********************license end**************************************/






/*
 * File version info: $Id: cvmx-resources.config 70030 2012-02-16 04:23:43Z cchavva $
 *
 */
#ifndef __CVMX_RESOURCES_CONFIG__
#define __CVMX_RESOURCES_CONFIG__


#if (CVMX_HELPER_FIRST_MBUFF_SKIP > 256)
#error CVMX_HELPER_FIRST_MBUFF_SKIP is greater than the maximum of 256
#endif

#if (CVMX_HELPER_NOT_FIRST_MBUFF_SKIP > 256)
#error CVMX_HELPER_NOT_FIRST_MBUFF_SKIP is greater than the maximum of 256
#endif


/* Content below this point is only used by the cvmx-config tool, and is
** not used by any C files as CAVIUM_COMPONENT_REQUIREMENT is never
defined.
*/
 #ifdef CAVIUM_COMPONENT_REQUIREMENT
    /* Define the number of LLM ports (interfaces), can be 1 or 2 */
    cvmxconfig
    {
    	#if CVMX_LLM_CONFIG_NUM_PORTS == 2
            define CVMX_LLM_NUM_PORTS value = 2;
	#else
            define CVMX_LLM_NUM_PORTS value = 1;
	#endif
    }
    /* Control the setting of Null pointer detection, default to enabled */
    cvmxconfig {
    	#ifdef CVMX_CONFIG_NULL_POINTER_PROTECT
            define CVMX_NULL_POINTER_PROTECT value = CVMX_CONFIG_NULL_POINTER_PROTECT;
	#else
            define CVMX_NULL_POINTER_PROTECT value = 1;
	#endif
    }
    /* Control Debug prints, default to enabled */
    cvmxconfig {
    	#ifdef CVMX_CONFIG_ENABLE_DEBUG_PRINTS
            define CVMX_ENABLE_DEBUG_PRINTS value = CVMX_CONFIG_ENABLE_DEBUG_PRINTS;
	#else
            define CVMX_ENABLE_DEBUG_PRINTS value = 1;
	#endif
    }

    /* Define CVMX_ENABLE_DFA_FUNCTIONS to allocate resources for the DFA functions */
    #ifdef CVMX_ENABLE_DFA_FUNCTIONS
        cvmxconfig
        {
        	fpa CVMX_FPA_DFA_POOL
                    size        = 2
                    protected   = 1
                    description = "DFA command buffers";
        	fau CVMX_FAU_DFA_STATE
                    size        = 8
                    count       = 1
                    description = "FAU registers for the state of the DFA command queue";
        }
    #endif

    /* Define CVMX_ENABLE_PKO_FUNCTIONS to allocate resources for the PKO functions */
    #ifdef CVMX_ENABLE_PKO_FUNCTIONS
        cvmxconfig
        {
		define CVMX_PKO_QUEUES_PER_PORT_INTERFACE0
		    value       = CVMX_HELPER_PKO_QUEUES_PER_PORT_INTERFACE0
		    description = "PKO queues per port for interface 0 (ports 0-15)";
		define CVMX_PKO_QUEUES_PER_PORT_INTERFACE1
		    value       = CVMX_HELPER_PKO_QUEUES_PER_PORT_INTERFACE1
		    description = "PKO queues per port for interface 1 (ports 16-31)";
		define CVMX_PKO_QUEUES_PER_PORT_INTERFACE2
		    value       = CVMX_HELPER_PKO_QUEUES_PER_PORT_INTERFACE2
		    description = "PKO queues per port for interface 2";
		define CVMX_PKO_QUEUES_PER_PORT_INTERFACE3
		    value       = CVMX_HELPER_PKO_QUEUES_PER_PORT_INTERFACE3
		    description = "PKO queues per port for interface 3";
		define CVMX_PKO_QUEUES_PER_PORT_INTERFACE4
		    value       = CVMX_HELPER_PKO_QUEUES_PER_PORT_INTERFACE4
		    description = "PKO queues per port for interface 4";
                define CVMX_PKO_MAX_PORTS_INTERFACE0
                    value       = CVMX_HELPER_PKO_MAX_PORTS_INTERFACE0
                    description = "Limit on the number of PKO ports enabled for interface 0";
                define CVMX_PKO_MAX_PORTS_INTERFACE1
                    value       = CVMX_HELPER_PKO_MAX_PORTS_INTERFACE1
                    description = "Limit on the number of PKO ports enabled for interface 1";
		define CVMX_PKO_QUEUES_PER_PORT_PCI
		    value       = 1
		    description = "PKO queues per port for PCI (ports 32-35)";
		define CVMX_PKO_QUEUES_PER_PORT_LOOP
		    value       = 1
		    description = "PKO queues per port for Loop devices (ports 36-39)";
		/* We use two queues per port for SRIO0. Having two queues per
		    port with two ports gives us four queues, one for each mailbox */
		define CVMX_PKO_QUEUES_PER_PORT_SRIO0
		    value       = 2
		    description = "PKO queues per port for SRIO0 devices (ports 40-41)";
		/* We use two queues per port for SRIO1. Having two queues per
		    port with two ports gives us four queues, one for each mailbox */
		define CVMX_PKO_QUEUES_PER_PORT_SRIO1
		    value       = 2
		    description = "PKO queues per port for SRIO1 devices (ports 42-43)";
                /* Set the IPD cache mode, select from cvmx_ipd_mode_t. */
                define CVMX_IPD_DRAM_MODE
                    value       = CVMX_HELPER_IPD_DRAM_MODE
                    description	= "set the IPD cache mode to CVMX_IPD_OPC_MODE_STT";
        	fpa CVMX_FPA_PACKET_POOL
                    pool        = 0
                    size        = 16
                    priority    = 1
                    protected   = 1
                    description = "Packet buffers";
        	fpa CVMX_FPA_OUTPUT_BUFFER_POOL
                    size        = 8
                    protected   = 1
                    description = "PKO queue command buffers";
        	scratch CVMX_SCR_SCRATCH
                    size        = 8
                    iobdma      = true
                    permanent   = false
                    description = "Generic scratch iobdma area";
        }
    #endif

    /* Define CVMX_ENABLE_HELPER_FUNCTIONS to allocate resources for the helper functions */
    #ifdef CVMX_ENABLE_HELPER_FUNCTIONS
        cvmxconfig
        {
        	fpa CVMX_FPA_WQE_POOL
                    size        = 1
                    priority    = 1
                    protected   = 1
                    description = "Work queue entrys";
        }
    #endif

    /* Define CVMX_ENABLE_TIMER_FUNCTIONS to allocate resources for the timer functions */
    #ifdef CVMX_ENABLE_TIMER_FUNCTIONS
        cvmxconfig
        {
        	fpa CVMX_FPA_TIMER_POOL
                    size        = 8
                    protected   = 1
                    description = "TIM command buffers";
        }
    #endif

#endif


#endif  /* __CVMX_RESOURCES_CONFIG__ */