idk man
This commit is contained in:
@@ -14,9 +14,7 @@
|
||||
}:
|
||||
let
|
||||
version =
|
||||
if cachyConfig.taste == "linux-cachyos-asahi" then
|
||||
cachyConfig.versions.linux.version
|
||||
else if stdenv.isAarch64 then
|
||||
if stdenv.isAarch64 then
|
||||
"6.12.47"
|
||||
else
|
||||
cachyConfig.versions.linux.version;
|
||||
@@ -36,14 +34,7 @@ let
|
||||
};
|
||||
|
||||
src =
|
||||
if cachyConfig.taste == "linux-cachyos-asahi" then
|
||||
fetchFromGitHub {
|
||||
owner = cachyConfig.versions.linux.owner;
|
||||
repo = cachyConfig.versions.linux.repo;
|
||||
rev = cachyConfig.versions.linux.rev;
|
||||
inherit (cachyConfig.versions.linux) hash;
|
||||
}
|
||||
else if stdenv.isAarch64 then
|
||||
if stdenv.isAarch64 then
|
||||
let
|
||||
tag = "stable_20250916";
|
||||
hash = "sha256-Rjn+eWl5cLcc9wgjS3HYVaWM5eKMN3pPfPbsu+QGR/M=";
|
||||
@@ -95,14 +86,7 @@ let
|
||||
++ schedPatches
|
||||
++ lib.optional (
|
||||
cachyConfig.cpuSched == "hardened"
|
||||
) "${patches-src}/${majorMinor}/misc/0001-hardened.patch"
|
||||
# The Asahi tree occupies BIT(2)–BIT(4) in TCP_CONG_MASK with AccECN flags,
|
||||
# so the CachyOS hunk defining TCP_CONG_WANTS_CE_EVENTS at BIT(2) fails to
|
||||
# apply while later hunks that use it succeed — causing a compile error.
|
||||
# This patch places the symbol at BIT(5) and adds it to TCP_CONG_MASK.
|
||||
++ lib.optional (
|
||||
cachyConfig.taste == "linux-cachyos-asahi"
|
||||
) ./patches/asahi-tcp-cong-wants-ce-events.patch;
|
||||
) "${patches-src}/${majorMinor}/misc/0001-hardened.patch";
|
||||
|
||||
# There are some configurations set by the PKGBUILD
|
||||
pkgbuildConfig =
|
||||
@@ -111,10 +95,9 @@ let
|
||||
++ mArchConfig
|
||||
++ cpuSchedConfig
|
||||
++ [
|
||||
"-m BCACHEFS_FS"
|
||||
"-m CONFIG_CRYPTO_BLAKE2B"
|
||||
]
|
||||
# _nr_cpus — skip for Asahi; asahiPlatformConfig sets the correct value (64)
|
||||
++ lib.optional (cachyConfig.taste != "linux-cachyos-asahi") "--set-val NR_CPUS 320"
|
||||
++ [
|
||||
|
||||
# _per_gov, defaults to empty [but PERSONAL CHANGE to "y"]
|
||||
@@ -154,15 +137,12 @@ let
|
||||
"-e PER_VMA_LOCK"
|
||||
"-d PER_VMA_LOCK_STATS"
|
||||
]
|
||||
# bcachefs is not in the Asahi 6.18 tree
|
||||
++ lib.optional (cachyConfig.taste != "linux-cachyos-asahi") "-m BCACHEFS_FS"
|
||||
++ hugePagesConfig
|
||||
++ damonConfig
|
||||
++ ntSyncConfig
|
||||
++ hdrConfig
|
||||
++ disableDebug
|
||||
++ pageSizeConfig
|
||||
++ asahiPlatformConfig;
|
||||
++ pageSizeConfig;
|
||||
|
||||
# _cachy_config, defaults to "y"
|
||||
basicCachyConfig = lib.optional cachyConfig.basicCachy "-e CACHY";
|
||||
@@ -421,84 +401,6 @@ let
|
||||
else
|
||||
throw "Unsupported cachyos _hugepage";
|
||||
|
||||
# Apple Silicon (Asahi) platform drivers
|
||||
# Mirrors the options set in the asahi-alarm/PKGBUILDs linux-asahi config.
|
||||
# ARCH_APPLE is the root Kconfig symbol; everything else gates on it.
|
||||
# olddefconfig will auto-select most sub-options once ARCH_APPLE is on,
|
||||
# but the hardware-specific drivers are listed explicitly so they aren't
|
||||
# left as =m when we want them built-in, or omitted entirely.
|
||||
asahiPlatformConfig = lib.optionals (cachyConfig.taste == "linux-cachyos-asahi") [
|
||||
# Rust support — must come before any symbol that depends on it
|
||||
"-e RUST"
|
||||
|
||||
# SoC platform — root symbol; must come first
|
||||
"-e ARCH_APPLE"
|
||||
|
||||
# Interrupt controller
|
||||
"-e APPLE_AIC"
|
||||
|
||||
# IOMMU (required for PCIe, GPU, and NVMe)
|
||||
"-e APPLE_DART"
|
||||
|
||||
# RTKit coprocessor framework (required by GPU, audio, SEP)
|
||||
"-e APPLE_RTKIT"
|
||||
"-e APPLE_RTKIT_HELPER"
|
||||
"-e APPLE_MAILBOX"
|
||||
# Rust-based mailbox/rtkit (present in 6.18 Asahi tree)
|
||||
"-e RUST_APPLE_MAILBOX"
|
||||
"-e RUST_APPLE_RTKIT"
|
||||
|
||||
# Power management
|
||||
"-e APPLE_PMGR_PWRSTATE"
|
||||
"-e APPLE_PMGR_MISC"
|
||||
|
||||
# DMA controller (required by audio)
|
||||
"-e APPLE_ADMAC"
|
||||
|
||||
# Security / SART (required by NVMe)
|
||||
"-e APPLE_SART"
|
||||
"-e APPLE_SEP"
|
||||
|
||||
# Storage
|
||||
"-e NVME_APPLE"
|
||||
|
||||
# PCIe
|
||||
"-e PCIE_APPLE"
|
||||
|
||||
# CPU frequency / idle
|
||||
"-e ARM_APPLE_SOC_CPUFREQ"
|
||||
"-e ARM_APPLE_CPUIDLE"
|
||||
|
||||
# Pin control
|
||||
"-e PINCTRL_APPLE_GPIO"
|
||||
|
||||
# Display (DCP)
|
||||
"-m DRM_APPLE"
|
||||
"-e DRM_APPLE_AUDIO"
|
||||
|
||||
# GPU (Asahi AGX Rust driver)
|
||||
"-e DRM_ASAHI"
|
||||
|
||||
# Audio
|
||||
"-m SND_SOC_APPLE_MCA"
|
||||
"-m SND_SOC_APPLE_MACAUDIO"
|
||||
"-m SND_SOC_APPLE_AOP_AUDIO"
|
||||
|
||||
# Misc Apple SoC peripherals
|
||||
"-e APPLE_DOCKCHANNEL"
|
||||
"-e APPLE_WATCHDOG"
|
||||
"-m APPLE_SIO"
|
||||
"-m APPLE_AOP"
|
||||
"-e APPLE_M1_CPU_PMU"
|
||||
|
||||
# 16K pages — Apple Silicon runs with 16K page granule
|
||||
"-d ARM64_4K_PAGES"
|
||||
"-e ARM64_16K_PAGES"
|
||||
|
||||
# NR_CPUS: Apple Silicon has at most ~16 cores; 64 is the Asahi default
|
||||
"--set-val NR_CPUS 64"
|
||||
];
|
||||
|
||||
# _damon, defaults to empty
|
||||
damonConfig = lib.optionals cachyConfig.withDAMON [
|
||||
"-e DAMON"
|
||||
@@ -538,9 +440,8 @@ let
|
||||
"-d LATENCYTOP"
|
||||
"-d DEBUG_PREEMPT"
|
||||
];
|
||||
# Asahi uses the LTS config base since it tracks the same 6.18 kernel series
|
||||
configTaste =
|
||||
if cachyConfig.taste == "linux-cachyos-asahi" then "linux-cachyos-lts" else cachyConfig.taste;
|
||||
|
||||
configTaste = cachyConfig.taste;
|
||||
|
||||
# Rust toolchain — needed so `make olddefconfig` can probe rustc and set
|
||||
# RUSTC_VERSION correctly, which gates CONFIG_RUST and all rust-dependent
|
||||
|
||||
Reference in New Issue
Block a user