ANDROID: kasan: fix interoperability with KFENCE
MTE-related KASAN changes were preceded by noticeable KASAN refactorings that were backported to android12-5.10, but not android12-5.4. As a result, some last-minute mm changes fixing "kfence, kasan: make KFENCE compatible with KASAN" (https://android.googlesource.com/kernel/common/+/f03825db4d6834a9d97e96eee2404a36ca79dafa ) did not make it to android12-5.4. Given that they do not exist as separate upstream commits and do not apply cleanly to 5.4 kernels, reimplement them. These changes boil down to skipping KASAN poisoning for KFENCE-allocated objects and to resetting the object tag in __kasan_kmalloc(). Bug: 172318110 Bug: 190593700 Signed-off-by:Alexander Potapenko <glider@google.com> Change-Id: I117ea37a1d41514a3c5beaf87386bb5f2f0046c8 (cherry picked from commit 2975020cd06cc96fd46258494e5ee10e62fbbeb1)
Loading
Please register or sign in to comment