Commit 5477ec61 authored by Michal Hrusecky's avatar Michal Hrusecky 🦎

mtd: Make verify return correct code

parent eb51288d
......@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=mtd
PKG_RELEASE:=21
PKG_RELEASE:=22
PKG_BUILD_DIR := $(KERNEL_BUILD_DIR)/$(PKG_NAME)
STAMP_PREPARED := $(STAMP_PREPARED)_$(call confvar,CONFIG_MTD_REDBOOT_PARTS)
......
......@@ -697,7 +697,7 @@ static void do_reboot(void)
int main (int argc, char **argv)
{
int ch, i, boot, imagefd = 0, force, unlocked;
int ch, i, boot, imagefd = 0, force, unlocked, ret = 0;
char *erase[MAX_ARGS], *device = NULL;
char *fis_layout = NULL;
size_t offset = 0, part_offset = 0, dump_len = 0;
......@@ -876,7 +876,7 @@ int main (int argc, char **argv)
mtd_unlock(device);
break;
case CMD_VERIFY:
mtd_verify(device, imagefile);
ret |= mtd_verify(device, imagefile);
break;
case CMD_DUMP:
mtd_dump(device, offset, dump_len);
......@@ -915,5 +915,5 @@ int main (int argc, char **argv)
if (boot)
do_reboot();
return 0;
return ret;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment