forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-13 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e
kernel/arch/arc/kernel/ctx_sw.c
....@@ -1,9 +1,6 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Copyright (C) 2004, 2007-2010, 2011-2012 Synopsys, Inc. (www.synopsys.com)
3
- *
4
- * This program is free software; you can redistribute it and/or modify
5
- * it under the terms of the GNU General Public License version 2 as
6
- * published by the Free Software Foundation.
74 *
85 * Vineetg: Aug 2009
96 * -"C" version of lowest level context switch asm macro called by schedular
....@@ -17,9 +14,6 @@
1714 #include <asm/asm-offsets.h>
1815 #include <linux/sched.h>
1916 #include <linux/sched/debug.h>
20
-#ifdef CONFIG_ARC_PLAT_EZNPS
21
-#include <plat/ctop.h>
22
-#endif
2317
2418 #define KSP_WORD_OFF ((TASK_THREAD + THREAD_KSP) / 4)
2519
....@@ -71,16 +65,9 @@
7165 #ifndef CONFIG_SMP
7266 "st %2, [@_current_task] \n\t"
7367 #else
74
-#ifdef CONFIG_ARC_PLAT_EZNPS
75
- "lr r24, [%4] \n\t"
76
-#ifndef CONFIG_EZNPS_MTM_EXT
77
- "lsr r24, r24, 4 \n\t"
78
-#endif
79
-#else
8068 "lr r24, [identity] \n\t"
8169 "lsr r24, r24, 8 \n\t"
8270 "bmsk r24, r24, 7 \n\t"
83
-#endif
8471 "add2 r24, @_current_task, r24 \n\t"
8572 "st %2, [r24] \n\t"
8673 #endif
....@@ -118,9 +105,6 @@
118105
119106 : "=r"(tmp)
120107 : "n"(KSP_WORD_OFF), "r"(next), "r"(prev)
121
-#ifdef CONFIG_ARC_PLAT_EZNPS
122
- , "i"(CTOP_AUX_LOGIC_GLOBAL_ID)
123
-#endif
124108 : "blink"
125109 );
126110