[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20201101231835.4589-1-rdunlap@infradead.org>
Date: Sun, 1 Nov 2020 15:18:35 -0800
From: Randy Dunlap <rdunlap@...radead.org>
To: linux-kernel@...r.kernel.org
Cc: Randy Dunlap <rdunlap@...radead.org>,
kernel test robot <lkp@...el.com>,
David Howells <dhowells@...hat.com>,
Arnd Bergmann <arnd@...db.de>,
Richard Henderson <rth@...ddle.net>,
Ivan Kokshaysky <ink@...assic.park.msu.ru>,
Matt Turner <mattst88@...il.com>, linux-alpha@...r.kernel.org,
Andrew Morton <akpm@...ux-foundation.org>,
Stephen Rothwell <sfr@...b.auug.org.au>
Subject: [PATCH v2] asm-generic: barrier.h: fix ALPHA builds when SMP is not enabled
<asm-generic/barrier.h> uses barrier() but needs to #include
<linux/compiler.h> to get a generic definition of it to fix
build errors in arch/alpha/ builds when CONFIG_SMP is not enabled.
Fixes build errors like this (there are several like this):
[49 in the kernel config that was supplied by the 0day bot]
In file included from ../arch/alpha/include/asm/barrier.h:21,
from ../arch/alpha/include/asm/atomic.h:6,
from ../include/linux/atomic.h:7,
from ../include/linux/dcache.h:5,
from ../fs/proc/util.c:1:
../arch/alpha/include/asm/atomic.h: In function 'atomic_add_return_relaxed':
../include/asm-generic/barrier.h:78:18: error: implicit declaration of function 'barrier' [-Werror=implicit-function-declaration]
78 | #define smp_mb() barrier()
| ^~~~~~~
Fixes: 885df91ca357 ("Create asm-generic/barrier.h")
Signed-off-by: Randy Dunlap <rdunlap@...radead.org>
Reported-by: kernel test robot <lkp@...el.com>
Cc: David Howells <dhowells@...hat.com>
Cc: Arnd Bergmann <arnd@...db.de>
Cc: Richard Henderson <rth@...ddle.net>
Cc: Ivan Kokshaysky <ink@...assic.park.msu.ru>
Cc: Matt Turner <mattst88@...il.com>
Cc: linux-alpha@...r.kernel.org
Cc: Andrew Morton <akpm@...ux-foundation.org>
Cc: Stephen Rothwell <sfr@...b.auug.org.au>
---
v2: also send to Andrew and Stephen.
include/asm-generic/barrier.h | 1 +
1 file changed, 1 insertion(+)
--- linux-next-20201030.orig/include/asm-generic/barrier.h
+++ linux-next-20201030/include/asm-generic/barrier.h
@@ -13,6 +13,7 @@
#ifndef __ASSEMBLY__
+#include <linux/compiler.h>
#include <asm/rwonce.h>
#ifndef nop
Powered by blists - more mailing lists