Kconfig 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. # Software watchdog configuration
  2. # Copyright (c) 2020 Libre Solar Technologies GmbH
  3. # SPDX-License-Identifier: Apache-2.0
  4. menuconfig TASK_WDT
  5. bool "Task-level software watchdog"
  6. select REBOOT
  7. help
  8. Enable task watchdog
  9. The task watchdog allows to have individual watchdog channels
  10. per thread, even if the hardware supports only a single watchdog.
  11. config TASK_WDT_CHANNELS
  12. int "Maximum number of task watchdog channels"
  13. depends on TASK_WDT
  14. default 5
  15. range 2 100
  16. help
  17. The timeouts for each channel are stored in an array. Allocate only
  18. the required amount of channels to reduce memory footprint.
  19. config TASK_WDT_HW_FALLBACK
  20. bool "Use hardware watchdog as a fallback"
  21. depends on TASK_WDT
  22. default y
  23. help
  24. This option allows to specify a hardware watchdog device in the
  25. application that is used as an additional safety layer if the task
  26. watchdog itself gets stuck.
  27. config TASK_WDT_MIN_TIMEOUT
  28. int "Minimum timeout for task watchdog (ms)"
  29. depends on TASK_WDT_HW_FALLBACK
  30. default 100
  31. range 1 10000
  32. help
  33. The task watchdog uses a continuously restarted k_timer as its
  34. backend. This value specifies the minimum timeout in milliseconds
  35. among all task watchdogs used in the application.
  36. If a hardware watchdog is configured as a fallback for the task
  37. watchdog, its timeout is set to this value plus
  38. TASK_WDT_HW_FALLBACK_DELAY.
  39. config TASK_WDT_HW_FALLBACK_DELAY
  40. int "Additional delay for hardware watchdog (ms)"
  41. depends on TASK_WDT_HW_FALLBACK
  42. default 20
  43. range 1 1000
  44. help
  45. The timeout of the hardware watchdog fallback will be increased by
  46. this value to provide sufficient time for corrective actions in the
  47. callback function.
  48. In addition to that, the delay allows to compensate deviations
  49. between different clock sources for the hardware watchdog and the
  50. kernel timer. This is especially important if the hardware watchdog
  51. is clocked by an inaccurate low-speed RC oscillator.
  52. config TASK_WDT_TIMEOUT
  53. int "timeout for task watchdog (ms)"
  54. depends on TASK_WDT_HW_FALLBACK
  55. default 1000
  56. range 1 10000000
  57. help
  58. The task watchdog uses a continuously restarted k_timer as its
  59. backend. This value specifies the timeout in milliseconds
  60. among all task watchdogs used in the application.
  61. If a hardware watchdog is configured as a fallback for the task
  62. watchdog, its timeout is set to this value plus
  63. TASK_WDT_HW_FALLBACK_DELAY.