File tree Expand file tree Collapse file tree 3 files changed +28
-19
lines changed Expand file tree Collapse file tree 3 files changed +28
-19
lines changed Original file line number Diff line number Diff line change 22
22
#include <asm/dsemul.h>
23
23
#include <asm/mipsregs.h>
24
24
#include <asm/prefetch.h>
25
+ #include <asm/vdso/processor.h>
25
26
26
27
/*
27
28
* System setup and hardware flags..
@@ -385,21 +386,6 @@ unsigned long get_wchan(struct task_struct *p);
385
386
#define KSTK_ESP (tsk ) (task_pt_regs(tsk)->regs[29])
386
387
#define KSTK_STATUS (tsk ) (task_pt_regs(tsk)->cp0_status)
387
388
388
- #ifdef CONFIG_CPU_LOONGSON64
389
- /*
390
- * Loongson-3's SFB (Store-Fill-Buffer) may buffer writes indefinitely when a
391
- * tight read loop is executed, because reads take priority over writes & the
392
- * hardware (incorrectly) doesn't ensure that writes will eventually occur.
393
- *
394
- * Since spin loops of any kind should have a cpu_relax() in them, force an SFB
395
- * flush from cpu_relax() such that any pending writes will become visible as
396
- * expected.
397
- */
398
- #define cpu_relax () smp_mb()
399
- #else
400
- #define cpu_relax () barrier()
401
- #endif
402
-
403
389
/*
404
390
* Return_address is a replacement for __builtin_return_address(count)
405
391
* which on certain architectures cannot reasonably be implemented in GCC
Original file line number Diff line number Diff line change 13
13
14
14
#ifndef __ASSEMBLY__
15
15
16
- #include <linux/compiler.h>
17
- #include <linux/time.h>
18
-
19
16
#include <asm/vdso/vdso.h>
20
17
#include <asm/clocksource.h>
21
- #include <asm/io.h>
22
18
#include <asm/unistd.h>
23
19
#include <asm/vdso.h>
24
20
Original file line number Diff line number Diff line change
1
+ /* SPDX-License-Identifier: GPL-2.0-only */
2
+ /*
3
+ * Copyright (C) 2020 ARM Ltd.
4
+ */
5
+ #ifndef __ASM_VDSO_PROCESSOR_H
6
+ #define __ASM_VDSO_PROCESSOR_H
7
+
8
+ #ifndef __ASSEMBLY__
9
+
10
+ #ifdef CONFIG_CPU_LOONGSON64
11
+ /*
12
+ * Loongson-3's SFB (Store-Fill-Buffer) may buffer writes indefinitely when a
13
+ * tight read loop is executed, because reads take priority over writes & the
14
+ * hardware (incorrectly) doesn't ensure that writes will eventually occur.
15
+ *
16
+ * Since spin loops of any kind should have a cpu_relax() in them, force an SFB
17
+ * flush from cpu_relax() such that any pending writes will become visible as
18
+ * expected.
19
+ */
20
+ #define cpu_relax () smp_mb()
21
+ #else
22
+ #define cpu_relax () barrier()
23
+ #endif
24
+
25
+ #endif /* __ASSEMBLY__ */
26
+
27
+ #endif /* __ASM_VDSO_PROCESSOR_H */
You can’t perform that action at this time.
0 commit comments