From b9abc5322e2a18828fbfab5e081f846f0c4199cc Mon Sep 17 00:00:00 2001 From: Sascha Hauer Date: Wed, 5 Apr 2017 16:26:20 +0200 Subject: boot: Allow to register boot entry providers bootentry_create_from_name() takes a name and creates bootentries for it. It tries different providers that interpret the name: blspec, bootchooser or script pathes. Instead of hardcoding the different providers in the function, allow the providers to register themselves. Signed-off-by: Sascha Hauer --- include/boot.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/boot.h') diff --git a/include/boot.h b/include/boot.h index a855cbe1e5..4f7612ab80 100644 --- a/include/boot.h +++ b/include/boot.h @@ -36,6 +36,8 @@ struct bootentry { int bootentries_add_entry(struct bootentries *entries, struct bootentry *entry); +int bootentry_register_provider(int (*fn)(struct bootentries *bootentries, const char *name)); + #define bootentries_for_each_entry(bootentries, entry) \ list_for_each_entry(entry, &bootentries->entries, list) -- cgit v1.2.3