[PATCH v2 3/5] security: Replace indirect LSM hook calls with static calls

Kees Cook keescook at chromium.org
Tue Jun 20 21:53:42 UTC 2023


On Fri, Jun 16, 2023 at 02:04:39AM +0200, KP Singh wrote:
> LSM hooks are currently invoked from a linked list as indirect calls
> which are invoked using retpolines as a mitigation for speculative
> attacks (Branch History / Target injection) and add extra overhead which
> is especially bad in kernel hot paths:

Overall, I find this a much cleaner patch compared to the v1 -- thanks
for cleaning up how the loops are replaced. I'm looking forward to v3
(with the build fixes and other comments addressed), as I think the
performance benefit this series provides is significant.

Thanks!

-Kees

-- 
Kees Cook



More information about the Linux-security-module-archive mailing list