Skip to content

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

5.19.rc3-1

Peter Jungc6db5a8bee96
diff --git a/linux-cachyos-rc/.SRCINFO b/linux-cachyos-rc/.SRCINFO
index a719b0df..32b4954a 100755
--- a/linux-cachyos-rc/.SRCINFO
+++ b/linux-cachyos-rc/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = linux-cachyos-rc
pkgdesc = Linux CFS scheduler Kernel by CachyOS and with some other patches and other improvements
- pkgver = 5.19.rc2
- pkgrel = 2
+ pkgver = 5.19.rc3
+ pkgrel = 1
url = https://github.com/CachyOS/linux-cachyos
arch = x86_64
arch = x86_64_v3
@@ -24,31 +24,27 @@ pkgbase = linux-cachyos-rc
makedepends = make
makedepends = patch
options = !strip
- source = https://github.com/torvalds/linux/archive/refs/tags/v5.19-rc2.tar.gz
+ source = https://github.com/torvalds/linux/archive/refs/tags/v5.19-rc3.tar.gz
source = config
+ source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-cachy.patch
source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/sched/0001-bore-5.19.patch
- source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-arch.patch
source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-bbr2.patch
- source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-cachy.patch
- source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-cpu.patch
source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-Extend-DAMOS-for-Proactive-LRU-lists-Sorting.patch
source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-MG-LRU-v12.patch
+ source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-rcu.patch
+ source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-xfs-async-buffered.patch
source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-futex-winesync.patch
- source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-ksm.patch
- source = https://raw.githubusercontent.com/ptr1337/kernel-patches/master/5.19/0001-zram-entropy-calculation.patch
source = auto-cpu-optimization.sh
- sha256sums = 530cb48a3bd084367d65f89a3e52af90676e155a65c39d3967726a5a4337339b
- sha256sums = d7d8bb7c2183700b1ca07e4c8365ea668ac036b9978cf02848596002607ffe68
+ sha256sums = d38da4f2094651d1ee766e864982df2433af33daed0b7bd159c52e2fa9d5f1cd
+ sha256sums = 45c25965fa5f04ddc479e8a79dd409063749140a2f5573caebb35b41ad1b3e42
+ sha256sums = 97b7a140f84774e8313ba7f9c8404ce90e029d347b6a189c71854571ab3330ba
sha256sums = 7a36fe0a53a644ade0ce85f08f9ca2ebaddd47876966b7cc9d4cae8844649271
- sha256sums = 8cb5f04d2b4da0db29cac021f97152e2eb2346547685f49532c1e352be05fb4a
sha256sums = 9975135d105b69a2efec4a868ce3a4aaf3ffeda5841dc9e6601858d0773e8829
- sha256sums = fb091f718c8e683c158dc0d3f3aa8f80f8dfd710f09da257e6bc5a418e16c2b9
- sha256sums = a3befe7b001470decc08b1e7cae0e436b5bc355c2f2b43148c6ab30ed9821ec7
sha256sums = 826c20a4bdd642d41147edeb801e32041db1c6aabf2b3a74306f333dcf3a3054
sha256sums = 7c486f166c9de16a661233ef2a72c55a27629563e8e6c52e54a3f2f617b2ac62
+ sha256sums = 325e282dcb0786090584267f9b1ed5646128a5a88f061850e24f900ea495a1e9
+ sha256sums = 2346332059809e82c60b3bc988966e2cda08428a0239b4eb4c04e8e1b6cbe576
sha256sums = 7cf2e27ae7ca49c8d20a6c10b0a34187f8c63f2dab3063b3649a692d65065fad
- sha256sums = f94ee42a540d935c3fa05d27485b7f6b66d6220ea2e603db8a3d9ca55e19f7ef
- sha256sums = f31972b5cdb0a9ffebe63070ce5706b9d28e47c96f5979820b3fb57f236a93bf
sha256sums = ce8bf7807b45a27eed05a5e1de5a0bf6293a3bbc2085bacae70cd1368f368d1f
pkgname = linux-cachyos-rc
@@ -60,15 +56,12 @@ pkgname = linux-cachyos-rc
optdepends = linux-firmware: firmware images needed for some devices
optdepends = modprobed-db: Keeps track of EVERY kernel module that has ever been probed - useful for those of us who make localmodconfig
optdepends = uksmd: Userspace KSM helper daemon
- optdepends = zfs-utils
provides = VIRTUALBOX-GUEST-MODULES
provides = WIREGUARD-MODULE
provides = KSMBD-MODULE
provides = UKSMD-BUILTIN
- provides = linux-cachyos-rc-zfs
pkgname = linux-cachyos-rc-headers
pkgdesc = Headers and scripts for building modules for the Linux CFS scheduler Kernel by CachyOS and with some other patches and other improvements kernel
depends = pahole
- provides = zfs-headers
- provides = spl-headers
+ depends = linux-cachyos-rc
diff --git a/linux-cachyos-rc/PKGBUILD b/linux-cachyos-rc/PKGBUILD
index cb44292e..676f570d 100644
--- a/linux-cachyos-rc/PKGBUILD
+++ b/linux-cachyos-rc/PKGBUILD
@@ -45,7 +45,7 @@ _localmodcfg=
_use_current=
### Enable KBUILD_CFLAGS -O3
-_cc_harder=yy
+_cc_harder=y
### Set performance governor as default
_per_gov=y
@@ -95,7 +95,7 @@ _processor_opt=
_use_auto_optimization=y
# disable debug to lower the size of the kernel
-_disable_debug=
+_disable_debug=y
## Enable zram/zswap ZSTD compression
_zstd_compression=y
@@ -107,9 +107,6 @@ _nf_cone=y
# "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full."
_use_llvm_lto=
-## Change the thin lto cachedir for fixing building several dkms modules including zfs
-_thin_lto_cachedir=
-
# KCFI is a proposed forward-edge control-flow integrity scheme for
# Clang, which is more suitable for kernel use than the existing CFI
# scheme used by CONFIG_CFI_CLANG. KCFI doesn't require LTO, doesn't
@@ -120,9 +117,10 @@ _thin_lto_cachedir=
# The packagename is called "llvm-kcfi"
_use_kcfi=
-# Build the zfs module builtin in to the kernel only works with GCC!
+# Build the zfs module builtin in to the kernel
_build_zfs=
+
if [ -n "$_use_llvm_lto" ]; then
pkgsuffix=cachyos-rc-lto
pkgbase=linux-$pkgsuffix
@@ -134,7 +132,7 @@ fi
_major=5.19
_minor=0
#_minorc=$((_minor+1))
-_rcver=rc2
+_rcver=rc3
pkgver=${_major}.${_rcver}
#_stable=${_major}.${_minor}
#_stable=${_major}
@@ -143,7 +141,7 @@ _srcname=linux-${_stable}
#_srcname=linux-${_major}
arch=(x86_64 x86_64_v3)
pkgdesc='Linux CFS scheduler Kernel by CachyOS and with some other patches and other improvements'
-pkgrel=2
+pkgrel=1
_kernver=$pkgver-$pkgrel
arch=('x86_64' 'x86_64_v3')
url="https://github.com/CachyOS/linux-cachyos"
@@ -162,7 +160,8 @@ fi
_patchsource="https://raw.githubusercontent.com/ptr1337/kernel-patches/master/${_major}"
source=(
"https://github.com/torvalds/linux/archive/refs/tags/v${_major}-${_rcver}.tar.gz"
-"config")
+ "config"
+ "${_patchsource}/0001-cachy.patch")
if [ "$_cpusched" = "bmq" ]; then
source+=("${_patchsource}/sched/0001-prjc-5.19.patch")
fi
@@ -189,18 +188,15 @@ if [ "$_cpusched" = "hardened" ]; then
"${_patchsource}/sched/0001-bore-5.19.patch"
"${_patchsource}/0001-migrate.patch"
"${_patchsource}/0001-hardening.patch"
- "${_patchsource}/0001-hardened.patch")
+ "${_patchsource}/0001-hardened.patch")
fi
source+=(
- "${_patchsource}/0001-arch.patch"
"${_patchsource}/0001-bbr2.patch"
- "${_patchsource}/0001-cachy.patch"
- "${_patchsource}/0001-cpu.patch"
"${_patchsource}/0001-Extend-DAMOS-for-Proactive-LRU-lists-Sorting.patch"
"${_patchsource}/0001-MG-LRU-v12.patch"
+ "${_patchsource}/0001-rcu.patch"
+ "${_patchsource}/0001-xfs-async-buffered.patch"
"${_patchsource}/0001-futex-winesync.patch"
- "${_patchsource}/0001-ksm.patch"
- "${_patchsource}/0001-zram-entropy-calculation.patch"
"auto-cpu-optimization.sh"
)
@@ -224,7 +220,7 @@ export KBUILD_BUILD_TIMESTAMP="$(date -Ru${SOURCE_DATE_EPOCH:+d @$SOURCE_DATE_EP
prepare() {
- cd $_srcname
+ cd ${srcdir}/$_srcname
echo "Setting version..."
scripts/setlocalversion --save-scmversion
@@ -621,6 +617,9 @@ prepare() {
fi
fi
+ ### Rewrite configuration
+ echo "Rewrite configuration..."
+ make ${BUILD_FLAGS[*]} prepare
yes "" | make ${BUILD_FLAGS[*]} config >/dev/null
diff -u ../config .config || :
@@ -628,27 +627,12 @@ prepare() {
make ${BUILD_FLAGS[*]} -s kernelrelease > version
echo "Prepared $pkgbase version $(<version)"
- ### Rewrite configuration
- echo "Rewrite configuration..."
- make ${BUILD_FLAGS[*]} prepare
- if [ -n "$_build_zfs" ]; then
- # KERNEL_CC="-fno-lto"
- cd "${srcdir}/zfs"
- ./autogen.sh
- ./configure --with-linux=${srcdir}/$_srcname \
- --with-linux-obj=${srcdir}/$_srcname --enable-linux-builtin \
- --prefix=$pkgdir/usr/lib/modules/$(<version)/build --exec-prefix=$pkgdir/usr/lib/modules/$(<version)/build \
- --with-config=kernel --enable-systemd
- ./copy-builtin ${srcdir}/$_srcname
- cd ${srcdir}/$_srcname
- scripts/config --enable CONFIG_ZFS
- fi
### Running make nconfig
[[ -z "$_makenconfig" ]] || make ${BUILD_FLAGS[*]} nconfig
### Save configuration for later reuse
echo "Save configuration for later reuse..."
- cat .config > "${startdir}/config.last"
+ cat .config > "${startdir}/config-${pkgver}-${pkgrel}${pkgbase#linux}"
### Save configuration for later reuse
# cp -Tf ./.config "${startdir}/config-${pkgver}-${pkgrel}${pkgbase#linux}"
@@ -656,9 +640,29 @@ prepare() {
}
build() {
-
- cd ${srcdir}/$_srcname
+ cd ${srcdir}/${_srcname}
make ${BUILD_FLAGS[*]} -j$(nproc) all
+
+ if [ -n "$_build_zfs" ]; then
+ cd ${srcdir}/"zfs"
+
+ if [ -n "$_use_llvm_lto" ]; then
+ ./autogen.sh
+ sed -i "s|\$(uname -r)|${pkgver}-${pkgsuffix}|g" configure
+ ./configure KERNEL_LLVM=1 --prefix=/usr --sysconfdir=/etc --sbindir=/usr/bin --libdir=/usr/lib \
+ --datadir=/usr/share --includedir=/usr/include --with-udevdir=/lib/udev \
+ --libexecdir=/usr/lib/zfs --with-config=kernel \
+ --with-linux=${srcdir}/$_srcname
+ else
+ ./autogen.sh
+ sed -i "s|\$(uname -r)|${pkgver}-${pkgsuffix}|g" configure
+ ./configure --prefix=/usr --sysconfdir=/etc --sbindir=/usr/bin --libdir=/usr/lib \
+ --datadir=/usr/share --includedir=/usr/include --with-udevdir=/lib/udev \
+ --libexecdir=/usr/lib/zfs --with-config=kernel \
+ --with-linux=${srcdir}/$_srcname
+ fi
+ make ${BUILD_FLAGS[*]}
+ fi
}
_package() {
@@ -669,12 +673,8 @@ _package() {
'modprobed-db: Keeps track of EVERY kernel module that has ever been probed - useful for those of us who make localmodconfig'
'uksmd: Userspace KSM helper daemon')
provides=(VIRTUALBOX-GUEST-MODULES WIREGUARD-MODULE KSMBD-MODULE UKSMD-BUILTIN)
- if [ -n "$_build_zfs" ]; then
- provides+=($pkgbase-zfs)
- optdepends+=('zfs-utils')
- fi
- cd $_srcname
+ cd ${srcdir}/$_srcname
local kernver="$(<version)"
local modulesdir="$pkgdir/usr/lib/modules/$kernver"
@@ -697,12 +697,9 @@ _package() {
_package-headers() {
pkgdesc="Headers and scripts for building modules for the $pkgdesc kernel"
- depends=(pahole)
- if [ -n "$_build_zfs" ]; then
- provides=("zfs-headers" "spl-headers")
- fi
+ depends=('pahole' linux-${pkgsuffix} )
- cd ${_srcname}
+ cd ${srcdir}/${_srcname}
local builddir="$pkgdir/usr/lib/modules/$(<version)/build"
echo "Installing build files..."
@@ -782,7 +779,21 @@ _package-headers() {
ln -sr "$builddir" "$pkgdir/usr/src/$pkgbase"
}
+_package-zfs(){
+ pkgdesc="zfs module for the $pkgdesc kernel"
+ depends=('pahole' linux-$pkgsuffix=$_kernver)
+
+ cd ${srcdir}/"zfs"
+ install -dm755 "$pkgdir/usr/lib/modules/${_kernver}-${pkgsuffix}"
+ install -m644 module/*/*.ko "$pkgdir/usr/lib/modules/${_kernver}-${pkgsuffix}"
+ find "$pkgdir" -name '*.ko' -exec zstd --rm -10 {} +
+ # sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${pkgver}-${pkgbase}'/" "$startdir/zfs.install"
+}
+
pkgname=("$pkgbase" "$pkgbase-headers")
+if [ -n "$_build_zfs" ]; then
+ pkgname+=("$pkgbase-zfs")
+fi
for _p in "${pkgname[@]}"; do
eval "package_$_p() {
$(declare -f "_package${_p#$pkgbase}")
@@ -790,16 +801,14 @@ for _p in "${pkgname[@]}"; do
}"
done
-sha256sums=('530cb48a3bd084367d65f89a3e52af90676e155a65c39d3967726a5a4337339b'
- 'd7d8bb7c2183700b1ca07e4c8365ea668ac036b9978cf02848596002607ffe68'
+sha256sums=('d38da4f2094651d1ee766e864982df2433af33daed0b7bd159c52e2fa9d5f1cd'
+ '45c25965fa5f04ddc479e8a79dd409063749140a2f5573caebb35b41ad1b3e42'
+ '97b7a140f84774e8313ba7f9c8404ce90e029d347b6a189c71854571ab3330ba'
'7a36fe0a53a644ade0ce85f08f9ca2ebaddd47876966b7cc9d4cae8844649271'
- '8cb5f04d2b4da0db29cac021f97152e2eb2346547685f49532c1e352be05fb4a'
'9975135d105b69a2efec4a868ce3a4aaf3ffeda5841dc9e6601858d0773e8829'
- 'fb091f718c8e683c158dc0d3f3aa8f80f8dfd710f09da257e6bc5a418e16c2b9'
- 'a3befe7b001470decc08b1e7cae0e436b5bc355c2f2b43148c6ab30ed9821ec7'
'826c20a4bdd642d41147edeb801e32041db1c6aabf2b3a74306f333dcf3a3054'
'7c486f166c9de16a661233ef2a72c55a27629563e8e6c52e54a3f2f617b2ac62'
+ '325e282dcb0786090584267f9b1ed5646128a5a88f061850e24f900ea495a1e9'
+ '2346332059809e82c60b3bc988966e2cda08428a0239b4eb4c04e8e1b6cbe576'
'7cf2e27ae7ca49c8d20a6c10b0a34187f8c63f2dab3063b3649a692d65065fad'
- 'f94ee42a540d935c3fa05d27485b7f6b66d6220ea2e603db8a3d9ca55e19f7ef'
- 'f31972b5cdb0a9ffebe63070ce5706b9d28e47c96f5979820b3fb57f236a93bf'
'ce8bf7807b45a27eed05a5e1de5a0bf6293a3bbc2085bacae70cd1368f368d1f')
diff --git a/linux-cachyos-rc/config b/linux-cachyos-rc/config
index ef6d7185..00a80c70 100644
--- a/linux-cachyos-rc/config
+++ b/linux-cachyos-rc/config
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.19.0-rc1 Kernel Configuration
+# Linux/x86 5.19.0-rc3 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (GCC) 12.1.0"
CONFIG_CC_IS_GCC=y
@@ -202,6 +202,7 @@ CONFIG_ARCH_SUPPORTS_NUMA_BALANCING=y
CONFIG_ARCH_WANT_BATCHED_UNMAP_TLB_FLUSH=y
CONFIG_CC_HAS_INT128=y
CONFIG_CC_IMPLICIT_FALLTHROUGH="-Wimplicit-fallthrough=5"
+CONFIG_GCC12_NO_ARRAY_BOUNDS=y
CONFIG_ARCH_SUPPORTS_INT128=y
CONFIG_NUMA_BALANCING=y
CONFIG_NUMA_BALANCING_DEFAULT_ENABLED=y
@@ -7256,9 +7257,11 @@ CONFIG_SND_SOC_CS35L41_LIB=m
CONFIG_SND_SOC_CS35L41=m
CONFIG_SND_SOC_CS35L41_SPI=m
CONFIG_SND_SOC_CS35L41_I2C=m
-CONFIG_SND_SOC_CS42L42=m
+CONFIG_SND_SOC_CS35L45_TABLES=m
+CONFIG_SND_SOC_CS35L45=m
CONFIG_SND_SOC_CS35L45_SPI=m
CONFIG_SND_SOC_CS35L45_I2C=m
+CONFIG_SND_SOC_CS42L42=m
CONFIG_SND_SOC_CS42L51=m
CONFIG_SND_SOC_CS42L51_I2C=m
CONFIG_SND_SOC_CS42L52=m
@@ -8610,6 +8613,7 @@ CONFIG_XEN_SYMS=y
CONFIG_XEN_HAVE_VPMU=y
CONFIG_XEN_FRONT_PGDIR_SHBUF=m
CONFIG_XEN_UNPOPULATED_ALLOC=y
+# CONFIG_XEN_VIRTIO is not set
# end of Xen driver support
# CONFIG_GREYBUS is not set
@@ -10651,6 +10655,7 @@ CONFIG_CRYPTO_LIB_CHACHA20POLY1305=m
CONFIG_CRYPTO_LIB_SHA256=y
# end of Crypto library routines
+CONFIG_LIB_MEMNEQ=y
CONFIG_CRC_CCITT=y
CONFIG_CRC16=m
CONFIG_CRC_T10DIF=y
@@ -11051,7 +11056,7 @@ CONFIG_DYNAMIC_EVENTS=y
CONFIG_PROBE_EVENTS=y
CONFIG_BPF_KPROBE_OVERRIDE=y
CONFIG_FTRACE_MCOUNT_RECORD=y
-CONFIG_FTRACE_MCOUNT_USE_OBJTOOL=y
+CONFIG_FTRACE_MCOUNT_USE_CC=y
CONFIG_TRACING_MAP=y
CONFIG_SYNTH_EVENTS=y
CONFIG_HIST_TRIGGERS=y