linker: esp32: fix empty iterable symbols

Z_ITERABLE_SECTION_ROM symbols were empty, meaning
that those symbols were not taking place in the linker script.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
This commit is contained in:
Sylvio Alves 2021-05-11 08:04:19 -03:00 committed by Anas Nashif
commit ad0bf94f77

View file

@ -265,41 +265,6 @@ _net_buf_pool_list = _esp_net_buf_pool_list;
SECTION_PROLOGUE(_RODATA_SECTION_NAME,,ALIGN(20)) SECTION_PROLOGUE(_RODATA_SECTION_NAME,,ALIGN(20))
{ {
_rodata_start = ABSOLUTE(.); _rodata_start = ABSOLUTE(.);
#if defined(CONFIG_NET_SOCKETS)
. = ALIGN(4);
Z_LINK_ITERABLE(net_socket_register);
. = ALIGN(4);
#endif
#if defined(CONFIG_SETTINGS)
. = ALIGN(4);
Z_LINK_ITERABLE(settings_handler_static);
. = ALIGN(4);
#endif
#if defined(CONFIG_BT_BREDR)
. = ALIGN(4);
Z_LINK_ITERABLE(bt_l2cap_br_fixed_chan);
. = ALIGN(4);
#endif
#if defined(CONFIG_BT_MESH)
Z_LINK_ITERABLE(bt_mesh_subnet_cb);
Z_LINK_ITERABLE(bt_mesh_app_key_cb);
Z_LINK_ITERABLE(bt_mesh_hb_cb);
#endif
. = ALIGN(4);
Z_LINK_ITERABLE(bt_gatt_service_static);
. = ALIGN(4);
. = ALIGN(4);
Z_LINK_ITERABLE(bt_l2cap_fixed_chan);
. = ALIGN(4);
. = ALIGN(4);
Z_LINK_ITERABLE(shell);
. = ALIGN(4);
__esp_shell_root_cmds_start = .; __esp_shell_root_cmds_start = .;
KEEP(*(SORT(.shell_root_cmd_*))); KEEP(*(SORT(.shell_root_cmd_*)));
@ -337,10 +302,7 @@ _net_buf_pool_list = _esp_net_buf_pool_list;
_rodata_end = ABSOLUTE(.); _rodata_end = ABSOLUTE(.);
} GROUP_LINK_IN(ROMABLE_REGION) } GROUP_LINK_IN(ROMABLE_REGION)
#pragma push_macro("Z_ITERABLE_SECTION_ROM")
#pragma push_macro("ROMABLE_REGION") #pragma push_macro("ROMABLE_REGION")
#undef Z_ITERABLE_SECTION_ROM
#define Z_ITERABLE_SECTION_ROM(x,y)
#undef ROMABLE_REGION #undef ROMABLE_REGION
/* This is to workaround limitation of `esptool` which needs single `FLASH` data segment /* This is to workaround limitation of `esptool` which needs single `FLASH` data segment
* which is already defined above. In case, `common-rom.ld` creates additional segments * which is already defined above. In case, `common-rom.ld` creates additional segments
@ -355,7 +317,6 @@ __log_backends_end = __esp_log_backends_end;
__shell_root_cmds_start = __esp_shell_root_cmds_start; __shell_root_cmds_start = __esp_shell_root_cmds_start;
__shell_root_cmds_end = __esp_shell_root_cmds_end; __shell_root_cmds_end = __esp_shell_root_cmds_end;
#pragma pop_macro("ROMABLE_REGION") #pragma pop_macro("ROMABLE_REGION")
#pragma pop_macro("Z_ITERABLE_SECTION_ROM")
SECTION_PROLOGUE(_TEXT_SECTION_NAME, , ALIGN(4)) SECTION_PROLOGUE(_TEXT_SECTION_NAME, , ALIGN(4))
{ {