rte_config.h 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. /* SPDX-License-Identifier: BSD-3-Clause
  2. * Copyright(c) 2017 Intel Corporation
  3. */
  4. /**
  5. * @file Header file containing DPDK compilation parameters
  6. *
  7. * Header file containing DPDK compilation parameters. Also include the
  8. * meson-generated header file containing the detected parameters that
  9. * are variable across builds or build environments.
  10. */
  11. #ifndef _RTE_CONFIG_H_
  12. #define _RTE_CONFIG_H_
  13. #include <rte_build_config.h>
  14. #include "rte_compatibility_defines.h"
  15. /* legacy defines */
  16. #ifdef RTE_EXEC_ENV_LINUX
  17. #define RTE_EXEC_ENV_LINUXAPP 1
  18. #endif
  19. #ifdef RTE_EXEC_ENV_FREEBSD
  20. #define RTE_EXEC_ENV_BSDAPP 1
  21. #endif
  22. /* String that appears before the version number */
  23. #define RTE_VER_PREFIX "DPDK"
  24. /****** library defines ********/
  25. /* EAL defines */
  26. #define RTE_MAX_HEAPS 32
  27. #define RTE_MAX_MEMSEG_LISTS 128
  28. #define RTE_MAX_MEMSEG_PER_LIST 8192
  29. #define RTE_MAX_MEM_MB_PER_LIST 32768
  30. #define RTE_MAX_MEMSEG_PER_TYPE 32768
  31. #define RTE_MAX_MEM_MB_PER_TYPE 65536
  32. #define RTE_MAX_MEMZONE 2560
  33. #define RTE_MAX_TAILQ 32
  34. #define RTE_LOG_DP_LEVEL RTE_LOG_INFO
  35. #define RTE_BACKTRACE 1
  36. #define RTE_MAX_VFIO_CONTAINERS 64
  37. /* bsd module defines */
  38. #define RTE_CONTIGMEM_MAX_NUM_BUFS 64
  39. #define RTE_CONTIGMEM_DEFAULT_NUM_BUFS 1
  40. #define RTE_CONTIGMEM_DEFAULT_BUF_SIZE (512*1024*1024)
  41. /* mempool defines */
  42. #define RTE_MEMPOOL_CACHE_MAX_SIZE 512
  43. /* mbuf defines */
  44. #define RTE_MBUF_DEFAULT_MEMPOOL_OPS "ring_mp_mc"
  45. #define RTE_MBUF_REFCNT_ATOMIC 1
  46. #define RTE_PKTMBUF_HEADROOM 128
  47. /* ether defines */
  48. #define RTE_MAX_QUEUES_PER_PORT 1024
  49. #define RTE_ETHDEV_QUEUE_STAT_CNTRS 16 /* max 256 */
  50. #define RTE_ETHDEV_RXTX_CALLBACKS 1
  51. /* cryptodev defines */
  52. #define RTE_CRYPTO_MAX_DEVS 64
  53. #define RTE_CRYPTODEV_NAME_LEN 64
  54. /* compressdev defines */
  55. #define RTE_COMPRESS_MAX_DEVS 64
  56. /* regexdev defines */
  57. #define RTE_MAX_REGEXDEV_DEVS 32
  58. /* eventdev defines */
  59. #define RTE_EVENT_MAX_DEVS 16
  60. #define RTE_EVENT_MAX_QUEUES_PER_DEV 255
  61. #define RTE_EVENT_TIMER_ADAPTER_NUM_MAX 32
  62. #define RTE_EVENT_ETH_INTR_RING_SIZE 1024
  63. #define RTE_EVENT_CRYPTO_ADAPTER_MAX_INSTANCE 32
  64. #define RTE_EVENT_ETH_TX_ADAPTER_MAX_INSTANCE 32
  65. /* rawdev defines */
  66. #define RTE_RAWDEV_MAX_DEVS 64
  67. /* ip_fragmentation defines */
  68. #define RTE_LIBRTE_IP_FRAG_MAX_FRAG 4
  69. #undef RTE_LIBRTE_IP_FRAG_TBL_STAT
  70. /* rte_power defines */
  71. #define RTE_MAX_LCORE_FREQS 64
  72. /* rte_sched defines */
  73. #undef RTE_SCHED_RED
  74. #undef RTE_SCHED_COLLECT_STATS
  75. #undef RTE_SCHED_SUBPORT_TC_OV
  76. #define RTE_SCHED_PORT_N_GRINDERS 8
  77. #undef RTE_SCHED_VECTOR
  78. /* KNI defines */
  79. #define RTE_KNI_PREEMPT_DEFAULT 1
  80. /* rte_graph defines */
  81. #define RTE_GRAPH_BURST_SIZE 256
  82. #define RTE_LIBRTE_GRAPH_STATS 1
  83. /****** driver defines ********/
  84. /* Packet prefetching in PMDs */
  85. #define RTE_PMD_PACKET_PREFETCH 1
  86. /* QuickAssist device */
  87. /* Max. number of QuickAssist devices which can be attached */
  88. #define RTE_PMD_QAT_MAX_PCI_DEVICES 48
  89. #define RTE_PMD_QAT_COMP_SGL_MAX_SEGMENTS 16
  90. #define RTE_PMD_QAT_COMP_IM_BUFFER_SIZE 65536
  91. /* virtio crypto defines */
  92. #define RTE_MAX_VIRTIO_CRYPTO 32
  93. /* DPAA SEC max cryptodev devices*/
  94. #define RTE_LIBRTE_DPAA_MAX_CRYPTODEV 4
  95. /* fm10k defines */
  96. #define RTE_LIBRTE_FM10K_RX_OLFLAGS_ENABLE 1
  97. /* hns3 defines */
  98. #define RTE_LIBRTE_HNS3_MAX_TQP_NUM_PER_PF 256
  99. /* i40e defines */
  100. #define RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC 1
  101. #undef RTE_LIBRTE_I40E_16BYTE_RX_DESC
  102. #define RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF 64
  103. #define RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF 4
  104. #define RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM 4
  105. /* Ring net PMD settings */
  106. #define RTE_PMD_RING_MAX_RX_RINGS 16
  107. #define RTE_PMD_RING_MAX_TX_RINGS 16
  108. /* QEDE PMD defines */
  109. #define RTE_LIBRTE_QEDE_FW ""
  110. /* DLB PMD defines */
  111. #define RTE_LIBRTE_PMD_DLB_POLL_INTERVAL 1000
  112. #define RTE_LIBRTE_PMD_DLB_UMWAIT_CTL_STATE 0
  113. #undef RTE_LIBRTE_PMD_DLB_QUELL_STATS
  114. #define RTE_LIBRTE_PMD_DLB_SW_CREDIT_QUANTA 32
  115. /* DLB2 defines */
  116. #define RTE_LIBRTE_PMD_DLB2_POLL_INTERVAL 1000
  117. #define RTE_LIBRTE_PMD_DLB2_UMWAIT_CTL_STATE 0
  118. #undef RTE_LIBRTE_PMD_DLB2_QUELL_STATS
  119. #define RTE_LIBRTE_PMD_DLB2_SW_CREDIT_QUANTA 32
  120. #define RTE_PMD_DLB2_DEFAULT_DEPTH_THRESH 256
  121. #endif /* _RTE_CONFIG_H_ */