mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-18 03:23:53 -04:00
kbuild: rust: Enable KASAN support
Rust supports KASAN via LLVM, but prior to this patch, the flags aren't set properly. Suggested-by: Miguel Ojeda <ojeda@kernel.org> Signed-off-by: Matthew Maurer <mmaurer@google.com> Reviewed-by: Andrey Konovalov <andreyknvl@gmail.com> Link: https://lore.kernel.org/r/20240820194910.187826-4-mmaurer@google.com [ Applied "SW_TAGS KASAN" nit. - Miguel ] Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
This commit is contained in:
committed by
Miguel Ojeda
parent
f64e2f3a66
commit
e3117404b4
@@ -207,7 +207,7 @@ fn main() {
|
||||
}
|
||||
ts.push("features", features);
|
||||
ts.push("llvm-target", "x86_64-linux-gnu");
|
||||
ts.push("supported-sanitizers", ["kcfi"]);
|
||||
ts.push("supported-sanitizers", ["kcfi", "kernel-address"]);
|
||||
ts.push("target-pointer-width", "64");
|
||||
} else if cfg.has("X86_32") {
|
||||
// This only works on UML, as i386 otherwise needs regparm support in rustc
|
||||
|
||||
Reference in New Issue
Block a user