On Wed, May 28, 2025 at 05:58:21PM +0200, Peter Zijlstra wrote:
On Wed, May 28, 2025 at 03:30:33PM +0200, Jürgen Groß wrote:
Have a look at its_fini_mod().
Oh, that's what you mean. But this still isn't very nice, you now have restore_rox() without make_temp_rw(), which was the intended usage pattern.
Bah, I hate how execmem works different for !PSE, Mike, you see a sane way to fix this?
The least ugly thing I could think of is to replace the current pattern of
execmem_alloc() exemem_make_temp_rw() /* update */ execmem_restore_rox()
with
execmem_alloc_rw() /* update */ execmem_protect()
but I still haven't got to try it.