Whenever I apply settings through make kernel_menuconfig and save it as .config, I check the file and I don’t see certain settings applying properly. An example is CONFIG_KERNEL_HZ_1000 or any mention of it (Timer Frequency). Another example is ZSTD kernel compression; it shows as selected in the GUI, but when saved I don’t see it in the .config.
Is this normal? I’ve been trying to make a diff file to save all my changes neatly to re-apply for next time, but I can’t when these settings are missing from .config.
You are diffing the wrong file.
Kernel config changes are not stored in the main .config file that focuses on OpenWrt packages and their settings.
Kernel settings vary by target, subtarget and kernel version, so
kernel_menuconfig settings are stored directly in the kernel config files in target/ directories, depending on the settings either in the general section of in target or target/subtarget directory. The kernel settings are there.
And changes are more permanently than the .config as there are no separate defaults. So, once you make the change, your changes will be new defaults from that on. (But as the target/ is under git, you can use git commands to reset/restore old default contents of the files there.)
For example, trying to set for my router that 1000 HZ that you mentioned, gets stored into mediatek/filogic subtarget kernel 6.12 config target/linux/mediatek/filogic/config-6.12 as shown by git diff
perus@ub2510:/OpenWrt/aarch64$ git diff
diff --git a/target/linux/mediatek/filogic/config-6.12 b/target/linux/mediatek/filogic/config-6.12
index d319785ce5..2038f34982 100644
--- a/target/linux/mediatek/filogic/config-6.12
+++ b/target/linux/mediatek/filogic/config-6.12
@@ -32,7 +32,6 @@ CONFIG_ARM64_PLATFORM_DEVICES=y
CONFIG_ARM64_TAGGED_ADDR_ABI=y
CONFIG_ARM64_VA_BITS=39
CONFIG_ARM64_VA_BITS_39=y
-# CONFIG_ARM64_VA_BITS_52 is not set
CONFIG_ARM_AMBA=y
CONFIG_ARM_ARCH_TIMER=y
CONFIG_ARM_ARCH_TIMER_EVTSTREAM=y
@@ -193,6 +192,7 @@ CONFIG_GENERIC_GETTIMEOFDAY=y
CONFIG_GENERIC_IDLE_POLL_SETUP=y
CONFIG_GENERIC_IOREMAP=y
CONFIG_GENERIC_IRQ_EFFECTIVE_AFF_MASK=y
+CONFIG_GENERIC_IRQ_KEXEC_CLEAR_VM_FORWARD=y
CONFIG_GENERIC_IRQ_SHOW=y
CONFIG_GENERIC_IRQ_SHOW_LEVEL=y
CONFIG_GENERIC_LIB_DEVMEM_IS_ALLOWED=y
@@ -220,12 +220,14 @@ CONFIG_HAS_IOPORT_MAP=y
CONFIG_HWMON=y
CONFIG_HW_RANDOM=y
CONFIG_HW_RANDOM_MTK=y
+CONFIG_HZ=1000
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_1000=y
CONFIG_I2C=y
CONFIG_I2C_BOARDINFO=y
...
(The kernel_menuconfig also cleaned out some unrecognized options at the same time.)
Ps. In case you want to revert to defaults, either git reset or git restore may work, if properly used. For example: