From 5a2ba27604fb8db0eb03b883580763af9e75ccfc Mon Sep 17 00:00:00 2001 From: Piotr Gorski Date: Wed, 14 Sep 2022 20:09:17 +0200 Subject: [PATCH] Bump to 5.19.8-2 Signed-off-by: Piotr Gorski --- .SRCINFO | 6 ++-- PKGBUILD | 77 ++++++++++++++++++++++++++-------------- auto-cpu-optimization.sh | 6 +++- config | 5 ++- configure | 2 ++ 5 files changed, 65 insertions(+), 31 deletions(-) diff --git a/.SRCINFO b/.SRCINFO index 312f2d6..3def32f 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = linux-cachyos pkgdesc = Linux BORE scheduler Kernel by CachyOS with other patches and improvements pkgver = 5.19.8 - pkgrel = 1 + pkgrel = 2 url = https://github.com/CachyOS/linux-cachyos arch = x86_64 arch = x86_64_v3 @@ -27,8 +27,8 @@ pkgbase = linux-cachyos source = https://raw.githubusercontent.com/cachyos/kernel-patches/master/5.19/all/0001-cachyos-base-all.patch source = https://raw.githubusercontent.com/cachyos/kernel-patches/master/5.19/sched/0001-bore.patch sha256sums = 616308795a952a6a39b4c74807c33916850eb7166d8ed7c9a87a1ba55d7487ce - sha256sums = 0dcff98ce415b81e00648712f8d7d7beb5f332239618bc95c7c3f9ae1573a92a - sha256sums = ce8bf7807b45a27eed05a5e1de5a0bf6293a3bbc2085bacae70cd1368f368d1f + sha256sums = 4e00d2c15d104f239fd1b320c0fd00f8de6ef7cb0e1eaba477b8b227854d639e + sha256sums = e1d45b5842079a5f0f53d7ea2d66ffa3f1497766f3ccffcf13ed00f1ac67f95e sha256sums = 170239dd75f80d5f3c4a4706b11c6569a97be36a9057cd36c54296da0cc6a2d7 sha256sums = 9659b83b734788c7cecb39d15f3a273d007bfa95fc3ed1951dd92796533fdcb2 diff --git a/PKGBUILD b/PKGBUILD index 65fdcf2..99b1b18 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -84,6 +84,12 @@ _kyber_disable=y # 'none' - disable multigenerational LRU _lru_config='standard' +### Enable per-VMA locking +# ATTENTION - one of two predefined values should be selected! +# 'standard' - enable per-VMA locking +# 'stats' - enable per-VMA locking with stats +_vma_config='standard' + ## Enable DAMON _damon= @@ -158,7 +164,7 @@ _stable=${_major}.${_minor} _srcname=linux-${_stable} #_srcname=linux-${_major} pkgdesc='Linux BORE scheduler Kernel by CachyOS with other patches and improvements' -pkgrel=1 +pkgrel=2 _kernver=$pkgver-$pkgrel arch=('x86_64' 'x86_64_v3') url="https://github.com/CachyOS/linux-cachyos" @@ -234,7 +240,7 @@ if [ -n "$_bcachefs" ]; then source+=("${_patchsource}/misc/0001-bcachefs-after-lru.patch") fi -export KBUILD_BUILD_HOST=archlinux +export KBUILD_BUILD_HOST=cachyos export KBUILD_BUILD_USER=$pkgbase export KBUILD_BUILD_TIMESTAMP="$(date -Ru${SOURCE_DATE_EPOCH:+d @$SOURCE_DATE_EPOCH})" @@ -503,17 +509,17 @@ prepare() { ### Select LRU config if [ "$_lru_config" = "standard" ]; then echo "Enabling multigenerational LRU..." - scripts/config --enable CONFIG_LRU_GEN \ - --enable CONFIG_LRU_GEN_ENABLED \ - --disable CONFIG_LRU_GEN_STATS + scripts/config --enable LRU_GEN \ + --enable LRU_GEN_ENABLED \ + --disable LRU_GEN_STATS elif [ "$_lru_config" = "stats" ]; then echo "Enabling multigenerational LRU with stats..." - scripts/config --enable CONFIG_LRU_GEN \ - --enable CONFIG_LRU_GEN_ENABLED \ - --enable CONFIG_LRU_GEN_STATS + scripts/config --enable LRU_GEN \ + --enable LRU_GEN_ENABLED \ + --enable LRU_GEN_STATS elif [ "$_lru_config" = "none" ]; then echo "Disabling multigenerational LRU..." - scripts/config --disable CONFIG_LRU_GEN + scripts/config --disable LRU_GEN else if [ -n "$_lru_config" ]; then error "The value $_lru_config is invalid. Choose the correct one again." @@ -524,6 +530,25 @@ prepare() { exit fi + ### Select VMA config + if [ "$_vma_config" = "standard" ]; then + echo "Enabling per-VMA locking..." + scripts/config --enable PER_VMA_LOCK \ + --disable PER_VMA_LOCK_STATS + elif [ "$_vma_config" = "stats" ]; then + echo "Enabling per-VMA locking with stats..." + scripts/config --enable PER_VMA_LOCK \ + --enable PER_VMA_LOCK_STATS + else + if [ -n "$_vma_config" ]; then + error "The value $_vma_config is invalid. Choose the correct one again." + else + error "The value is empty. Choose the correct one again." + fi + error "Enabling per-VMA locking failed!" + exit + fi + ### Enable DAMON if [ -n "$_damon" ]; then echo "Enabling DAMON..." @@ -611,28 +636,28 @@ prepare() { ### Enable zram/zswap ZSTD compression if [ -n "$_zstd_compression" ]; then echo "Enabling zram/swap ZSTD compression..." - scripts/config --disable CONFIG_ZRAM_DEF_COMP_LZORLE \ - --enable CONFIG_ZRAM_DEF_COMP_ZSTD \ - --set-str CONFIG_ZRAM_DEF_COMP zstd \ - --disable CONFIG_ZSWAP_COMPRESSOR_DEFAULT_LZ4 \ - --enable CONFIG_ZSWAP_COMPRESSOR_DEFAULT_ZSTD \ - --set-str CONFIG_ZSWAP_COMPRESSOR_DEFAULT zstd \ - --enable CONFIG_ZRAM_ENTROPY \ - --set-val CONFIG_ZRAM_ENTROPY_THRESHOLD 100000 + scripts/config --disable ZRAM_DEF_COMP_LZORLE \ + --enable ZRAM_DEF_COMP_ZSTD \ + --set-str ZRAM_DEF_COMP zstd \ + --disable ZSWAP_COMPRESSOR_DEFAULT_LZ4 \ + --enable ZSWAP_COMPRESSOR_DEFAULT_ZSTD \ + --set-str ZSWAP_COMPRESSOR_DEFAULT zstd \ + --enable ZRAM_ENTROPY \ + --set-val ZRAM_ENTROPY_THRESHOLD 100000 fi ### Selecting the ZSTD modules and kernel compression level if [ "$_zstd_level_value" = "ultra" ]; then echo "Enabling highest ZSTD modules and kernel compression ratio..." - scripts/config --set-val CONFIG_MODULE_COMPRESS_ZSTD_LEVEL 19 \ - --enable CONFIG_MODULE_COMPRESS_ZSTD_ULTRA \ - --set-val CONFIG_MODULE_COMPRESS_ZSTD_LEVEL_ULTRA 22 \ - --set-val CONFIG_ZSTD_COMP_VAL 22 + scripts/config --set-val MODULE_COMPRESS_ZSTD_LEVEL 19 \ + --enable MODULE_COMPRESS_ZSTD_ULTRA \ + --set-val MODULE_COMPRESS_ZSTD_LEVEL_ULTRA 22 \ + --set-val ZSTD_COMP_VAL 22 elif [ "$_zstd_level_value" = "normal" ]; then echo "Enabling standard ZSTD modules and kernel compression ratio..." - scripts/config --set-val CONFIG_MODULE_COMPRESS_ZSTD_LEVEL 9 \ - --disable CONFIG_MODULE_COMPRESS_ZSTD_ULTRA \ - --set-val CONFIG_ZSTD_COMP_VAL 19 + scripts/config --set-val MODULE_COMPRESS_ZSTD_LEVEL 9 \ + --disable MODULE_COMPRESS_ZSTD_ULTRA \ + --set-val ZSTD_COMP_VAL 19 else if [ -n "$_zstd_level_value" ]; then error "The value $_zstd_level_value is invalid. Choose the correct one again." @@ -885,7 +910,7 @@ for _p in "${pkgname[@]}"; do done sha256sums=('616308795a952a6a39b4c74807c33916850eb7166d8ed7c9a87a1ba55d7487ce' - '0dcff98ce415b81e00648712f8d7d7beb5f332239618bc95c7c3f9ae1573a92a' - 'ce8bf7807b45a27eed05a5e1de5a0bf6293a3bbc2085bacae70cd1368f368d1f' + '4e00d2c15d104f239fd1b320c0fd00f8de6ef7cb0e1eaba477b8b227854d639e' + 'e1d45b5842079a5f0f53d7ea2d66ffa3f1497766f3ccffcf13ed00f1ac67f95e' '170239dd75f80d5f3c4a4706b11c6569a97be36a9057cd36c54296da0cc6a2d7' '9659b83b734788c7cecb39d15f3a273d007bfa95fc3ed1951dd92796533fdcb2') diff --git a/auto-cpu-optimization.sh b/auto-cpu-optimization.sh index a86795a..a1b76ec 100755 --- a/auto-cpu-optimization.sh +++ b/auto-cpu-optimization.sh @@ -1,7 +1,7 @@ #!/bin/bash CPU=$(gcc -Q -march=native --help=target|grep march=|awk '{print $2}'|head -1) MARCH=$(echo $CPU|tr '[:lower:]' '[:upper:]'&&echo) -if [[ ${MARCH} == "ZNVER" ]]; then +if [[ ${MARCH} == "ZNVER1" ]]; then MARCH="ZEN" elif [[ ${MARCH} == "ZNVER2" ]]; then MARCH="ZEN2" @@ -29,6 +29,10 @@ elif [[ ${MARCH} == "GOLDMONT-PLUS" ]]; then MARCH="GOLDMONTPLUS" elif [[ ${MARCH} == "SKYLAKE-AVX512" ]]; then MARCH="SKYLAKE2" +elif [[ ${MARCH} == "MIVYBRIDGE" ]]; then + scripts/config --disable CONFIG_AGP_AMD64 + scripts/config --disable CONFIG_MICROCODE_AMD + MARCH="MIVYBRIDGE" elif [[ ${MARCH} == "ICELAKE-CLIENT" ]]; then MARCH="ICELAKE" fi diff --git a/config b/config index 82fadf6..b83e9bd 100644 --- a/config +++ b/config @@ -1,6 +1,6 @@ # # Automatically generated file; DO NOT EDIT. -# Linux/x86 5.19.3 Kernel Configuration +# Linux/x86 5.19.8 Kernel Configuration # CONFIG_CC_VERSION_TEXT="gcc (GCC) 12.2.0" CONFIG_CC_IS_GCC=y @@ -1196,6 +1196,8 @@ CONFIG_PTE_MARKER_UFFD_WP=y # CONFIG_LRU_GEN is not set # CONFIG_LRU_GEN_ENABLED is not set # CONFIG_LRU_GEN_STATS is not set +CONFIG_ARCH_SUPPORTS_PER_VMA_LOCK=y +CONFIG_PER_VMA_LOCK=y # # Data Access Monitoring @@ -10945,6 +10947,7 @@ CONFIG_DEBUG_WX=y CONFIG_GENERIC_PTDUMP=y CONFIG_PTDUMP_CORE=y # CONFIG_PTDUMP_DEBUGFS is not set +# CONFIG_PER_VMA_LOCK_STATS is not set # CONFIG_DEBUG_OBJECTS is not set CONFIG_HAVE_DEBUG_KMEMLEAK=y # CONFIG_DEBUG_KMEMLEAK is not set diff --git a/configure b/configure index 2f1411c..5846925 100644 --- a/configure +++ b/configure @@ -202,6 +202,8 @@ cpu_arch() { scripts/config --enable CONFIG_MSANDYBRIDGE elif [[ "$_microarchitecture" = "45" ]]; then scripts/config --disable CONFIG_GENERIC_CPU + scripts/config --disable CONFIG_AGP_AMD64 + scripts/config --disable CONFIG_MICROCODE_AMD scripts/config --enable CONFIG_MIVYBRIDGE elif [[ "$_microarchitecture" = "46" ]]; then scripts/config --disable CONFIG_GENERIC_CPU