Skip to contentSkip to conversation

net-next branch fails to build on my P8 CI system

DISCUSSION Abdul Haleem 2 participants 2 messages Nov 12, 2019

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

Greeting's

I see a build failure for net-next branch on my Power 8 system

13:25:10 ERROR| [stderr] ./include/linux/u64_stats_sync.h: In function 64_stats_read�:
13:25:10 ERROR| [stderr] ./include/linux/u64_stats_sync.h:80:2: warning: passing argument 1 of 鈥榣ocal_read鈥� discards 鈥榗onst鈥� qualifier from pointer target type [enabled by default]
13:25:10 ERROR| [stderr]   return local64_read(&p->v);
13:25:10 ERROR| [stderr]   ^
13:25:10 ERROR| [stderr] In file included from ./include/asm-generic/local64.h:22:0,
13:25:10 ERROR| [stderr]                  from ./arch/powerpc/include/generated/asm/local64.h:1,
13:25:10 ERROR| [stderr]                  from ./include/linux/u64_stats_sync.h:72,
13:25:10 ERROR| [stderr]                  from ./include/linux/cgroup-defs.h:20,
13:25:10 ERROR| [stderr]                  from ./include/linux/cgroup.h:28,
13:25:10 ERROR| [stderr]                  from ./include/linux/memcontrol.h:13,
13:25:10 ERROR| [stderr]                  from ./include/linux/swap.h:9,
13:25:10 ERROR| [stderr]                  from ./include/linux/suspend.h:5,
13:25:10 ERROR| [stderr]                  from init/do_mounts.c:7:
13:25:10 ERROR| [stderr] ./arch/powerpc/include/asm/local.h:20:24: note: expected 鈥榮truct local_t *鈥� but argument is of type 鈥榗onst struct local_t *鈥�
13:25:10 ERROR| [stderr]  static __inline__ long local_read(local_t *l)
13:25:10 ERROR| [stderr]                         ^
13:25:11 ERROR| [stderr] In file included from ./include/linux/cgroup-defs.h:20:0,
13:25:11 ERROR| [stderr]                  from ./include/linux/cgroup.h:28,
13:25:11 ERROR| [stderr]                  from ./include/linux/hugetlb.h:9,
13:25:11 ERROR| [stderr]                  from arch/powerpc/kvm/book3s_64_vio_hv.c:16:
13:25:11 ERROR| [stderr] ./include/linux/u64_stats_sync.h: In function 鈥榰64_stats_read鈥�:
13:25:11 ERROR| [stderr] ./include/linux/u64_stats_sync.h:80:2: error: passing argument 1 of 鈥榣ocal_read鈥� discards 鈥榗onst鈥� qualifier from pointer target type [-Werror]
13:25:11 ERROR| [stderr]   return local64_read(&p->v);
13:25:11 ERROR| [stderr]   ^

I see some recent code changes here

9dfd871481c8e9c512938e9ce632beed645363e0 Merge branch 'u64_stats_t' fd2f4737870eb866537fbbffa2b59414b9b0c0a2 net: use u64_stats_t in struct pcpu_lstats
5260dd3ed1ff7eba39251b28977e4d8950e2f099 tun: switch to u64_stats_t 316580b69d0a7aeeee5063af47438b626bc47cbd u64_stats: provide u64_stats_t type

Signature · 4 lines
Regard's

Abdul Haleem
IBM Linux Technology Centre
#1 lore raw
Quoted 29 lines · Abdul Haleem

Greeting's

I see a build failure for net-next branch on my Power 8 system

13:25:10 ERROR| [stderr] ./include/linux/u64_stats_sync.h: In function 64_stats_read�:
13:25:10 ERROR| [stderr] ./include/linux/u64_stats_sync.h:80:2: warning: passing argument 1 of 鈥榣ocal_read鈥� discards 鈥榗onst鈥� qualifier from pointer target type [enabled by default]
13:25:10 ERROR| [stderr]   return local64_read(&p->v);
13:25:10 ERROR| [stderr]   ^
13:25:10 ERROR| [stderr] In file included from ./include/asm-generic/local64.h:22:0,
13:25:10 ERROR| [stderr]                  from ./arch/powerpc/include/generated/asm/local64.h:1,
13:25:10 ERROR| [stderr]                  from ./include/linux/u64_stats_sync.h:72,
13:25:10 ERROR| [stderr]                  from ./include/linux/cgroup-defs.h:20,
13:25:10 ERROR| [stderr]                  from ./include/linux/cgroup.h:28,
13:25:10 ERROR| [stderr]                  from ./include/linux/memcontrol.h:13,
13:25:10 ERROR| [stderr]                  from ./include/linux/swap.h:9,
13:25:10 ERROR| [stderr]                  from ./include/linux/suspend.h:5,
13:25:10 ERROR| [stderr]                  from init/do_mounts.c:7:
13:25:10 ERROR| [stderr] ./arch/powerpc/include/asm/local.h:20:24: note: expected 鈥榮truct local_t *鈥� but argument is of type 鈥榗onst struct local_t *鈥�
13:25:10 ERROR| [stderr]  static __inline__ long local_read(local_t *l)
13:25:10 ERROR| [stderr]                         ^
13:25:11 ERROR| [stderr] In file included from ./include/linux/cgroup-defs.h:20:0,
13:25:11 ERROR| [stderr]                  from ./include/linux/cgroup.h:28,
13:25:11 ERROR| [stderr]                  from ./include/linux/hugetlb.h:9,
13:25:11 ERROR| [stderr]                  from arch/powerpc/kvm/book3s_64_vio_hv.c:16:
13:25:11 ERROR| [stderr] ./include/linux/u64_stats_sync.h: In function 鈥榰64_stats_read鈥�:
13:25:11 ERROR| [stderr] ./include/linux/u64_stats_sync.h:80:2: error: passing argument 1 of 鈥榣ocal_read鈥� discards 鈥榗onst鈥� qualifier from pointer target type [-Werror]
13:25:11 ERROR| [stderr]   return local64_read(&p->v);
13:25:11 ERROR| [stderr]   ^
Quoted 10 lines

I see some recent code changes here

9dfd871481c8e9c512938e9ce632beed645363e0 Merge branch 'u64_stats_t' fd2f4737870eb866537fbbffa2b59414b9b0c0a2 net: use u64_stats_t in struct pcpu_lstats
5260dd3ed1ff7eba39251b28977e4d8950e2f099 tun: switch to u64_stats_t 316580b69d0a7aeeee5063af47438b626bc47cbd u64_stats: provide u64_stats_t type

Fix has been sent few days ago.

For some reason the [email protected] list has not received the patch.

From 47c47befdcf31fb8498c9e630bb8e0dc3ef88079 Mon Sep 17 00:00:00 2001
From: Eric Dumazet <[email protected]>
Date: Fri, 8 Nov 2019 06:04:35 -0800
Subject: [PATCH] powerpc: add const qual to local_read() parameter

A patch in net-next triggered a compile error on powerpc.

This seems reasonable to relax powerpc local_read() requirements.

Fixes 316580b69d0a ("u64_stats: provide u64_stats_t type")
Cc Benjamin Herrenschmidt <[email protected]>
Cc Paul Mackerras <[email protected]>
Cc Michael Ellerman <[email protected]>
---
 arch/powerpc/include/asm/local.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/powerpc/include/asm/local.h +1 -1
index fdd00939270bf08113b537a090d6a6e34a048361..bc4bd19b7fc235b80ec1132f44409b6fe1057975 100644
@@ -17,7 +17,7 @@ typedef struct
 
 #define LOCAL_INIT(i)	{ (i) }
 
-static __inline__ long local_read(local_t *l)
+static __inline__ long local_read(const local_t *l)
 {
 	return READ_ONCE(l->v);
 }
Signature · 1 line
2.24.0.432.g9d3f5f5b63-goog