提交 160cfc4b 编写于 作者: N Nobuhiro Iwamatsu 提交者: Tom Rini

boot_fit: Change return value from FDT_ERROR to -EINVAL in fdt_offset()

FDT_ERROR is defined as unsigned long. However, since the return value of
fdt_offset() is int, a warning will occur when compiling. Also, it is better
to use -EINVAL than FDT_ERROR.
This fixes this problem by change return value from FDT_ERROR to -EINVAL.
Signed-off-by: NNobuhiro Iwamatsu <iwamatsu@nigauri.org>
CC: Franklin S Cooper Jr <fcooper@ti.com>
Reviewed-by: NFranklin S Cooper Jr <fcooper@ti.com>
上级 7088a365
......@@ -25,7 +25,7 @@ int fdt_offset(void *fit)
images = fdt_path_offset(fit, FIT_IMAGES_PATH);
if (images < 0) {
debug("%s: Cannot find /images node: %d\n", __func__, images);
return FDT_ERROR;
return -EINVAL;
}
fdt_name = fdt_getprop(fit, node, FIT_FDT_PROP, &fdt_len);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册