app_shmem: auto-initialize partitions

There are no longer per-partition initialization functions.
Instead, we iterate over all of them at boot to set up the
derived k_mem_partitions properly.

Some ARC-specific hacks that should never have been applied
have been removed from the userspace test.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2019-01-29 12:56:02 -08:00 committed by Anas Nashif
commit c253a686bf
8 changed files with 53 additions and 157 deletions

View file

@ -42,6 +42,13 @@
}
#endif
SECTION_PROLOGUE(app_shmem_regions, (OPTIONAL),)
{
__app_shmem_regions_start = .;
KEEP(*(SORT(".app_regions.*")));
__app_shmem_regions_end = .;
} GROUP_LINK_IN(ROMABLE_REGION)
SECTION_PROLOGUE (devconfig, (OPTIONAL),)
{
__devconfig_start = .;

View file

@ -116,7 +116,7 @@
#define APP_INPUT_SECTION(sect) *(MAYBE_EXCLUDE_SOME_FILES sect)
#define KERNEL_INPUT_SECTION(sect) *(sect)
#define APP_SMEM_SECTION() KEEP(*(SORT(data_smem_[_a-zA-Z0-9]*)))
#define APP_SMEM_SECTION() KEEP(*(SORT("data_smem_*")))
#ifdef CONFIG_X86 /* LINKER FILES: defines used by linker script */
/* Should be moved to linker-common-defs.h */