Kconfig 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. menu "ESP-Driver:SPI Configurations"
  2. depends on SOC_GPSPI_SUPPORTED
  3. config SPI_MASTER_IN_IRAM
  4. bool "Place transmitting functions of SPI master into IRAM"
  5. default n
  6. depends on !FREERTOS_PLACE_FUNCTIONS_INTO_FLASH
  7. select SPI_MASTER_ISR_IN_IRAM
  8. help
  9. Normally only the ISR of SPI master is placed in the IRAM, so that it
  10. can work without the flash when interrupt is triggered.
  11. For other functions, there's some possibility that the flash cache
  12. miss when running inside and out of SPI functions, which may increase
  13. the interval of SPI transactions.
  14. Enable this to put ``queue_trans``, ``get_trans_result`` and
  15. ``transmit`` functions into the IRAM to avoid possible cache miss.
  16. This configuration won't be available if `CONFIG_FREERTOS_PLACE_FUNCTIONS_INTO_FLASH` is enabled.
  17. During unit test, this is enabled to measure the ideal case of api.
  18. config SPI_MASTER_ISR_IN_IRAM
  19. bool "Place SPI master ISR function into IRAM"
  20. default y
  21. depends on !HEAP_PLACE_FUNCTION_INTO_FLASH
  22. select PERIPH_CTRL_FUNC_IN_IRAM
  23. select HAL_SPI_MASTER_FUNC_IN_IRAM
  24. help
  25. Place the SPI master ISR in to IRAM to avoid possible cache miss.
  26. Enabling this configuration is possible only when HEAP_PLACE_FUNCTION_INTO_FLASH
  27. is disabled since the spi master uses can allocate transactions buffers into DMA
  28. memory section using the heap component API that ipso facto has to be placed in IRAM.
  29. Also you can forbid the ISR being disabled during flash writing
  30. access, by add ESP_INTR_FLAG_IRAM when initializing the driver.
  31. config SPI_SLAVE_IN_IRAM
  32. bool "Place transmitting functions of SPI slave into IRAM"
  33. default n
  34. select SPI_SLAVE_ISR_IN_IRAM
  35. help
  36. Normally only the ISR of SPI slave is placed in the IRAM, so that it
  37. can work without the flash when interrupt is triggered.
  38. For other functions, there's some possibility that the flash cache
  39. miss when running inside and out of SPI functions, which may increase
  40. the interval of SPI transactions.
  41. Enable this to put ``queue_trans``, ``get_trans_result`` and
  42. ``transmit`` functions into the IRAM to avoid possible cache miss.
  43. config SPI_SLAVE_ISR_IN_IRAM
  44. bool "Place SPI slave ISR function into IRAM"
  45. default y
  46. select PERIPH_CTRL_FUNC_IN_IRAM
  47. select HAL_SPI_SLAVE_FUNC_IN_IRAM
  48. help
  49. Place the SPI slave ISR in to IRAM to avoid possible cache miss.
  50. Also you can forbid the ISR being disabled during flash writing
  51. access, by add ESP_INTR_FLAG_IRAM when initializing the driver.
  52. endmenu # SPI Configuration