Skip to content

Commit

Permalink
core/test/run_mem_region: fix GCC8 compile error
Browse files Browse the repository at this point in the history
error: ‘const’ attribute on function returning ‘void’ [-Werror=attributes]

Fix by not putting the const attribute in the stub

Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
  • Loading branch information
stewartsmith committed May 29, 2018
1 parent f708f67 commit b32ddeb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion core/test/run-mem_region_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ static void add_mem_node(uint64_t start, uint64_t len)
free(name);
}

void __attrconst add_chip_dev_associativity(struct dt_node *dev __attribute__((unused)))
void add_chip_dev_associativity(struct dt_node *dev __attribute__((unused)))
{
}

Expand Down
2 changes: 1 addition & 1 deletion core/test/run-mem_region_release_unused.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ static void add_mem_node(uint64_t start, uint64_t len)
free(name);
}

void __attrconst add_chip_dev_associativity(struct dt_node *dev __attribute__((unused)))
void add_chip_dev_associativity(struct dt_node *dev __attribute__((unused)))
{
}

Expand Down
2 changes: 1 addition & 1 deletion core/test/run-mem_region_release_unused_noalloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ static void add_mem_node(uint64_t start, uint64_t len)
free(name);
}

void __attrconst add_chip_dev_associativity(struct dt_node *dev __attribute__((unused)))
void add_chip_dev_associativity(struct dt_node *dev __attribute__((unused)))
{
}

Expand Down

0 comments on commit b32ddeb

Please sign in to comment.