summaryrefslogtreecommitdiffstats
path: root/security/selinux/include/objsec.h
diff options
context:
space:
mode:
authorCasey Schaufler <casey@schaufler-ca.com>2024-07-10 23:32:29 +0200
committerPaul Moore <paul@paul-moore.com>2024-07-29 22:54:52 +0200
commit66de33a0bbb59ef3909d2c65dbbb7fc503d573bd (patch)
tree9f6269a38c23b93663e5927567a14628017679cf /security/selinux/include/objsec.h
parentlsm: infrastructure management of the dev_tun blob (diff)
downloadlinux-66de33a0bbb59ef3909d2c65dbbb7fc503d573bd.tar.xz
linux-66de33a0bbb59ef3909d2c65dbbb7fc503d573bd.zip
lsm: infrastructure management of the infiniband blob
Move management of the infiniband security blob out of the individual security modules and into the LSM infrastructure. The security modules tell the infrastructure how much space they require at initialization. There are no longer any modules that require the ib_free() hook. The hook definition has been removed. Signed-off-by: Casey Schaufler <casey@schaufler-ca.com> Reviewed-by: John Johansen <john.johansen@canonical.com> [PM: subject tweak, selinux style fixes] Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'security/selinux/include/objsec.h')
-rw-r--r--security/selinux/include/objsec.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/security/selinux/include/objsec.h b/security/selinux/include/objsec.h
index b7d4b1fc8fee..ed9e37f3c9b5 100644
--- a/security/selinux/include/objsec.h
+++ b/security/selinux/include/objsec.h
@@ -212,4 +212,9 @@ static inline struct tun_security_struct *selinux_tun_dev(void *security)
return security + selinux_blob_sizes.lbs_tun_dev;
}
+static inline struct ib_security_struct *selinux_ib(void *ib_sec)
+{
+ return ib_sec + selinux_blob_sizes.lbs_ib;
+}
+
#endif /* _SELINUX_OBJSEC_H_ */