From nobody Fri Dec 19 19:17:12 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7FD71CE79A7 for ; Mon, 25 Sep 2023 22:41:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233111AbjIYWll (ORCPT ); Mon, 25 Sep 2023 18:41:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33964 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229481AbjIYWli (ORCPT ); Mon, 25 Sep 2023 18:41:38 -0400 Received: from bg4.exmail.qq.com (bg4.exmail.qq.com [43.155.65.254]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A4F8111C; Mon, 25 Sep 2023 15:41:31 -0700 (PDT) X-QQ-mid: bizesmtp64t1695681678tnvf3nwx Received: from linux-lab-host.localdomain ( [116.30.124.152]) by bizesmtp.qq.com (ESMTP) with id ; Tue, 26 Sep 2023 06:41:16 +0800 (CST) X-QQ-SSF: 01200000002000E0Y000B00A0000000 X-QQ-FEAT: 3M0okmaRx3gfsSflpNrVeZ3sLICSqSaF1U3sraXTLgAlViLSauDfSqqDtpoNW SpJ9yhtzh6PzBUapWeOX0uRrrOAx/YDjuGcAV/ElqISXdLVJrgKYLDHpCpA9o8pTr1UJmAp TZpLJKkg5BgsLqXJA7AyPqGQd4uo4wJ9kG/PcrwaYQDKWoXQAHmyI48DbJyB9TrgDn6MwV1 xAbDs/bktubgubuWpp3z5BZzxdTfsdxIyMEd653QAHjXk0VSw0QgkTt/ZwID4tddHr20MU5 IBenNgCrBRJGf1SYzfyD/v+sJ8AofWpCIgALXUucwYI6Z1XoKE8OaZJ5OVSdOUqOPo7jhE0 8L83kEBlrjALbS9Xe1VQFAawPyge85zIGnGGzgYOddDAkAAqjslJdveiZm9lYGNaojrQbrE X-QQ-GoodBg: 0 X-BIZMAIL-ID: 2541803507469492191 From: Zhangjin Wu To: linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org, Arnd Bergmann Cc: falcon@tinylab.org, palmer@rivosinc.com, paul.walmsley@sifive.com, paulburton@kernel.org, paulmck@kernel.org, tsbogend@alpha.franken.de, w@1wt.eu, =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= , Tim Bird Subject: [PATCH v1 5/7] DCE/DSE: riscv: move syscall tables to syscalls/ Date: Tue, 26 Sep 2023 06:41:16 +0800 Message-Id: X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:tinylab.org:qybglogicsvrgz:qybglogicsvrgz5a-1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Both syscall table and compat syscall table share some dead syscalls elimination code, to avoid cluttering the main RISC-V kernel Makefile, let's move these tables and the corresponding compile settings to syscalls/. Signed-off-by: Zhangjin Wu --- arch/riscv/kernel/Makefile | 5 +---- arch/riscv/kernel/syscalls/Makefile | 10 ++++++++++ .../riscv/kernel/{ =3D> syscalls}/compat_syscall_table.c | 0 arch/riscv/kernel/{ =3D> syscalls}/syscall_table.c | 0 4 files changed, 11 insertions(+), 4 deletions(-) create mode 100644 arch/riscv/kernel/syscalls/Makefile rename arch/riscv/kernel/{ =3D> syscalls}/compat_syscall_table.c (100%) rename arch/riscv/kernel/{ =3D> syscalls}/syscall_table.c (100%) diff --git a/arch/riscv/kernel/Makefile b/arch/riscv/kernel/Makefile index 95cf25d48405..40aebbf06880 100644 --- a/arch/riscv/kernel/Makefile +++ b/arch/riscv/kernel/Makefile @@ -8,8 +8,6 @@ CFLAGS_REMOVE_ftrace.o =3D $(CC_FLAGS_FTRACE) CFLAGS_REMOVE_patch.o =3D $(CC_FLAGS_FTRACE) CFLAGS_REMOVE_sbi.o =3D $(CC_FLAGS_FTRACE) endif -CFLAGS_syscall_table.o +=3D $(call cc-option,-Wno-override-init,) -CFLAGS_compat_syscall_table.o +=3D $(call cc-option,-Wno-override-init,) =20 ifdef CONFIG_KEXEC AFLAGS_kexec_relocate.o :=3D -mcmodel=3Dmedany $(call cc-option,-mno-relax) @@ -48,7 +46,7 @@ obj-y +=3D ptrace.o obj-y +=3D reset.o obj-y +=3D setup.o obj-y +=3D signal.o -obj-y +=3D syscall_table.o +obj-y +=3D syscalls/ obj-y +=3D sys_riscv.o obj-y +=3D time.o obj-y +=3D traps.o @@ -95,7 +93,6 @@ obj-$(CONFIG_JUMP_LABEL) +=3D jump_label.o obj-$(CONFIG_CFI_CLANG) +=3D cfi.o =20 obj-$(CONFIG_EFI) +=3D efi.o -obj-$(CONFIG_COMPAT) +=3D compat_syscall_table.o obj-$(CONFIG_COMPAT) +=3D compat_signal.o obj-$(CONFIG_COMPAT) +=3D compat_vdso/ =20 diff --git a/arch/riscv/kernel/syscalls/Makefile b/arch/riscv/kernel/syscal= ls/Makefile new file mode 100644 index 000000000000..65abd0871ee5 --- /dev/null +++ b/arch/riscv/kernel/syscalls/Makefile @@ -0,0 +1,10 @@ +# SPDX-License-Identifier: GPL-2.0-only +# +# Makefile for the RISC-V syscall tables +# + +CFLAGS_syscall_table.o +=3D $(call cc-option,-Wno-override-init,) +CFLAGS_compat_syscall_table.o +=3D $(call cc-option,-Wno-override-init,) + +obj-y +=3D syscall_table.o +obj-$(CONFIG_COMPAT) +=3D compat_syscall_table.o diff --git a/arch/riscv/kernel/compat_syscall_table.c b/arch/riscv/kernel/s= yscalls/compat_syscall_table.c similarity index 100% rename from arch/riscv/kernel/compat_syscall_table.c rename to arch/riscv/kernel/syscalls/compat_syscall_table.c diff --git a/arch/riscv/kernel/syscall_table.c b/arch/riscv/kernel/syscalls= /syscall_table.c similarity index 100% rename from arch/riscv/kernel/syscall_table.c rename to arch/riscv/kernel/syscalls/syscall_table.c --=20 2.25.1