On 25/02/14 10:10, NeilBrown wrote:
This code is obviously too subtle.
Not at all, it's my understanding that is under-developed. I was just looking for something obvious to explain the behaviour others have been reporting where a check won't trigger a re-write of a pending sector if the sector is a p or q rather than data.
If 0 drives have failed, then 's->failed' is 0 (it is the count of failed drives), and 's->q_failed' is also 0 (it is a boolean flag, and q clearly hasn't failed as nothing has). So the first 'if' branch will be followed (as "0 == 0") and check_state set to check_state_run. Then as q_failed is still 0 and failed < 2, check_state gets set to check_state_run_pq.
Got it, thanks for taking the time to set me straight. Regards, Brad -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html