]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
h8300: don't implement set_fs
authorChristoph Hellwig <hch@lst.de>
Fri, 9 Jul 2021 11:53:11 +0000 (13:53 +0200)
committerYoshinori Sato <ysato@users.sourceforge.jp>
Wed, 18 Aug 2021 07:50:10 +0000 (16:50 +0900)
There is no need for set_fs on this nommu-only architecture, so just
remove all the boilerplate code.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
arch/h8300/Kconfig
arch/h8300/include/asm/processor.h
arch/h8300/include/asm/segment.h [deleted file]
arch/h8300/include/asm/thread_info.h
arch/h8300/kernel/entry.S
arch/h8300/kernel/head_ram.S
arch/h8300/mm/init.c

index 3e3e0f16f7e0af5ac78056e9a172ddfa97c0ccd3..fe48c4f26cc83a942b32f1d11bf31e32be903256 100644 (file)
@@ -24,7 +24,6 @@ config H8300
        select HAVE_ARCH_KGDB
        select HAVE_ARCH_HASH
        select CPU_NO_EFFICIENT_FFS
-       select SET_FS
        select UACCESS_MEMCPY
 
 config CPU_BIG_ENDIAN
index a060b41b2d31ca74f79aecfb50cbcef35ebb8b39..66d7d5271f10a0096500589c09b82a061dbcae4e 100644 (file)
@@ -13,7 +13,6 @@
 #define __ASM_H8300_PROCESSOR_H
 
 #include <linux/compiler.h>
-#include <asm/segment.h>
 #include <asm/ptrace.h>
 #include <asm/current.h>
 
diff --git a/arch/h8300/include/asm/segment.h b/arch/h8300/include/asm/segment.h
deleted file mode 100644 (file)
index 3795072..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _H8300_SEGMENT_H
-#define _H8300_SEGMENT_H
-
-/* define constants */
-#define USER_DATA     (1)
-#ifndef __USER_DS
-#define __USER_DS     (USER_DATA)
-#endif
-#define USER_PROGRAM  (2)
-#define SUPER_DATA    (3)
-#ifndef __KERNEL_DS
-#define __KERNEL_DS   (SUPER_DATA)
-#endif
-#define SUPER_PROGRAM (4)
-
-#ifndef __ASSEMBLY__
-
-typedef struct {
-       unsigned long seg;
-} mm_segment_t;
-
-#define MAKE_MM_SEG(s) ((mm_segment_t) { (s) })
-#define USER_DS                MAKE_MM_SEG(__USER_DS)
-#define KERNEL_DS      MAKE_MM_SEG(__KERNEL_DS)
-
-/*
- * Get/set the SFC/DFC registers for MOVES instructions
- */
-
-static inline mm_segment_t get_fs(void)
-{
-       return USER_DS;
-}
-
-#define uaccess_kernel()       (get_fs().seg == KERNEL_DS.seg)
-
-#endif /* __ASSEMBLY__ */
-
-#endif /* _H8300_SEGMENT_H */
index a518214d4ddd81f75e79a1d7fbb0fc106c681866..ff2d873749a4df6b1a059974b7248623a9e59d1a 100644 (file)
@@ -10,7 +10,6 @@
 #define _ASM_THREAD_INFO_H
 
 #include <asm/page.h>
-#include <asm/segment.h>
 
 #ifdef __KERNEL__
 
@@ -31,7 +30,6 @@ struct thread_info {
        unsigned long      flags;               /* low level flags */
        int                cpu;                 /* cpu we're on */
        int                preempt_count;       /* 0 => preemptable, <0 => BUG */
-       mm_segment_t            addr_limit;
 };
 
 /*
@@ -43,7 +41,6 @@ struct thread_info {
        .flags =        0,                      \
        .cpu =          0,                      \
        .preempt_count = INIT_PREEMPT_COUNT,    \
-       .addr_limit     = KERNEL_DS,            \
 }
 
 /* how to get the thread information struct from C */
index c6e289b5f1f284f4a5b3c11b8acba29bab3fa4c6..42db87c17917b794a917cf7886f94cc2a02bb6f2 100644 (file)
@@ -17,7 +17,6 @@
 #include <linux/sys.h>
 #include <asm/unistd.h>
 #include <asm/setup.h>
-#include <asm/segment.h>
 #include <asm/linkage.h>
 #include <asm/asm-offsets.h>
 #include <asm/thread_info.h>
index dbf8429f5fab5f91071242a059f159fbe92c0c62..489462f0ee57baa69315e35028a809d6e12adada 100644 (file)
@@ -4,7 +4,6 @@
 #include <linux/init.h>
 #include <asm/unistd.h>
 #include <asm/setup.h>
-#include <asm/segment.h>
 #include <asm/linkage.h>
 #include <asm/asm-offsets.h>
 #include <asm/thread_info.h>
index 1f3b345d68b97b9d71fb4276f6eab5c5294c6c66..3a2f006119f9bade4c66ff2f2fe55de006ffb616 100644 (file)
@@ -34,7 +34,6 @@
 #include <linux/gfp.h>
 
 #include <asm/setup.h>
-#include <asm/segment.h>
 #include <asm/page.h>
 #include <asm/sections.h>
 
@@ -71,11 +70,6 @@ void __init paging_init(void)
                panic("%s: Failed to allocate %lu bytes align=0x%lx\n",
                      __func__, PAGE_SIZE, PAGE_SIZE);
 
-       /*
-        * Set up SFC/DFC registers (user data space).
-        */
-       set_fs(USER_DS);
-
        pr_debug("before free_area_init\n");
 
        pr_debug("free_area_init -> start_mem is %#lx\nvirtual_end is %#lx\n",