aboutsummaryrefslogtreecommitdiff
path: root/boot
diff options
context:
space:
mode:
authorSimon Glass2023-02-22 12:17:03 -0700
committerSimon Glass2023-03-08 11:40:49 -0800
commit4f806f31fc29b30f06bd13abe44a1d3649d480e5 (patch)
treee4d27f00d1b0815f778e562c8c4524fae442e881 /boot
parentfe7e9245c53e254526d3bbd6296d658596f41b48 (diff)
bootflow: Rename bootflow_flags_t
These flags actually relate to the iterator, not the bootflow struct itself. Rename them. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'boot')
-rw-r--r--boot/bootdev-uclass.c16
-rw-r--r--boot/bootflow.c20
2 files changed, 18 insertions, 18 deletions
diff --git a/boot/bootdev-uclass.c b/boot/bootdev-uclass.c
index 8103a11d1bb..d34b7e37cf7 100644
--- a/boot/bootdev-uclass.c
+++ b/boot/bootdev-uclass.c
@@ -629,11 +629,11 @@ int bootdev_next_prio(struct bootflow_iter *iter, struct udevice **devp)
if (++iter->cur_prio == BOOTDEVP_COUNT)
return log_msg_ret("fin", -ENODEV);
- if (iter->flags & BOOTFLOWF_HUNT) {
+ if (iter->flags & BOOTFLOWIF_HUNT) {
/* hunt to find new bootdevs */
ret = bootdev_hunt_prio(iter->cur_prio,
iter->flags &
- BOOTFLOWF_SHOW);
+ BOOTFLOWIF_SHOW);
log_debug("- hunt ret %d\n", ret);
if (ret)
return log_msg_ret("hun", ret);
@@ -657,7 +657,7 @@ int bootdev_setup_iter(struct bootflow_iter *iter, const char *label,
struct udevice **devp, int *method_flagsp)
{
struct udevice *bootstd, *dev = NULL;
- bool show = iter->flags & BOOTFLOWF_SHOW;
+ bool show = iter->flags & BOOTFLOWIF_SHOW;
int method_flags;
int ret;
@@ -668,7 +668,7 @@ int bootdev_setup_iter(struct bootflow_iter *iter, const char *label,
}
/* hunt for any pre-scan devices */
- if (iter->flags & BOOTFLOWF_HUNT) {
+ if (iter->flags & BOOTFLOWIF_HUNT) {
ret = bootdev_hunt_prio(BOOTDEVP_1_PRE_SCAN, show);
if (ret)
return log_msg_ret("pre", ret);
@@ -676,7 +676,7 @@ int bootdev_setup_iter(struct bootflow_iter *iter, const char *label,
/* Handle scanning a single device */
if (IS_ENABLED(CONFIG_BOOTSTD_FULL) && label) {
- if (iter->flags & BOOTFLOWF_HUNT) {
+ if (iter->flags & BOOTFLOWIF_HUNT) {
ret = bootdev_hunt(label, show);
if (ret)
return log_msg_ret("hun", ret);
@@ -687,11 +687,11 @@ int bootdev_setup_iter(struct bootflow_iter *iter, const char *label,
log_debug("method_flags: %x\n", method_flags);
if (method_flags & BOOTFLOW_METHF_SINGLE_UCLASS)
- iter->flags |= BOOTFLOWF_SINGLE_UCLASS;
+ iter->flags |= BOOTFLOWIF_SINGLE_UCLASS;
else if (method_flags & BOOTFLOW_METHF_SINGLE_DEV)
- iter->flags |= BOOTFLOWF_SINGLE_DEV;
+ iter->flags |= BOOTFLOWIF_SINGLE_DEV;
else
- iter->flags |= BOOTFLOWF_SINGLE_MEDIA;
+ iter->flags |= BOOTFLOWIF_SINGLE_MEDIA;
log_debug("Selected label: %s, flags %x\n", label, iter->flags);
} else {
bool ok;
diff --git a/boot/bootflow.c b/boot/bootflow.c
index 60791e681bd..70d5fc52387 100644
--- a/boot/bootflow.c
+++ b/boot/bootflow.c
@@ -139,8 +139,8 @@ static void bootflow_iter_set_dev(struct bootflow_iter *iter,
if (dev && iter->num_devs < iter->max_devs)
iter->dev_used[iter->num_devs++] = dev;
- if ((iter->flags & (BOOTFLOWF_SHOW | BOOTFLOWF_SINGLE_DEV)) ==
- BOOTFLOWF_SHOW) {
+ if ((iter->flags & (BOOTFLOWIF_SHOW | BOOTFLOWIF_SINGLE_DEV)) ==
+ BOOTFLOWIF_SHOW) {
if (dev)
printf("Scanning bootdev '%s':\n", dev->name);
else if (IS_ENABLED(CONFIG_BOOTMETH_GLOBAL) &&
@@ -215,7 +215,7 @@ static int iter_incr(struct bootflow_iter *iter)
iter->max_part = 0;
/* ...select next bootdev */
- if (iter->flags & BOOTFLOWF_SINGLE_DEV) {
+ if (iter->flags & BOOTFLOWIF_SINGLE_DEV) {
ret = -ENOENT;
} else {
int method_flags;
@@ -227,7 +227,7 @@ static int iter_incr(struct bootflow_iter *iter)
ret = bootdev_setup_iter(iter, NULL, &dev,
&method_flags);
} else if (IS_ENABLED(CONFIG_BOOTSTD_FULL) &&
- (iter->flags & BOOTFLOWF_SINGLE_UCLASS)) {
+ (iter->flags & BOOTFLOWIF_SINGLE_UCLASS)) {
/* Move to the next bootdev in this uclass */
uclass_find_next_device(&dev);
if (!dev) {
@@ -236,7 +236,7 @@ static int iter_incr(struct bootflow_iter *iter)
ret = -ENODEV;
}
} else if (IS_ENABLED(CONFIG_BOOTSTD_FULL) &&
- iter->flags & BOOTFLOWF_SINGLE_MEDIA) {
+ iter->flags & BOOTFLOWIF_SINGLE_MEDIA) {
log_debug("next in single\n");
method_flags = 0;
do {
@@ -328,7 +328,7 @@ static int bootflow_check(struct bootflow_iter *iter, struct bootflow *bflow)
* For 'all' we return all bootflows, even
* those with errors
*/
- if (iter->flags & BOOTFLOWF_ALL)
+ if (iter->flags & BOOTFLOWIF_ALL)
return log_msg_ret("all", ret);
}
if (ret)
@@ -344,14 +344,14 @@ int bootflow_scan_first(struct udevice *dev, const char *label,
int ret;
if (dev || label)
- flags |= BOOTFLOWF_SKIP_GLOBAL;
+ flags |= BOOTFLOWIF_SKIP_GLOBAL;
bootflow_iter_init(iter, flags);
/*
* Set up the ordering of bootmeths. This sets iter->doing_global and
* iter->first_glob_method if we are starting with the global bootmeths
*/
- ret = bootmeth_setup_iter_order(iter, !(flags & BOOTFLOWF_SKIP_GLOBAL));
+ ret = bootmeth_setup_iter_order(iter, !(flags & BOOTFLOWIF_SKIP_GLOBAL));
if (ret)
return log_msg_ret("obmeth", -ENODEV);
@@ -373,7 +373,7 @@ int bootflow_scan_first(struct udevice *dev, const char *label,
if (ret) {
log_debug("check - ret=%d\n", ret);
if (ret != BF_NO_MORE_PARTS && ret != -ENOSYS) {
- if (iter->flags & BOOTFLOWF_ALL)
+ if (iter->flags & BOOTFLOWIF_ALL)
return log_msg_ret("all", ret);
}
iter->err = ret;
@@ -402,7 +402,7 @@ int bootflow_scan_next(struct bootflow_iter *iter, struct bootflow *bflow)
return 0;
iter->err = ret;
if (ret != BF_NO_MORE_PARTS && ret != -ENOSYS) {
- if (iter->flags & BOOTFLOWF_ALL)
+ if (iter->flags & BOOTFLOWIF_ALL)
return log_msg_ret("all", ret);
}
} else {