Merge tag 'rust-fixes-7.4-3' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux

Pull Rust fix from Miguel Ojeda:

 - Fix build error in the upcoming Rust 1.100 when using an AutoFDO
   profile by supporting the stabilized name for 'profile-sample-use'

* tag 'rust-fixes-7.4-3' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux:
  kbuild: rust: support stabilized flag `-Cprofile-sample-use` for Rust >= 1.100
This commit is contained in:
Linus Torvalds
2026-11-12 09:35:54 -08:00
+1 -1
View File
@@ -13,7 +13,7 @@ endif
ifdef CLANG_AUTOFDO_PROFILE
CFLAGS_AUTOFDO_CLANG += -fprofile-sample-use=$(CLANG_AUTOFDO_PROFILE) -ffunction-sections
CFLAGS_AUTOFDO_CLANG += -fsplit-machine-functions
RUSTFLAGS_AUTOFDO_CLANG += -Zprofile-sample-use=$(CLANG_AUTOFDO_PROFILE) -Zfunction-sections=y
RUSTFLAGS_AUTOFDO_CLANG += $(if $(call rustc-min-version,110000),-Cprofile-sample-use,-Zprofile-sample-use)=$(CLANG_AUTOFDO_PROFILE) -Zfunction-sections=y
RUSTFLAGS_AUTOFDO_CLANG += -Cllvm-args=-split-machine-functions
endif