rom_layout.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. // Copyright 2020 Espressif Systems (Shanghai) PTE LTD
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. // http://www.apache.org/licenses/LICENSE-2.0
  7. //
  8. // Unless required by applicable law or agreed to in writing, software
  9. // distributed under the License is distributed on an "AS IS" BASIS,
  10. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  11. // See the License for the specific language governing permissions and
  12. // limitations under the License.
  13. #pragma once
  14. #include <stdint.h>
  15. #ifdef __cplusplus
  16. extern "C" {
  17. #endif
  18. #define SUPPORT_WIFI 1
  19. #define SUPPORT_BTDM 1
  20. /* Structure and functions for returning ROM global layout
  21. *
  22. * This is for address symbols defined in the linker script, which may change during ECOs.
  23. */
  24. typedef struct {
  25. void *dram0_stack_shared_mem_start;
  26. void *dram0_rtos_reserved_start;
  27. void *stack_sentry;
  28. void *stack;
  29. void *stack_sentry_app;
  30. void *stack_app;
  31. /* BTDM data */
  32. void *data_start_btdm;
  33. void *data_end_btdm;
  34. void *bss_start_btdm;
  35. void *bss_end_btdm;
  36. void *data_start_btdm_rom;
  37. void *data_end_btdm_rom;
  38. void *data_start_interface_btdm;
  39. void *data_end_interface_btdm;
  40. void *bss_start_interface_btdm;
  41. void *bss_end_interface_btdm;
  42. /* Other DRAM ranges */
  43. #if SUPPORT_BTDM || SUPPORT_WIFI
  44. void *dram_start_phyrom;
  45. void *dram_end_phyrom;
  46. #endif
  47. #if SUPPORT_WIFI
  48. void *dram_start_coexist;
  49. void *dram_end_coexist;
  50. void *dram_start_net80211;
  51. void *dram_end_net80211;
  52. void *dram_start_pp;
  53. void *dram_end_pp;
  54. void *data_start_interface_coexist;
  55. void *data_end_interface_coexist;
  56. void *bss_start_interface_coexist;
  57. void *bss_end_interface_coexist;
  58. void *data_start_interface_net80211;
  59. void *data_end_interface_net80211;
  60. void *bss_start_interface_net80211;
  61. void *bss_end_interface_net80211;
  62. void *data_start_interface_pp;
  63. void *data_end_interface_pp;
  64. void *bss_start_interface_pp;
  65. void *bss_end_interface_pp;
  66. #endif
  67. void *dram_start_usbdev_rom;
  68. void *dram_end_usbdev_rom;
  69. void *dram_start_uart_rom;
  70. void *dram_end_uart_rom;
  71. } ets_rom_layout_t;
  72. extern const ets_rom_layout_t * const ets_rom_layout_p;
  73. #ifdef __cplusplus
  74. }
  75. #endif