git: 756728ec1c56 - stable/13 - LinuxKPI: add kfree_sensitive() using zfree().
Bjoern A. Zeeb
bz at FreeBSD.org
Sun Jul 18 00:36:16 UTC 2021
The branch stable/13 has been updated by bz:
URL: https://cgit.FreeBSD.org/src/commit/?id=756728ec1c56ea22f6ab4a57d45b72368fadc40a
commit 756728ec1c56ea22f6ab4a57d45b72368fadc40a
Author: Bjoern A. Zeeb <bz at FreeBSD.org>
AuthorDate: 2021-05-24 18:43:33 +0000
Commit: Bjoern A. Zeeb <bz at FreeBSD.org>
CommitDate: 2021-07-18 00:35:00 +0000
LinuxKPI: add kfree_sensitive() using zfree().
Sponsored by: The FreeBSD Foundation
Reviewed by: hselasky
Differential Revision: https://reviews.freebsd.org/D30437
(cherry picked from commit abcac97f8202d91b61ae4846794ba60166a56cfe)
---
sys/compat/linuxkpi/common/include/linux/slab.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/sys/compat/linuxkpi/common/include/linux/slab.h b/sys/compat/linuxkpi/common/include/linux/slab.h
index 9494d458e87c..8d5eb3e85e96 100644
--- a/sys/compat/linuxkpi/common/include/linux/slab.h
+++ b/sys/compat/linuxkpi/common/include/linux/slab.h
@@ -198,6 +198,12 @@ kfree(const void *ptr)
free(__DECONST(void *, ptr), M_KMALLOC);
}
+static __inline void
+kfree_sensitive(const void *ptr)
+{
+ zfree(__DECONST(void *, ptr), M_KMALLOC);
+}
+
static inline size_t
ksize(const void *ptr)
{
More information about the dev-commits-src-all
mailing list