xref: /openbmc/linux/net/sched/Kconfig (revision d5cb9783536a41df9f9cba5b0a1d78047ed787f7)
1#
2# Traffic control configuration.
3#
4
5menu "QoS and/or fair queueing"
6
7config NET_SCHED
8	bool "QoS and/or fair queueing"
9	---help---
10	  When the kernel has several packets to send out over a network
11	  device, it has to decide which ones to send first, which ones to
12	  delay, and which ones to drop. This is the job of the queueing
13	  disciplines, several different algorithms for how to do this
14	  "fairly" have been proposed.
15
16	  If you say N here, you will get the standard packet scheduler, which
17	  is a FIFO (first come, first served). If you say Y here, you will be
18	  able to choose from among several alternative algorithms which can
19	  then be attached to different network devices. This is useful for
20	  example if some of your network devices are real time devices that
21	  need a certain minimum data flow rate, or if you need to limit the
22	  maximum data flow rate for traffic which matches specified criteria.
23	  This code is considered to be experimental.
24
25	  To administer these schedulers, you'll need the user-level utilities
26	  from the package iproute2+tc at <ftp://ftp.tux.org/pub/net/ip-routing/>.
27	  That package also contains some documentation; for more, check out
28	  <http://linux-net.osdl.org/index.php/Iproute2>.
29
30	  This Quality of Service (QoS) support will enable you to use
31	  Differentiated Services (diffserv) and Resource Reservation Protocol
32	  (RSVP) on your Linux router if you also say Y to the corresponding
33	  classifiers below.  Documentation and software is at
34	  <http://diffserv.sourceforge.net/>.
35
36	  If you say Y here and to "/proc file system" below, you will be able
37	  to read status information about packet schedulers from the file
38	  /proc/net/psched.
39
40	  The available schedulers are listed in the following questions; you
41	  can say Y to as many as you like. If unsure, say N now.
42
43choice
44	prompt "Packet scheduler clock source"
45	depends on NET_SCHED
46	default NET_SCH_CLK_JIFFIES
47	---help---
48	  Packet schedulers need a monotonic clock that increments at a static
49	  rate. The kernel provides several suitable interfaces, each with
50	  different properties:
51
52	  - high resolution (us or better)
53	  - fast to read (minimal locking, no i/o access)
54	  - synchronized on all processors
55	  - handles cpu clock frequency changes
56
57	  but nothing provides all of the above.
58
59config NET_SCH_CLK_JIFFIES
60	bool "Timer interrupt"
61	---help---
62	  Say Y here if you want to use the timer interrupt (jiffies) as clock
63	  source. This clock source is fast, synchronized on all processors and
64	  handles cpu clock frequency changes, but its resolution is too low
65	  for accurate shaping except at very low speed.
66
67config NET_SCH_CLK_GETTIMEOFDAY
68	bool "gettimeofday"
69	---help---
70	  Say Y here if you want to use gettimeofday as clock source. This clock
71	  source has high resolution, is synchronized on all processors and
72	  handles cpu clock frequency changes, but it is slow.
73
74	  Choose this if you need a high resolution clock source but can't use
75	  the CPU's cycle counter.
76
77# don't allow on SMP x86 because they can have unsynchronized TSCs.
78# gettimeofday is a good alternative
79config NET_SCH_CLK_CPU
80	bool "CPU cycle counter"
81	depends on ((X86_TSC || X86_64) && !SMP) || ALPHA || SPARC64 || PPC64 || IA64
82	---help---
83	  Say Y here if you want to use the CPU's cycle counter as clock source.
84	  This is a cheap and high resolution clock source, but on some
85	  architectures it is not synchronized on all processors and doesn't
86	  handle cpu clock frequency changes.
87
88	  The useable cycle counters are:
89
90	  	x86/x86_64	- Timestamp Counter
91		alpha		- Cycle Counter
92		sparc64		- %ticks register
93		ppc64		- Time base
94		ia64		- Interval Time Counter
95
96	  Choose this if your CPU's cycle counter is working properly.
97
98endchoice
99
100comment "Queueing/Scheduling"
101	depends on NET_SCHED
102
103config NET_SCH_CBQ
104	tristate "Class Based Queueing (CBQ)"
105	depends on NET_SCHED
106	---help---
107	  Say Y here if you want to use the Class-Based Queueing (CBQ) packet
108	  scheduling algorithm. This algorithm classifies the waiting packets
109	  into a tree-like hierarchy of classes; the leaves of this tree are
110	  in turn scheduled by separate algorithms.
111
112	  See the top of <file:net/sched/sch_cbq.c> for more details.
113
114	  CBQ is a commonly used scheduler, so if you're unsure, you should
115	  say Y here. Then say Y to all the queueing algorithms below that you
116	  want to use as leaf disciplines.
117
118	  To compile this code as a module, choose M here: the
119	  module will be called sch_cbq.
120
121config NET_SCH_HTB
122	tristate "Hierarchical Token Bucket (HTB)"
123	depends on NET_SCHED
124	---help---
125	  Say Y here if you want to use the Hierarchical Token Buckets (HTB)
126	  packet scheduling algorithm. See
127	  <http://luxik.cdi.cz/~devik/qos/htb/> for complete manual and
128	  in-depth articles.
129
130	  HTB is very similar to CBQ regarding its goals however is has
131	  different properties and different algorithm.
132
133	  To compile this code as a module, choose M here: the
134	  module will be called sch_htb.
135
136config NET_SCH_HFSC
137	tristate "Hierarchical Fair Service Curve (HFSC)"
138	depends on NET_SCHED
139	---help---
140	  Say Y here if you want to use the Hierarchical Fair Service Curve
141	  (HFSC) packet scheduling algorithm.
142
143	  To compile this code as a module, choose M here: the
144	  module will be called sch_hfsc.
145
146config NET_SCH_ATM
147	tristate "ATM Virtual Circuits (ATM)"
148	depends on NET_SCHED && ATM
149	---help---
150	  Say Y here if you want to use the ATM pseudo-scheduler.  This
151	  provides a framework for invoking classifiers, which in turn
152	  select classes of this queuing discipline.  Each class maps
153	  the flow(s) it is handling to a given virtual circuit.
154
155	  See the top of <file:net/sched/sch_atm.c>) for more details.
156
157	  To compile this code as a module, choose M here: the
158	  module will be called sch_atm.
159
160config NET_SCH_PRIO
161	tristate "Multi Band Priority Queueing (PRIO)"
162	depends on NET_SCHED
163	---help---
164	  Say Y here if you want to use an n-band priority queue packet
165	  scheduler.
166
167	  To compile this code as a module, choose M here: the
168	  module will be called sch_prio.
169
170config NET_SCH_RED
171	tristate "Random Early Detection (RED)"
172	depends on NET_SCHED
173	---help---
174	  Say Y here if you want to use the Random Early Detection (RED)
175	  packet scheduling algorithm.
176
177	  See the top of <file:net/sched/sch_red.c> for more details.
178
179	  To compile this code as a module, choose M here: the
180	  module will be called sch_red.
181
182config NET_SCH_SFQ
183	tristate "Stochastic Fairness Queueing (SFQ)"
184	depends on NET_SCHED
185	---help---
186	  Say Y here if you want to use the Stochastic Fairness Queueing (SFQ)
187	  packet scheduling algorithm .
188
189	  See the top of <file:net/sched/sch_sfq.c> for more details.
190
191	  To compile this code as a module, choose M here: the
192	  module will be called sch_sfq.
193
194config NET_SCH_TEQL
195	tristate "True Link Equalizer (TEQL)"
196	depends on NET_SCHED
197	---help---
198	  Say Y here if you want to use the True Link Equalizer (TLE) packet
199	  scheduling algorithm. This queueing discipline allows the combination
200	  of several physical devices into one virtual device.
201
202	  See the top of <file:net/sched/sch_teql.c> for more details.
203
204	  To compile this code as a module, choose M here: the
205	  module will be called sch_teql.
206
207config NET_SCH_TBF
208	tristate "Token Bucket Filter (TBF)"
209	depends on NET_SCHED
210	---help---
211	  Say Y here if you want to use the Token Bucket Filter (TBF) packet
212	  scheduling algorithm.
213
214	  See the top of <file:net/sched/sch_tbf.c> for more details.
215
216	  To compile this code as a module, choose M here: the
217	  module will be called sch_tbf.
218
219config NET_SCH_GRED
220	tristate "Generic Random Early Detection (GRED)"
221	depends on NET_SCHED
222	---help---
223	  Say Y here if you want to use the Generic Random Early Detection
224	  (GRED) packet scheduling algorithm for some of your network devices
225	  (see the top of <file:net/sched/sch_red.c> for details and
226	  references about the algorithm).
227
228	  To compile this code as a module, choose M here: the
229	  module will be called sch_gred.
230
231config NET_SCH_DSMARK
232	tristate "Differentiated Services marker (DSMARK)"
233	depends on NET_SCHED
234	---help---
235	  Say Y if you want to schedule packets according to the
236	  Differentiated Services architecture proposed in RFC 2475.
237	  Technical information on this method, with pointers to associated
238	  RFCs, is available at <http://www.gta.ufrj.br/diffserv/>.
239
240	  To compile this code as a module, choose M here: the
241	  module will be called sch_dsmark.
242
243config NET_SCH_NETEM
244	tristate "Network emulator (NETEM)"
245	depends on NET_SCHED
246	---help---
247	  Say Y if you want to emulate network delay, loss, and packet
248	  re-ordering. This is often useful to simulate networks when
249	  testing applications or protocols.
250
251	  To compile this driver as a module, choose M here: the module
252	  will be called sch_netem.
253
254	  If unsure, say N.
255
256config NET_SCH_INGRESS
257	tristate "Ingress Qdisc"
258	depends on NET_SCHED
259	---help---
260	  Say Y here if you want to use classifiers for incoming packets.
261	  If unsure, say Y.
262
263	  To compile this code as a module, choose M here: the
264	  module will be called sch_ingress.
265
266comment "Classification"
267	depends on NET_SCHED
268
269config NET_CLS
270	boolean
271
272config NET_CLS_BASIC
273	tristate "Elementary classification (BASIC)"
274	depends NET_SCHED
275	select NET_CLS
276	---help---
277	  Say Y here if you want to be able to classify packets using
278	  only extended matches and actions.
279
280	  To compile this code as a module, choose M here: the
281	  module will be called cls_basic.
282
283config NET_CLS_TCINDEX
284	tristate "Traffic-Control Index (TCINDEX)"
285	depends NET_SCHED
286	select NET_CLS
287	---help---
288	  Say Y here if you want to be able to classify packets based on
289	  traffic control indices. You will want this feature if you want
290	  to implement Differentiated Services together with DSMARK.
291
292	  To compile this code as a module, choose M here: the
293	  module will be called cls_tcindex.
294
295config NET_CLS_ROUTE4
296	tristate "Routing decision (ROUTE)"
297	depends NET_SCHED
298	select NET_CLS_ROUTE
299	select NET_CLS
300	---help---
301	  If you say Y here, you will be able to classify packets
302	  according to the route table entry they matched.
303
304	  To compile this code as a module, choose M here: the
305	  module will be called cls_route.
306
307config NET_CLS_ROUTE
308	bool
309	default n
310
311config NET_CLS_FW
312	tristate "Netfilter mark (FW)"
313	depends NET_SCHED
314	select NET_CLS
315	---help---
316	  If you say Y here, you will be able to classify packets
317	  according to netfilter/firewall marks.
318
319	  To compile this code as a module, choose M here: the
320	  module will be called cls_fw.
321
322config NET_CLS_U32
323	tristate "Universal 32bit comparisons w/ hashing (U32)"
324	depends NET_SCHED
325	select NET_CLS
326	---help---
327	  Say Y here to be able to classify packetes using a universal
328	  32bit pieces based comparison scheme.
329
330	  To compile this code as a module, choose M here: the
331	  module will be called cls_u32.
332
333config CLS_U32_PERF
334	bool "Performance counters support"
335	depends on NET_CLS_U32
336	---help---
337	  Say Y here to make u32 gather additional statistics useful for
338	  fine tuning u32 classifiers.
339
340config CLS_U32_MARK
341	bool "Netfilter marks support"
342	depends on NET_CLS_U32 && NETFILTER
343	---help---
344	  Say Y here to be able to use netfilter marks as u32 key.
345
346config NET_CLS_RSVP
347	tristate "IPv4 Resource Reservation Protocol (RSVP)"
348	depends on NET_SCHED
349	select NET_CLS
350	select NET_ESTIMATOR
351	---help---
352	  The Resource Reservation Protocol (RSVP) permits end systems to
353	  request a minimum and maximum data flow rate for a connection; this
354	  is important for real time data such as streaming sound or video.
355
356	  Say Y here if you want to be able to classify outgoing packets based
357	  on their RSVP requests.
358
359	  To compile this code as a module, choose M here: the
360	  module will be called cls_rsvp.
361
362config NET_CLS_RSVP6
363	tristate "IPv6 Resource Reservation Protocol (RSVP6)"
364	depends on NET_SCHED
365	select NET_CLS
366	select NET_ESTIMATOR
367	---help---
368	  The Resource Reservation Protocol (RSVP) permits end systems to
369	  request a minimum and maximum data flow rate for a connection; this
370	  is important for real time data such as streaming sound or video.
371
372	  Say Y here if you want to be able to classify outgoing packets based
373	  on their RSVP requests and you are using the IPv6.
374
375	  To compile this code as a module, choose M here: the
376	  module will be called cls_rsvp6.
377
378config NET_EMATCH
379	bool "Extended Matches"
380	depends NET_SCHED
381	select NET_CLS
382	---help---
383	  Say Y here if you want to use extended matches on top of classifiers
384	  and select the extended matches below.
385
386	  Extended matches are small classification helpers not worth writing
387	  a separate classifier for.
388
389	  A recent version of the iproute2 package is required to use
390	  extended matches.
391
392config NET_EMATCH_STACK
393	int "Stack size"
394	depends on NET_EMATCH
395	default "32"
396	---help---
397	  Size of the local stack variable used while evaluating the tree of
398	  ematches. Limits the depth of the tree, i.e. the number of
399	  encapsulated precedences. Every level requires 4 bytes of additional
400	  stack space.
401
402config NET_EMATCH_CMP
403	tristate "Simple packet data comparison"
404	depends on NET_EMATCH
405	---help---
406	  Say Y here if you want to be able to classify packets based on
407	  simple packet data comparisons for 8, 16, and 32bit values.
408
409	  To compile this code as a module, choose M here: the
410	  module will be called em_cmp.
411
412config NET_EMATCH_NBYTE
413	tristate "Multi byte comparison"
414	depends on NET_EMATCH
415	---help---
416	  Say Y here if you want to be able to classify packets based on
417	  multiple byte comparisons mainly useful for IPv6 address comparisons.
418
419	  To compile this code as a module, choose M here: the
420	  module will be called em_nbyte.
421
422config NET_EMATCH_U32
423	tristate "U32 key"
424	depends on NET_EMATCH
425	---help---
426	  Say Y here if you want to be able to classify packets using
427	  the famous u32 key in combination with logic relations.
428
429	  To compile this code as a module, choose M here: the
430	  module will be called em_u32.
431
432config NET_EMATCH_META
433	tristate "Metadata"
434	depends on NET_EMATCH
435	---help---
436	  Say Y here if you want to be ablt to classify packets based on
437	  metadata such as load average, netfilter attributes, socket
438	  attributes and routing decisions.
439
440	  To compile this code as a module, choose M here: the
441	  module will be called em_meta.
442
443config NET_EMATCH_TEXT
444	tristate "Textsearch"
445	depends on NET_EMATCH
446	select TEXTSEARCH
447	select TEXTSEARCH_KMP
448	select TEXTSEARCH_BM
449	select TEXTSEARCH_FSM
450	---help---
451	  Say Y here if you want to be able to classify packets based on
452	  textsearch comparisons.
453
454	  To compile this code as a module, choose M here: the
455	  module will be called em_text.
456
457config NET_CLS_ACT
458	bool "Actions"
459	depends on EXPERIMENTAL && NET_SCHED
460	select NET_ESTIMATOR
461	---help---
462	  Say Y here if you want to use traffic control actions. Actions
463	  get attached to classifiers and are invoked after a successful
464	  classification. They are used to overwrite the classification
465	  result, instantly drop or redirect packets, etc.
466
467	  A recent version of the iproute2 package is required to use
468	  extended matches.
469
470config NET_ACT_POLICE
471	tristate "Traffic Policing"
472        depends on NET_CLS_ACT
473        ---help---
474	  Say Y here if you want to do traffic policing, i.e. strict
475	  bandwidth limiting. This action replaces the existing policing
476	  module.
477
478	  To compile this code as a module, choose M here: the
479	  module will be called police.
480
481config NET_ACT_GACT
482        tristate "Generic actions"
483        depends on NET_CLS_ACT
484        ---help---
485	  Say Y here to take generic actions such as dropping and
486	  accepting packets.
487
488	  To compile this code as a module, choose M here: the
489	  module will be called gact.
490
491config GACT_PROB
492        bool "Probability support"
493        depends on NET_ACT_GACT
494        ---help---
495	  Say Y here to use the generic action randomly or deterministically.
496
497config NET_ACT_MIRRED
498        tristate "Redirecting and Mirroring"
499        depends on NET_CLS_ACT
500        ---help---
501	  Say Y here to allow packets to be mirrored or redirected to
502	  other devices.
503
504	  To compile this code as a module, choose M here: the
505	  module will be called mirred.
506
507config NET_ACT_IPT
508        tristate "IPtables targets"
509        depends on NET_CLS_ACT && NETFILTER && IP_NF_IPTABLES
510        ---help---
511	  Say Y here to be able to invoke iptables targets after succesful
512	  classification.
513
514	  To compile this code as a module, choose M here: the
515	  module will be called ipt.
516
517config NET_ACT_PEDIT
518        tristate "Packet Editing"
519        depends on NET_CLS_ACT
520        ---help---
521	  Say Y here if you want to mangle the content of packets.
522
523	  To compile this code as a module, choose M here: the
524	  module will be called pedit.
525
526config NET_ACT_SIMP
527        tristate "Simple Example (Debug)"
528        depends on NET_CLS_ACT
529        ---help---
530	  Say Y here to add a simple action for demonstration purposes.
531	  It is meant as an example and for debugging purposes. It will
532	  print a configured policy string followed by the packet count
533	  to the console for every packet that passes by.
534
535	  If unsure, say N.
536
537	  To compile this code as a module, choose M here: the
538	  module will be called simple.
539
540config NET_CLS_POLICE
541	bool "Traffic Policing (obsolete)"
542	depends on NET_SCHED && NET_CLS_ACT!=y
543	select NET_ESTIMATOR
544	---help---
545	  Say Y here if you want to do traffic policing, i.e. strict
546	  bandwidth limiting. This option is obsoleted by the traffic
547	  policer implemented as action, it stays here for compatibility
548	  reasons.
549
550config NET_CLS_IND
551	bool "Incoming device classification"
552	depends on NET_SCHED && (NET_CLS_U32 || NET_CLS_FW)
553	---help---
554	  Say Y here to extend the u32 and fw classifier to support
555	  classification based on the incoming device. This option is
556	  likely to disappear in favour of the metadata ematch.
557
558config NET_ESTIMATOR
559	bool "Rate estimator"
560	depends on NET_SCHED
561	---help---
562	  Say Y here to allow using rate estimators to estimate the current
563	  rate-of-flow for network devices, queues, etc. This module is
564	  automaticaly selected if needed but can be selected manually for
565	  statstical purposes.
566
567endmenu
568