spl: fit: not allow default configure node miss
Signed-off-by: Joseph Chen <chenjh@rock-chips.com> Change-Id: I07af21fdc371dcfdc55115febfc3e99ff41ee8d4
This commit is contained in:
parent
1ddd141a3e
commit
a7560f55a3
|
|
@ -413,15 +413,18 @@ static int spl_internal_load_simple_fit(struct spl_image_info *spl_image,
|
||||||
int conf_noffset;
|
int conf_noffset;
|
||||||
|
|
||||||
conf_noffset = fit_conf_get_node(fit, NULL);
|
conf_noffset = fit_conf_get_node(fit, NULL);
|
||||||
if (conf_noffset > 0) {
|
if (conf_noffset <= 0) {
|
||||||
ret = fit_config_verify(fit, conf_noffset);
|
printf("No default config node\n");
|
||||||
if (ret) {
|
return -EINVAL;
|
||||||
printf("fit verify configure failed, ret=%d\n", ret);
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
printf("\n");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ret = fit_config_verify(fit, conf_noffset);
|
||||||
|
if (ret) {
|
||||||
|
printf("fit verify configure failed, ret=%d\n", ret);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
printf("\n");
|
||||||
|
|
||||||
#ifdef CONFIG_SPL_FIT_ROLLBACK_PROTECT
|
#ifdef CONFIG_SPL_FIT_ROLLBACK_PROTECT
|
||||||
uint32_t this_index, min_index;
|
uint32_t this_index, min_index;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue