From 74195b1b73367c10f79b8f5bb8b4e0c3bc585e0d Mon Sep 17 00:00:00 2001 From: cenhuilin Date: Tue, 2 Jul 2024 17:02:24 +0800 Subject: [PATCH] add loongarch64 support (cherry picked from commit a8191474086ede7b5718047c93779fde5d9a2843) --- ...-loongarch64-add-loongarch64-support.patch | 33 +++++++++++++++++++ iotop.spec | 6 +++- 2 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 0013-loongarch64-add-loongarch64-support.patch diff --git a/0013-loongarch64-add-loongarch64-support.patch b/0013-loongarch64-add-loongarch64-support.patch new file mode 100644 index 0000000..ab0f2eb --- /dev/null +++ b/0013-loongarch64-add-loongarch64-support.patch @@ -0,0 +1,33 @@ +From 0ab9bc45ab09d98e9d6db082c9ea384093c65c39 Mon Sep 17 00:00:00 2001 +From: cenhuilin +Date: Tue, 2 Jul 2024 16:52:03 +0800 +Subject: [PATCH] loongarch64: add loongarch64 support + +Signed-off-by: cenhuilin +--- + iotop/ioprio.py | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/iotop/ioprio.py b/iotop/ioprio.py +index ba804c8..5ff5f61 100644 +--- a/iotop/ioprio.py ++++ b/iotop/ioprio.py +@@ -27,6 +27,7 @@ import platform + # 'x86_64' but it will use the i386 syscall number, that's why we consider both + # the architecture name and the word size. + IOPRIO_GET_ARCH_SYSCALL = [ ++ ('loongarch64', '*', 31), + ('aarch64', '*', 31), + ('alpha', '*', 443), + ('arm*', '*', 315), +@@ -43,6 +44,7 @@ IOPRIO_GET_ARCH_SYSCALL = [ + ] + + IOPRIO_SET_ARCH_SYSCALL = [ ++ ('loongarch64', '*', 30), + ('aarch64', '*', 30), + ('alpha', '*', 442), + ('arm*', '*', 314), +-- +2.33.0 + diff --git a/iotop.spec b/iotop.spec index 57985a3..baa2720 100644 --- a/iotop.spec +++ b/iotop.spec @@ -1,6 +1,6 @@ Name: iotop Version: 0.6 -Release: 25 +Release: 26 Summary: Simple top-like I/O monitor License: GPLv2+ URL: http://guichaz.free.fr/iotop/ @@ -22,6 +22,7 @@ Patch9: 0009-Improve-the-message-that-is-printed-when-Linux-tasks.patch Patch10: 0010-Fix-crash-due-to-syntax-error.patch Patch11: 0011-Use-monotonic-time-to-calculate-durations.patch Patch12: 0012-riscv-Add-riscv64-support.patch +Patch13: 0013-loongarch64-add-loongarch64-support.patch %description iotop watches I/O usage information output by the Linux kernel (requires 2.6.20 or later) and @@ -59,6 +60,9 @@ This contains man files for the using of iotop %{_mandir}/man8/iotop.* %changelog +* Tue Jul 2 2024 cenhuilin - 0.6-26 +- loongarch64: add loongarch64 support + * Sun Sep 17 2023 Mingzheng Xing - 0.6-25 - riscv: Add riscv64 support