[PATCH] linux/seqlock.h should #include asm/processor.h forcpu_relax()

From: David Howells
Date: Sat Jun 11 2011 - 07:30:32 EST


linux/seqlock.h should #include asm/processor.h as it uses cpu_relax().

Without this patch, I see:

CC arch/mn10300/kernel/asm-offsets.s
In file included from include/linux/time.h:8,
from include/linux/timex.h:56,
from include/linux/sched.h:57,
from arch/mn10300/kernel/asm-offsets.c:7:
include/linux/seqlock.h: In function 'read_seqbegin':
include/linux/seqlock.h:91: error: implicit declaration of function 'cpu_relax'

whilst building asb2364_defconfig on MN10300.

Signed-off-by: David Howells <dhowells@xxxxxxxxxx>
---

include/linux/seqlock.h | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/include/linux/seqlock.h b/include/linux/seqlock.h
index e981189..c6db9fb 100644
--- a/include/linux/seqlock.h
+++ b/include/linux/seqlock.h
@@ -28,6 +28,7 @@

#include <linux/spinlock.h>
#include <linux/preempt.h>
+#include <asm/processor.h>

typedef struct {
unsigned sequence;

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/