diff mbox series

[v6,01/20] libstb/secureboot: expose secureboot_enforce for later use in secvar

Message ID 20200916162131.22478-2-erichte@linux.ibm.com
State Accepted
Headers show
Series Add initial secure variable storage and backend drivers | expand

Checks

Context Check Description
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot-dco success Signed-off-by present
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot success Test snowpatch/job/snowpatch-skiboot on branch master
snowpatch_ozlabs/apply_patch success Successfully applied on branch master (d362ae4f4c521a7faffb1befe2fbba467f2c4d18)

Commit Message

Eric Richter Sept. 16, 2020, 4:21 p.m. UTC
This patch exposes the secureboot_enforce() function to unify any
system-halting behavior enacted by either firmware or OS secure boot.

Signed-off-by: Eric Richter <erichte@linux.ibm.com>
---
 libstb/secureboot.c | 2 +-
 libstb/secureboot.h | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/libstb/secureboot.c b/libstb/secureboot.c
index c8697216..60324809 100644
--- a/libstb/secureboot.c
+++ b/libstb/secureboot.c
@@ -27,7 +27,7 @@  static struct {
 	{ IBM_SECUREBOOT_V2, "ibm,secureboot-v2" },
 };
 
-static void secureboot_enforce(void)
+void secureboot_enforce(void)
 {
 	/* Sanity check */
 	if (!secure_mode)
diff --git a/libstb/secureboot.h b/libstb/secureboot.h
index 0792dd5a..721b28de 100644
--- a/libstb/secureboot.h
+++ b/libstb/secureboot.h
@@ -15,6 +15,7 @@  enum secureboot_version {
 	IBM_SECUREBOOT_V2,
 };
 
+void secureboot_enforce(void);
 bool secureboot_is_compatible(struct dt_node *node, int *version, const char **compat);
 void secureboot_init(void);