/* This function is useful when dealing with flash, for checking whether a data block is erased and thus does not need to be programmed. */
static int cros_ec_data_is_erased(const uint32_t *data, int size)
/* This function is useful when dealing with flash, for checking whether a data block is erased and thus does not need to be programmed. */
static int cros_ec_data_is_erased(const uint32_t *data, int size)
{
	assert(!(size & 3));
	size /= sizeof(uint32_t);
	for (; size > 0; size -= 4, data++)
		if (*data != -1U)
			return 0;
	return 1;
}