[Skiboot] [PATCH 01/51] stubs: Remove __attrconst annotation

Andrew Jeffery andrew at aj.id.au
Fri Feb 15 17:56:18 AEDT 2019


`make check` with gcc 8.2.0 (Ubuntu 8.2.0-7ubuntu1) produces the
following warnings:

    [ HOSTCC ]  core/test/stubs.c
    core/test/stubs.c:80:1: warning: ‘const’ attribute on function returning
    ‘void’ [-Wattributes]
    {
    ^
    core/test/stubs.c:87:1: warning: ‘const’ attribute on function returning
    ‘void’ [-Wattributes]
    {
    ^
    [ HOSTCC ]  hdata/test/stubs.c
    hdata/test/stubs.c:122:1: warning: ‘const’ attribute on function
    returning ‘void’ [-Wattributes]
    {
    ^
    hdata/test/stubs.c:131:1: warning: ‘const’ attribute on function
    returning ‘void’ [-Wattributes]
    {
    ^

Signed-off-by: Andrew Jeffery <andrew at aj.id.au>
---
 core/test/stubs.c  | 4 ++--
 hdata/test/stubs.c | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/core/test/stubs.c b/core/test/stubs.c
index 66252f8a1e92..0e80e057d1e4 100644
--- a/core/test/stubs.c
+++ b/core/test/stubs.c
@@ -76,14 +76,14 @@ struct cpu_job *__cpu_queue_job(struct cpu_thread *cpu,
 	return NULL;
 }
 
-void __attrconst cpu_wait_job(struct cpu_job *job, bool free_it)
+void cpu_wait_job(struct cpu_job *job, bool free_it)
 {
 	(void)job;
 	(void)free_it;
 	return;
 }
 
-void __attrconst cpu_process_local_jobs(void)
+void cpu_process_local_jobs(void)
 {
 }
 
diff --git a/hdata/test/stubs.c b/hdata/test/stubs.c
index ab6e2cec1344..f7b1da105e0e 100644
--- a/hdata/test/stubs.c
+++ b/hdata/test/stubs.c
@@ -118,7 +118,7 @@ struct cpu_job *__cpu_queue_job(struct cpu_thread *cpu,
 
 void cpu_wait_job(struct cpu_job *job, bool free_it);
 
-void __attrconst cpu_wait_job(struct cpu_job *job, bool free_it)
+void cpu_wait_job(struct cpu_job *job, bool free_it)
 {
 	(void)job;
 	(void)free_it;
@@ -127,7 +127,7 @@ void __attrconst cpu_wait_job(struct cpu_job *job, bool free_it)
 
 void cpu_process_local_jobs(void);
 
-void __attrconst cpu_process_local_jobs(void)
+void cpu_process_local_jobs(void)
 {
 }
 
-- 
2.19.1



More information about the Skiboot mailing list