Kconfig 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. # Kconfig - USB device stack configuration options
  2. #
  3. # Copyright (c) 2016 Wind River Systems, Inc.
  4. #
  5. # SPDX-License-Identifier: Apache-2.0
  6. #
  7. menuconfig USB_DEVICE_STACK
  8. bool
  9. prompt "USB device stack"
  10. depends on USB_DEVICE_DRIVER || ARCH_POSIX
  11. default n
  12. help
  13. Enable USB device stack.
  14. if USB_DEVICE_STACK
  15. config SYS_LOG_USB_DEVICE_LEVEL
  16. int
  17. prompt "Sets log level for the USB device stack"
  18. default 0
  19. depends on LOG
  20. help
  21. This option sets log level for the USB device stack.
  22. Levels are:
  23. - 0 OFF, do not write
  24. - 1 ERROR, only write SYS_LOG_ERR
  25. - 2 WARNING, write SYS_LOG_WRN in addition to previous level
  26. - 3 INFO, write SYS_LOG_INF in addition to previous levels
  27. - 4 DEBUG, write SYS_LOG_DBG in addition to previous levels
  28. config USB_DEVICE_SELF_POWERED
  29. bool "Enable USB device with self-powered"
  30. default n
  31. help
  32. This option enables USB device with self-powered.
  33. config USB_DEVICE_REMOTE_WAKEUP
  34. bool "Enable support for remote wakeup"
  35. default n
  36. help
  37. This option requires USBD peripheral driver to also support remote wakeup.
  38. config USB_DEVICE_STRING_DESC_MAX_LEN
  39. int
  40. prompt "The max len of device string descriptor"
  41. default 20
  42. help
  43. The max len of device string descriptor.
  44. config USB_DEVICE_TRANSFER
  45. bool
  46. prompt "Enable usb transfer work"
  47. default n
  48. help
  49. Enable usb transfer work.
  50. config USB_COMPOSITE_DEVICE_CLASS_NUM
  51. int
  52. prompt "Number of single class devices in composite devices"
  53. default 2
  54. help
  55. Number of single class devices in composite devices.
  56. config USB_REQUEST_BUFFER_SIZE
  57. int "Set buffer size for Standard, Class and Vendor request handlers"
  58. range 256 65536 if USB_DEVICE_NETWORK_RNDIS
  59. range 8 65536
  60. default 256 if USB_DEVICE_NETWORK_RNDIS
  61. default 1024 if USB_DEVICE_LOOPBACK
  62. default 128
  63. config USB_DEVICE_BOS
  64. bool
  65. prompt "Enable USB Binary Device Object Store (BOS)"
  66. default n
  67. rsource "class/Kconfig"
  68. endif # USB_DEVICE_STACK
  69. menuconfig USB_HOST_STACK
  70. bool
  71. prompt "USB host stack"
  72. depends on USB_HOST_DRIVER
  73. default n
  74. help
  75. Enable USB host stack.
  76. if USB_HOST_STACK
  77. config SYS_LOG_USB_HOST_LEVEL
  78. int
  79. prompt "Sets log level for the USB host stack"
  80. default 0
  81. depends on SYS_LOG
  82. help
  83. This option sets log level for the USB host stack.
  84. Levels are:
  85. - 0 OFF, do not write
  86. - 1 ERROR, only write SYS_LOG_ERR
  87. - 2 WARNING, write SYS_LOG_WRN in addition to previous level
  88. - 3 INFO, write SYS_LOG_INF in addition to previous levels
  89. - 4 DEBUG, write SYS_LOG_DBG in addition to previous levels
  90. config USB_HOST_MAXINTERFACES
  91. int
  92. prompt "max number of interfaces of one configure"
  93. default 1
  94. config USB_HOST_MAXENDPOINTS
  95. int
  96. prompt "max number of endpoints of one interface"
  97. default 2
  98. config USB_HOST_RAW_DESCRIPTORS_SIZE
  99. int
  100. prompt "max size of the whole configure descriptor"
  101. default 32
  102. rsource "host/Kconfig"
  103. endif # USB_HOST_STACK