Skip to content

Archlinux Kernel based on different schedulers and some other performance improvements.

Add RT to cpusched option

Vasiliy Stelmachenokfea4e8730edd
diff --git a/linux-bore/PKGBUILD b/linux-bore/PKGBUILD
index 10a0d85a..ef433415 100644
--- a/linux-bore/PKGBUILD
+++ b/linux-bore/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-bore}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-bmq/PKGBUILD b/linux-cachyos-bmq/PKGBUILD
index ba3ec843..2a0b3907 100644
--- a/linux-cachyos-bmq/PKGBUILD
+++ b/linux-cachyos-bmq/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-bmq}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-bore/PKGBUILD b/linux-cachyos-bore/PKGBUILD
index dc679164..042d5364 100644
--- a/linux-cachyos-bore/PKGBUILD
+++ b/linux-cachyos-bore/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-bore}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-cfs/PKGBUILD b/linux-cachyos-cfs/PKGBUILD
index 0e3f168f..912673b2 100644
--- a/linux-cachyos-cfs/PKGBUILD
+++ b/linux-cachyos-cfs/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-cfs}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-eevdf/PKGBUILD b/linux-cachyos-eevdf/PKGBUILD
index ab0fecae..9e8bbd5f 100644
--- a/linux-cachyos-eevdf/PKGBUILD
+++ b/linux-cachyos-eevdf/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-eevdf}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-hardened/PKGBUILD b/linux-cachyos-hardened/PKGBUILD
index 2cbbd455..1786ceb5 100644
--- a/linux-cachyos-hardened/PKGBUILD
+++ b/linux-cachyos-hardened/PKGBUILD
@@ -253,6 +253,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler with latency_nice
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -332,6 +334,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened) scripts/config -e SCHED_BORE;;
cfs) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -440,16 +443,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-lts/PKGBUILD b/linux-cachyos-lts/PKGBUILD
index fa9a51c7..8a617fb3 100644
--- a/linux-cachyos-lts/PKGBUILD
+++ b/linux-cachyos-lts/PKGBUILD
@@ -257,6 +257,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler with latency_nice
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -335,6 +337,7 @@ prepare() {
bmq) scripts/config -e SCHED_ALT -e SCHED_BMQ -d SCHED_PDS;;
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened) scripts/config -e SCHED_BORE;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
cfs) ;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -444,16 +447,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-pds/PKGBUILD b/linux-cachyos-pds/PKGBUILD
index 1621041c..5f600033 100644
--- a/linux-cachyos-pds/PKGBUILD
+++ b/linux-cachyos-pds/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-pds}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-rc/PKGBUILD b/linux-cachyos-rc/PKGBUILD
index 2b5aacaa..bf05befc 100644
--- a/linux-cachyos-rc/PKGBUILD
+++ b/linux-cachyos-rc/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-cachyos}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-server/PKGBUILD b/linux-cachyos-server/PKGBUILD
index b974e85b..ccc64ac6 100644
--- a/linux-cachyos-server/PKGBUILD
+++ b/linux-cachyos-server/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-cfs}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos-tt/PKGBUILD b/linux-cachyos-tt/PKGBUILD
index 5d2bfa78..eb099a09 100644
--- a/linux-cachyos-tt/PKGBUILD
+++ b/linux-cachyos-tt/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-tt}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-cachyos/PKGBUILD b/linux-cachyos/PKGBUILD
index b84c181a..d70a9ffa 100644
--- a/linux-cachyos/PKGBUILD
+++ b/linux-cachyos/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-cachyos}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then
diff --git a/linux-tt/PKGBUILD b/linux-tt/PKGBUILD
index e6c6068e..f7e9f79c 100644
--- a/linux-tt/PKGBUILD
+++ b/linux-tt/PKGBUILD
@@ -19,6 +19,7 @@ _cachy_config=${_cachy_config-y}
# 'hardened' - select 'BORE Scheduler hardened' ## kernel with hardened config and hardening patches with the bore scheduler
# 'cachyos' - select 'EEVDF-BORE Variant Scheduler' EEVDF includes latency nice
# 'eevdf' - select 'EEVDF Scheduler' EEVDF includes latency nice
+# 'rt' - select CFS, but includes a series of realtime patches
_cpusched=${_cpusched-tt}
## Apply some suggested sysctl values from the bore developer
@@ -233,6 +234,8 @@ case "$_cpusched" in
bore) ## BORE Scheduler
[ -n "$_tune_bore" ] && source+=("${_patchsource}/misc/0001-bore-tuning-sysctl.patch")
source+=("${_patchsource}/sched/0001-bore-cachy.patch");;
+ rt) ## CFS with RT patches
+ source+=("${_patchsource}/misc/0001-rt.patch");;
hardened) ## Hardened Patches with BORE Scheduler
source+=("${_patchsource}/sched/0001-bore-cachy.patch"
"${_patchsource}/misc/0001-hardened.patch");;
@@ -309,6 +312,7 @@ prepare() {
tt) scripts/config -e TT_SCHED -e TT_ACCOUNTING_STATS;;
bore|hardened|cachyos) scripts/config -e SCHED_BORE;;
cfs|eevdf) ;;
+ rt) scripts/config -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPT_NONE -e PREEMPT_RT -e PREEMPT_LAZY -d PREEMPT_DYNAMIC -e HAVE_PREEMPT_LAZY -d PREEMPT_BUILD;;
*) _die "The value $_cpusched is invalid. Choose the correct one again.";;
esac
@@ -408,16 +412,20 @@ prepare() {
echo "Selecting '$_tickrate' tick type..."
### Select preempt type
- [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
- case "$_preempt" in
- full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
- voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
- server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
- *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
- esac
+ # We should not set up the PREEMPT for RT kernels
+ if [ "$_cpusched" != "rt" ]; then
+ [ -z "$_preempt" ] && _die "The value is empty. Choose the correct one again."
+
+ case "$_preempt" in
+ full) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -d PREEMPT_VOLUNTARY -e PREEMPT -e PREEMPT_COUNT -e PREEMPTION -e PREEMPT_DYNAMIC;;
+ voluntary) scripts/config -e PREEMPT_BUILD -d PREEMPT_NONE -e PREEMPT_VOLUNTARY -d PREEMPT -e PREEMPT_COUNT -e PREEMPTION -d PREEMPT_DYNAMIC;;
+ server) scripts/config -e PREEMPT_NONE_BUILD -e PREEMPT_NONE -d PREEMPT_VOLUNTARY -d PREEMPT -d PREEMPTION -d PREEMPT_DYNAMIC;;
+ *) _die "The value '$_preempt' is invalid. Choose the correct one again.";;
+ esac
- echo "Selecting '$_preempt' preempt type..."
+ echo "Selecting '$_preempt' preempt type..."
+ fi
### Enable O3
if [ -n "$_cc_harder" ] && [ -z "$_cc_size" ]; then