dev->n_ecc_unfixed++;
}
- if (tags && ecc_result == -YAFFS_ECC_RESULT_FIXED) {
+ if (tags && ecc_result == YAFFS_ECC_RESULT_FIXED) {
if (tags->ecc_result <= YAFFS_ECC_RESULT_NO_ERROR)
tags->ecc_result = YAFFS_ECC_RESULT_FIXED;
dev->n_ecc_fixed++;
}
- if (ecc_result < YAFFS_ECC_RESULT_UNFIXED)
+ if (retval == YAFFS_OK && ecc_result < YAFFS_ECC_RESULT_UNFIXED)
return YAFFS_OK;
else
return YAFFS_FAIL;