diff options
author | Thomas Bogendoerfer <tsbogend@alpha.franken.de> | 2021-02-10 17:16:13 +0100 |
---|---|---|
committer | Thomas Bogendoerfer <tsbogend@alpha.franken.de> | 2021-02-13 09:53:08 +0100 |
commit | b1468f3071f7312bdc78c380dd01273b5e4459c1 (patch) | |
tree | 86b23c652e28410edebd15553b67ee9fc038dc39 /arch/mips/kernel/ftrace.c | |
parent | 4e0664416c70702731734ab8b3e4819a5a2c0486 (diff) | |
download | lwn-b1468f3071f7312bdc78c380dd01273b5e4459c1.tar.gz lwn-b1468f3071f7312bdc78c380dd01273b5e4459c1.zip |
Revert "MIPS: kernel: {ftrace,kgdb}: Set correct address limit for cache flushes"
This reverts commit 6ebda44f366478d1eea180d93154e7d97b591f50.
All icache flushes in this code paths are done via flush_icache_range(),
which only uses normal cache instruction. And this is the correct thing
for EVA mode, too. So no need to do set_fs(KERNEL_DS) here.
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'arch/mips/kernel/ftrace.c')
-rw-r--r-- | arch/mips/kernel/ftrace.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/arch/mips/kernel/ftrace.c b/arch/mips/kernel/ftrace.c index f57e68f40a34..666b9969c1bd 100644 --- a/arch/mips/kernel/ftrace.c +++ b/arch/mips/kernel/ftrace.c @@ -73,7 +73,6 @@ static inline void ftrace_dyn_arch_init_insns(void) static int ftrace_modify_code(unsigned long ip, unsigned int new_code) { int faulted; - mm_segment_t old_fs; /* *(unsigned int *)ip = new_code; */ safe_store_code(new_code, ip, faulted); @@ -81,10 +80,7 @@ static int ftrace_modify_code(unsigned long ip, unsigned int new_code) if (unlikely(faulted)) return -EFAULT; - old_fs = get_fs(); - set_fs(KERNEL_DS); flush_icache_range(ip, ip + 8); - set_fs(old_fs); return 0; } |