hardening updates for v7.1-rc1

- randomize_kstack: Improve implementation across arches (Ryan Roberts)

- lkdtm/fortify: Drop unneeded FORTIFY_STR_OBJECT test

- refcount: Remove unused __signed_wrap function annotations
lkdtm/fortify: Drop unneeded FORTIFY_STR_OBJECT test

The str* family of fortified functions all use member-sized limits
for a while now, so the FORTIFY_STR_OBJECT test is redundant to
FORTIFY_STR_MEMBER. While here, replace the strncpy() use with strscpy(),
as strncpy() is being removed.

Link: https://patch.msgid.link/20260324020726.work.624-kees@kernel.org
Signed-off-by: Kees Cook <kees@kernel.org>
2 files changed