Kconfig 17 KB

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