From f2c9b91a2ac15ee70f1f7ea9a8d2297d70406b35 Mon Sep 17 00:00:00 2001 From: xdavidwu Date: Thu, 20 Jul 2023 12:03:50 +0800 Subject: [PATCH] remove failed clr patches, sync with clr --- 0105-ksm-wakeups.patch | 52 -------------------- 0119-use-lfence-instead-of-rep-and-nop.patch | 25 ---------- 0133-novector.patch | 2 +- APKBUILD | 4 -- 4 files changed, 1 insertion(+), 82 deletions(-) delete mode 100644 0105-ksm-wakeups.patch delete mode 100644 0119-use-lfence-instead-of-rep-and-nop.patch diff --git a/0105-ksm-wakeups.patch b/0105-ksm-wakeups.patch deleted file mode 100644 index 712690d..0000000 --- a/0105-ksm-wakeups.patch +++ /dev/null @@ -1,52 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Arjan van de Ven -Date: Mon, 6 May 2019 12:57:09 -0500 -Subject: [PATCH] ksm-wakeups - -reduce wakeups in ksm by adding rounding (aligning) when -the sleep times are 1 second or longer - -Signed-off-by: Arjan van de Ven ---- - kernel/watchdog.c | 2 +- - mm/ksm.c | 11 ++++++++--- - 2 files changed, 9 insertions(+), 4 deletions(-) - -diff --git a/kernel/watchdog.c b/kernel/watchdog.c -index 99afb88d2e85..e24483521e17 100644 ---- a/kernel/watchdog.c -+++ b/kernel/watchdog.c -@@ -41,7 +41,7 @@ unsigned long __read_mostly watchdog_enabled; - int __read_mostly watchdog_user_enabled = 1; - int __read_mostly nmi_watchdog_user_enabled = NMI_WATCHDOG_DEFAULT; - int __read_mostly soft_watchdog_user_enabled = 1; --int __read_mostly watchdog_thresh = 10; -+int __read_mostly watchdog_thresh = 40; - static int __read_mostly nmi_watchdog_available; - - struct cpumask watchdog_cpumask __read_mostly; -diff --git a/mm/ksm.c b/mm/ksm.c -index c20bd4d9a0d9..702a2a111fef 100644 ---- a/mm/ksm.c -+++ b/mm/ksm.c -@@ -2421,9 +2421,14 @@ static int ksm_scan_thread(void *nothing) - - if (ksmd_should_run()) { - sleep_ms = READ_ONCE(ksm_thread_sleep_millisecs); -- wait_event_interruptible_timeout(ksm_iter_wait, -- sleep_ms != READ_ONCE(ksm_thread_sleep_millisecs), -- msecs_to_jiffies(sleep_ms)); -+ if (sleep_ms >= 1000) -+ wait_event_interruptible_timeout(ksm_iter_wait, -+ sleep_ms != READ_ONCE(ksm_thread_sleep_millisecs), -+ msecs_to_jiffies(round_jiffies_relative(sleep_ms))); -+ else -+ wait_event_interruptible_timeout(ksm_iter_wait, -+ sleep_ms != READ_ONCE(ksm_thread_sleep_millisecs), -+ msecs_to_jiffies(sleep_ms)); - } else { - wait_event_freezable(ksm_thread_wait, - ksmd_should_run() || kthread_should_stop()); --- -https://clearlinux.org - diff --git a/0119-use-lfence-instead-of-rep-and-nop.patch b/0119-use-lfence-instead-of-rep-and-nop.patch deleted file mode 100644 index 463f384..0000000 --- a/0119-use-lfence-instead-of-rep-and-nop.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Arjan van de Ven -Date: Sat, 8 Dec 2018 18:21:32 +0000 -Subject: [PATCH] use lfence instead of rep and nop - ---- - arch/x86/include/asm/vdso/processor.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/arch/x86/include/asm/vdso/processor.h b/arch/x86/include/asm/vdso/processor.h -index 57b1a7034c64..e2c45674f989 100644 ---- a/arch/x86/include/asm/vdso/processor.h -+++ b/arch/x86/include/asm/vdso/processor.h -@@ -10,7 +10,7 @@ - /* REP NOP (PAUSE) is a good thing to insert into busy-wait loops. */ - static __always_inline void rep_nop(void) - { -- asm volatile("rep; nop" ::: "memory"); -+ asm volatile("lfence" ::: "memory"); - } - - static __always_inline void cpu_relax(void) --- -https://clearlinux.org - diff --git a/0133-novector.patch b/0133-novector.patch index 533b932..9e8391e 100644 --- a/0133-novector.patch +++ b/0133-novector.patch @@ -18,7 +18,7 @@ index 415a5d138de4..6b91d1306a7c 100644 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53383 # -KBUILD_CFLAGS += -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -+KBUILD_CFLAGS += -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -mno-avx2 -O3 -fno-tree-vectorize -march=westmere -mpopcnt ++KBUILD_CFLAGS += -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -mno-avx2 -O3 -fno-tree-vectorize -march=westmere -mpopcnt KBUILD_RUSTFLAGS += -Ctarget-feature=-sse,-sse2,-sse3,-ssse3,-sse4.1,-sse4.2,-avx,-avx2 ifeq ($(CONFIG_X86_KERNEL_IBT),y) diff --git a/APKBUILD b/APKBUILD index 81bd1d2..12850bc 100644 --- a/APKBUILD +++ b/APKBUILD @@ -20,7 +20,6 @@ source="https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-${pkgver}.tar.xz 0102-increase-the-ext4-default-commit-age.patch 0103-silence-rapl.patch 0104-pci-pme-wakeups.patch - 0105-ksm-wakeups.patch 0106-intel_idle-tweak-cpuidle-cstates.patch 0108-smpboot-reuse-timer-calibration.patch 0109-initialize-ata-before-graphics.patch @@ -29,7 +28,6 @@ source="https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-${pkgver}.tar.xz 0115-enable-stateless-firmware-loading.patch 0116-migrate-some-systemd-defaults-to-the-kernel-defaults.patch 0118-add-scheduler-turbo3-patch.patch - 0119-use-lfence-instead-of-rep-and-nop.patch 0120-do-accept-in-LIFO-order-for-cache-efficiency.patch 0121-locking-rwsem-spin-faster.patch 0122-ata-libahci-ignore-staggered-spin-up.patch @@ -65,7 +63,6 @@ b2de23b9f86fc670537f432cd0b141e28d6da1b879a3a6457b8597699ed8e55df5f44df014df3d6c edc8a2d463dc15ace6016b8da96c0de284a280534eade094c5fa6717760eed9ecdb90068bf0fa3db10bf246641615b8300ab5a7e25641cc43bb99a3fbd8bc000 0102-increase-the-ext4-default-commit-age.patch e5eed79203bdb7fe709919a093d382250d353368011cd6bd144bdff01d6d97110356bc05b0ac03f9e08f2ff6fdcd216ea727cc48d782433788a68ccbd02ed160 0103-silence-rapl.patch 303504654b1747c3aa923825ab67e48114edb9388b1f2ff897f1d1b18376b0c1b03c3d34dcd029ee78889a50310e7ae551272cd3b0c3240fc703847664ce6c43 0104-pci-pme-wakeups.patch -9bab4a38124d970bdf4d56ef4c288a9bdab4164b7fe5eb40dd3bbf833afd0d50b9e5afec3fc06c8c467f3e20011c7e5678b8241abd52df083b544f77afb4e4f9 0105-ksm-wakeups.patch 5483799f084b7a7c63660d9b9c0f392eaf734221b8e55480177aee06c0a24481008f74f33c3e9252e9c5982065918af7304d6786d7e7d2685d24ef92b958d7f2 0106-intel_idle-tweak-cpuidle-cstates.patch 828d66bb480dd974cfaa3b89e4839195ce6d24e37f39ba35e7a0c13a062f137b6875c2f9051384f4e7a51bf2f3b44e988ec1b8a310fdafff8b9dc77b34f59b6c 0108-smpboot-reuse-timer-calibration.patch 42b65217790ac6a699c92b763b80f6ea26e1d80d977ff65c5093919ef16d783ef06121ff0a061b9a78b6d32f234dac439f908ddafa6d15cc3b3dd12bdd477c78 0109-initialize-ata-before-graphics.patch @@ -74,7 +71,6 @@ e5eed79203bdb7fe709919a093d382250d353368011cd6bd144bdff01d6d97110356bc05b0ac03f9 6e202984fefa1969a0bf6063b33e6fdd6d7e31917369edbf45b42e0a985721fd465252b235812780722f7163466314cd71810ae884f66c67567e4e26adee28aa 0115-enable-stateless-firmware-loading.patch ead629b352126972268e96e6f0b34b558b96fbc9d0efbb7b6c560671fe61c97272492509f190b682c2b7db0da485886a941f58a502d72095c208e492f2f4ccd0 0116-migrate-some-systemd-defaults-to-the-kernel-defaults.patch 95e56d6a221ba6e5392ae53a136c9411fbc46e97f00ed87166527cf5bd54b13652a615dbcd318edc5c2242338088468400a3a47ec107952d03d78a4eb624bba0 0118-add-scheduler-turbo3-patch.patch -027832a5a2e671095460bf069d9a9c02dbf015956938f21bfa3c400aa53be81c75ce367fcc77a82e01bd10ce2f89f2df54bb8ca321ff9cca6d31d69c89dd4353 0119-use-lfence-instead-of-rep-and-nop.patch 66cea1c904f3642bc23b0a609564b1bfb6b36dda2f927145354659b59ffaf412ccdf5ffaf37197edaf07a6be1ea5a5ace21007a883df41d6877264d734dd30f7 0120-do-accept-in-LIFO-order-for-cache-efficiency.patch c0ee48709ba1e70e0c4fa99f7a41514f629db6383febf4e067fa452ac10b4de57a31a5955fdc654e739e6e46656b788ebc10ce89efe382b7533fd9a6e4774b89 0121-locking-rwsem-spin-faster.patch d406b33ccc8ca6c2a0c5e8b32889a059ddbac68ec2e0ebc30251fc90f0784ceca21a25a25b09cff390593d2cc797df5c1620a323e6384e120ab91cd5b7a5108a 0122-ata-libahci-ignore-staggered-spin-up.patch -- 2.45.2