9
0
Fork 0

state: mtd_get_meminfo: make usage of mtd's meminfo compatible to linux

This patch makes it possible to share the code with linux.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
This commit is contained in:
Marc Kleine-Budde 2015-05-21 10:40:52 +02:00 committed by Jan Luebbe
parent 6fecafad03
commit a8a3c2de5b
1 changed files with 2 additions and 2 deletions

View File

@ -1019,7 +1019,7 @@ int state_backend_dtb_file(struct state *state, const char *of_path, const char
state->backend = backend;
ret = mtd_get_meminfo(backend->path, &meminfo);
if (!ret && !(meminfo.mtd->flags & MTD_NO_ERASE))
if (!ret && !(meminfo.flags & MTD_NO_ERASE))
backend_dtb->need_erase = true;
return 0;
@ -1268,7 +1268,7 @@ int state_backend_raw_file(struct state *state, const char *of_path,
state->backend = backend;
ret = mtd_get_meminfo(backend->path, &meminfo);
if (!ret && !(meminfo.mtd->flags & MTD_NO_ERASE)) {
if (!ret && !(meminfo.flags & MTD_NO_ERASE)) {
backend_raw->need_erase = true;
backend_raw->step = ALIGN(backend_raw->size_full,
meminfo.erasesize);