summaryrefslogtreecommitdiff
path: root/boot/system_bootdev.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2022-08-12 12:51:14 -0400
committerTom Rini <trini@konsulko.com>2022-08-12 12:51:14 -0400
commit6fc212779c990ff27a430e370bfb8fac01ddde7f (patch)
tree32ecaafa1d653e275683cfacac41dd2bb57efca1 /boot/system_bootdev.c
parentf5003e0791dbe796bf7b41515d67ae5527679ec9 (diff)
parent5fe76d460d857b00d582d7cd6cea9ac740ea912b (diff)
Merge branch '2022-08-11-verified-boot-for-embedded-initial-support'
To quote Simon: This adds the concept of a VBE method to U-Boot, along with an implementation of the 'VBE simple' method, basically a simple way of updating firmware in MMC from userspace and monitoring it from U-Boot. VBE simple is implemented in fwupd. U-Boot's role is to set up the device tree with the required firmware-update properties and provide the developer with information about the current VBE state. To that end this series includes a new 'vbe' command that allows VBE methods to be listed and examined. As part of this work, support for doing FDT fixups via the event interface is provided, along with the ability to write to the device tree via the ofnode interface. Another (significant) change is that bootmeths now have a 'global' flag, to allow the implementation of EFI bootmgr (and VBE) to be cleaned up. The 'system' bootdev is no-longer needed and these bootmeths are scanned first. Further work is needed to pull everything together, but this is a step along the way.
Diffstat (limited to 'boot/system_bootdev.c')
-rw-r--r--boot/system_bootdev.c66
1 files changed, 0 insertions, 66 deletions
diff --git a/boot/system_bootdev.c b/boot/system_bootdev.c
deleted file mode 100644
index 432d2034780..00000000000
--- a/boot/system_bootdev.c
+++ /dev/null
@@ -1,66 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * Bootdevice for system, used for bootmeths not tied to any partition device
- *
- * Copyright 2021 Google LLC
- * Written by Simon Glass <sjg@chromium.org>
- */
-
-#define LOG_CATEGORY UCLASS_BOOTSTD
-
-#include <common.h>
-#include <bootdev.h>
-#include <bootflow.h>
-#include <bootmeth.h>
-#include <command.h>
-#include <distro.h>
-#include <dm.h>
-#include <log.h>
-#include <net.h>
-
-static int system_get_bootflow(struct udevice *dev, struct bootflow_iter *iter,
- struct bootflow *bflow)
-{
- int ret;
-
- /* Must be an bootstd device */
- ret = bootflow_iter_uses_system(iter);
- if (ret)
- return log_msg_ret("net", ret);
-
- ret = bootmeth_check(bflow->method, iter);
- if (ret)
- return log_msg_ret("check", ret);
-
- ret = bootmeth_read_bootflow(bflow->method, bflow);
- if (ret)
- return log_msg_ret("method", ret);
-
- return 0;
-}
-
-static int system_bootdev_bind(struct udevice *dev)
-{
- struct bootdev_uc_plat *ucp = dev_get_uclass_plat(dev);
-
- ucp->prio = BOOTDEVP_6_SYSTEM;
-
- return 0;
-}
-
-struct bootdev_ops system_bootdev_ops = {
- .get_bootflow = system_get_bootflow,
-};
-
-static const struct udevice_id system_bootdev_ids[] = {
- { .compatible = "u-boot,bootdev-system" },
- { }
-};
-
-U_BOOT_DRIVER(system_bootdev) = {
- .name = "system_bootdev",
- .id = UCLASS_BOOTDEV,
- .ops = &system_bootdev_ops,
- .bind = system_bootdev_bind,
- .of_match = system_bootdev_ids,
-};