summaryrefslogtreecommitdiffstats
path: root/discover/grub2/grub2.h
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2019-11-11 19:30:41 +0800
committerJeremy Kerr <jk@ozlabs.org>2019-11-29 13:54:10 +0800
commitb22445748f44ed6965f31f45b39abb690d24ec47 (patch)
treecb9f942dac9ff19cc1786ea23f9f5a3509deec48 /discover/grub2/grub2.h
parent9fc2ac627df17ddc8e7c2735053aeb9e1252ff6e (diff)
downloadtalos-petitboot-b22445748f44ed6965f31f45b39abb690d24ec47.tar.gz
talos-petitboot-b22445748f44ed6965f31f45b39abb690d24ec47.zip
discover/grub2: Allow (device)/path references in general script usage
Currently, we have support for grub2 (device)/path syntax for boot resources. This change allows this syntax for general paths in grub2 scripts (for example, -f tests). This involves exposing grub2_lookup_device, to allow the script execution code to resolve pathnames. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'discover/grub2/grub2.h')
-rw-r--r--discover/grub2/grub2.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/discover/grub2/grub2.h b/discover/grub2/grub2.h
index ef32d4b..eabd6d6 100644
--- a/discover/grub2/grub2.h
+++ b/discover/grub2/grub2.h
@@ -200,6 +200,8 @@ bool resolve_grub2_resource(struct device_handler *handler,
/* grub-style device+path parsing */
struct grub2_file *grub2_parse_file(struct grub2_script *script,
const char *str);
+struct discover_device *grub2_lookup_device(struct device_handler *handler,
+ const char *desc);
/* external parser api */
struct grub2_parser *grub2_parser_create(struct discover_context *ctx);
OpenPOWER on IntegriCloud