X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=common%2Fcmd_ubi.c;h=0460b4cc56f352581b91c951725d99adb1597c9d;hb=9aa1280a5644a1d05859b862ebc7b60a862e0ef3;hp=6c8570377e31d4726424eea67b4e53e417a08469;hpb=6af857c50df4e62ec08e51ad73c96f63f1480386;p=u-boot diff --git a/common/cmd_ubi.c b/common/cmd_ubi.c index 6c8570377e..0460b4cc56 100644 --- a/common/cmd_ubi.c +++ b/common/cmd_ubi.c @@ -14,7 +14,7 @@ #include #include #include - +#include #include #include #include @@ -114,7 +114,7 @@ static int ubi_check(char *name) return 0; } - return -EEXIST; + return 1; } @@ -363,7 +363,7 @@ int ubi_volume_read(char *volume, char *buf, size_t size) tbuf_size = vol->usable_leb_size; if (size < tbuf_size) tbuf_size = ALIGN(size, ubi->min_io_size); - tbuf = malloc(tbuf_size); + tbuf = malloc_cache_aligned(tbuf_size); if (!tbuf) { printf("NO MEM\n"); return ENOMEM;