added a couple of LOG_ERROR() messages to improve logfile.
[fw/openocd] / src / flash / flash.c
index 850dcd4cb50b1f5579a044ecf7fd28c9c6b2d616..46606d2de28fe57f871d6a58be9006bb52616b30 100644 (file)
@@ -884,7 +884,10 @@ int flash_erase_address_range(target_t *target, u32 addr, u32 length)
                return ERROR_FLASH_DST_OUT_OF_BANK; /* no corresponding bank found */
 
        if (c->size == 0 || c->num_sectors == 0)
+       {
+               LOG_ERROR("Bank is invalid");
                return ERROR_FLASH_BANK_INVALID;
+       }
 
        if (length == 0)
        {