Commit 5f81b127 authored by Andrzej Puzdrowski's avatar Andrzej Puzdrowski
Browse files

zephyr: fix flash_area_read_is_empty

Implementation of flash_area_read_is_empty introduced recently
uses deprecated hal_flash_read API which caused build failure.

This patch uses zephyr's native flash_area_read() API which
solves the bug.

Signed-off-by: default avatarAndrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
parent 178be54b
Loading
Loading
Loading
Loading
+1 −1
Changes for boot/zephyr/flash_map_extended.c: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -83,7 +83,7 @@ int flash_area_read_is_empty(const struct flash_area *fa, uint32_t off,
    uint8_t *u8dst;
    int rc;

    rc = hal_flash_read(fa->fa_device_id, fa->fa_off + off, dst, len);
    rc = flash_area_read(fa, off, dst, len);
    if (rc) {
        return -1;
    }