Re: [patch 00/38] x86/retbleed: Call depth tracking mitigation

Steven Rostedt
2022-07-20T19:43:54Z

On Wed, 20 Jul 2022 12:36:38 -0700
Kees Cook <keescook@chromium.org> wrote:

> I'd rather not remove it (or do it dynamically) since the point is to
> test what has been generated by the toolchain/build process and stuffed
> into the .rodata section. i.e. making sure gadgets there can't be
> executed, that the boot-time section permission-setting works correctly,
> etc. Before the retbleed mitigation, this test worked for all
> architectures; I'd hate to regress it. :(

If you haven't noticed my reply, I wasn't able to come up with a one line
workaround, but I was able to come up with a two line workaround. Hopefully
that will be good enough to keep your little feature.

https://lore.kernel.org/all/20220720151123.0e5bf61e@gandalf.local.home/

I'm currently running it under my entire ftrace test suite. If it passes,
I'll submit a formal patch.

-- Steve