From patchwork Mon Nov 11 01:39:22 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Rothwell X-Patchwork-Id: 1192690 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 47BD9K4R0Wz9s4Y for ; Mon, 11 Nov 2019 12:40:53 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=canb.auug.org.au Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; secure) header.d=canb.auug.org.au header.i=@canb.auug.org.au header.b="k7U0p6SX"; dkim-atps=neutral Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 47BD9K30V0zF4R2 for ; Mon, 11 Nov 2019 12:40:53 +1100 (AEDT) X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from ozlabs.org (bilbo.ozlabs.org [203.11.71.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 47BD7b3jxgzDqkW for ; Mon, 11 Nov 2019 12:39:23 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=canb.auug.org.au Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=canb.auug.org.au header.i=@canb.auug.org.au header.b="k7U0p6SX"; dkim-atps=neutral Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 47BD7b0NqVz9s4Y; Mon, 11 Nov 2019 12:39:22 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=canb.auug.org.au; s=201702; t=1573436363; bh=AuDaBqMuB8YubdI3py2WhU7Li+8/PG+7HZ/4VOX2HnA=; h=Date:From:To:Cc:Subject:From; b=k7U0p6SXwZk/q8bu8b1ogCWIDgEMACuwxHCNAXQewobz5E1AwkLCWdsjKcY1LuRhn r2fqPu5raFH4i9nsV3Ixc+SLcF4tOsXDkoK43ieWLiRRZM2B+f5F1woaGj0Qy+Hz4X pj06pmo4YMKHjkT36XkW4S9ZEuOOxZWQe/9RTx6vGeV91nfKaPoowCvuZNnktFwx7K iRsZqk07aEP1rl85ArHNloyMqZbyymArZtzAtGzC1s22jNckBiYuV8clMo5KWdoGaJ coc0uCbGLKwDt+xEAHiup3X+B9qm7Gf1HmH5uZCa/lV5hQuAKactfz+Puun5UMArCt ngH2XkK1oic8g== Date: Mon, 11 Nov 2019 12:39:22 +1100 From: Stephen Rothwell To: David Miller , Networking Subject: linux-next: build warning after merge of the net-next tree Message-ID: <20191111123922.540319a2@canb.auug.org.au> MIME-Version: 1.0 X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eric Dumazet , Linux Next Mailing List , PowerPC , Linux Kernel Mailing List Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Hi all, After merging the net-next tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning: In file included from ./arch/powerpc/include/generated/asm/local64.h:1, from include/linux/u64_stats_sync.h:72, from include/linux/cgroup-defs.h:20, from include/linux/cgroup.h:28, from include/linux/memcontrol.h:13, from include/linux/swap.h:9, from include/linux/suspend.h:5, from arch/powerpc/kernel/asm-offsets.c:23: include/linux/u64_stats_sync.h: In function 'u64_stats_read': include/asm-generic/local64.h:30:37: warning: passing argument 1 of 'local_read' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers] 30 | #define local64_read(l) local_read(&(l)->a) | ^~~~~~~ include/linux/u64_stats_sync.h:80:9: note: in expansion of macro 'local64_read' 80 | return local64_read(&p->v); | ^~~~~~~~~~~~ In file included from include/asm-generic/local64.h:22, from ./arch/powerpc/include/generated/asm/local64.h:1, from include/linux/u64_stats_sync.h:72, from include/linux/cgroup-defs.h:20, from include/linux/cgroup.h:28, from include/linux/memcontrol.h:13, from include/linux/swap.h:9, from include/linux/suspend.h:5, from arch/powerpc/kernel/asm-offsets.c:23: arch/powerpc/include/asm/local.h:20:44: note: expected 'local_t *' {aka 'struct *'} but argument is of type 'const local_t *' {aka 'const struct *'} 20 | static __inline__ long local_read(local_t *l) | ~~~~~~~~~^ Introduced by commit 316580b69d0a ("u64_stats: provide u64_stats_t type") Powerpc folks: is there some reason that local_read() cannot take a const argument? I have added this patch (which builds fine) for today: From: Stephen Rothwell Date: Mon, 11 Nov 2019 12:32:24 +1100 Subject: [PATCH] powerpc: local_read() should take a const local_t argument Signed-off-by: Stephen Rothwell Signed-off-by: Eric Dumazet Reported-by: kbuild test robot --- arch/powerpc/include/asm/local.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/include/asm/local.h b/arch/powerpc/include/asm/local.h index fdd00939270b..bc4bd19b7fc2 100644 --- a/arch/powerpc/include/asm/local.h +++ b/arch/powerpc/include/asm/local.h @@ -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); }