lkml.org 
[lkml]   [2023]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] x86/alternatives: Disable KASAN on text_poke_early() in apply_alternatives()
On Tue, Oct 10, 2023 at 12:16:21PM +0200, Peter Zijlstra wrote:
> On Tue, Oct 10, 2023 at 12:10:56PM +0200, Peter Zijlstra wrote:
>
> > That said, I don't particularly like the patch, I think it should, at
> > the veyr least, cover all of apply_alternatives, not just
> > text_poke_early().
>
> kasan_arch_is_ready() is another option, x86 doesn't currently define
> that, but that would allow us to shut kasan down harder around patching.
> Not sure if it's worth the trouble though.

IIUC, it was intended to delay KASAN usage until it is ready. KASAN is
functional well before apply_alternatives() and making
kasan_arch_is_ready() temporary false for patching feels like abuse of the
hook.

--
Kiryl Shutsemau / Kirill A. Shutemov

\
 
 \ /
  Last update: 2023-10-10 12:32    [W:0.093 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site