#define LOG_CATEGORY LOGC_BOOT
#include <common.h>
+#include <bloblist.h>
#include <bootdev.h>
#include <bootflow.h>
#include <bootmeth.h>
struct udevice *meth, *bdev;
struct simple_priv *priv;
struct bootflow bflow;
+ struct vbe_handoff *handoff;
int ret;
if (spl_phase() != PHASE_VPL && spl_phase() != PHASE_SPL)
return -ENOENT;
+ ret = bloblist_ensure_size(BLOBLISTT_VBE, sizeof(struct vbe_handoff),
+ 0, (void **)&handoff);
+ if (ret)
+ return log_msg_ret("ro", ret);
+
vbe_find_first_device(&meth);
if (!meth)
return log_msg_ret("vd", -ENODEV);
/* this is not used from now on, so free it */
bootflow_free(&bflow);
+ /* Record that VBE was used in this phase */
+ handoff->phases |= 1 << spl_phase();
+
return 0;
}
SPL_LOAD_IMAGE_METHOD("vbe_simple", 5, BOOT_DEVICE_VBE,