Lines Matching refs:test_bit

167 	if (test_bit(MD_RECOVERY_SYNC, &conf->mddev->recovery) ||  in r10buf_pool_alloc()
168 test_bit(MD_RECOVERY_RESHAPE, &conf->mddev->recovery)) in r10buf_pool_alloc()
211 if (!j || test_bit(MD_RECOVERY_SYNC, in r10buf_pool_alloc()
335 if (!test_bit(R10BIO_Uptodate, &r10_bio->state)) in raid_end_bio_io()
419 if (!_enough(conf, test_bit(R10BIO_Previous, &r10_bio->state), in raid10_end_read_request()
445 !test_bit(R10BIO_Degraded, &r10_bio->state), in close_write()
453 if (test_bit(R10BIO_WriteError, &r10_bio->state)) in one_write_done()
457 if (test_bit(R10BIO_MadeGood, &r10_bio->state)) in one_write_done()
503 if (test_bit(FailFast, &rdev->flags) && in raid10_end_write_request()
506 if (!test_bit(Faulty, &rdev->flags)) in raid10_end_write_request()
541 if (test_bit(In_sync, &rdev->flags) && in raid10_end_write_request()
542 !test_bit(Faulty, &rdev->flags)) in raid10_end_write_request()
783 if (rdev == NULL || test_bit(Faulty, &rdev->flags) || in read_balance()
787 test_bit(Faulty, &rdev->flags)) in read_balance()
789 if (!test_bit(In_sync, &rdev->flags) && in read_balance()
881 if (rdev && !test_bit(Faulty, &rdev->flags)) { in raid10_congested()
928 if (test_bit(Faulty, &rdev->flags)) { in flush_pending_writes()
1071 if (!test_bit(MD_RECOVERY_RESHAPE, &rdev->mddev->recovery) || in choose_data_offset()
1072 test_bit(R10BIO_Previous, &r10_bio->state)) in choose_data_offset()
1113 if (test_bit(Faulty, &rdev->flags)) { in raid10_unplug()
1176 while (test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery) && in raid10_read_request()
1228 if (test_bit(FailFast, &rdev->flags) && in raid10_read_request()
1229 test_bit(R10BIO_FailFast, &r10_bio->state)) in raid10_read_request()
1277 if (!replacement && test_bit(FailFast, in raid10_write_one_disk()
1342 while (test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery) && in raid10_write_request()
1358 if (test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery) && in raid10_write_request()
1371 !test_bit(MD_SB_CHANGE_PENDING, &mddev->sb_flags)); in raid10_write_request()
1406 if (rdev && unlikely(test_bit(Blocked, &rdev->flags))) { in raid10_write_request()
1411 if (rrdev && unlikely(test_bit(Blocked, &rrdev->flags))) { in raid10_write_request()
1416 if (rdev && (test_bit(Faulty, &rdev->flags))) in raid10_write_request()
1418 if (rrdev && (test_bit(Faulty, &rrdev->flags))) in raid10_write_request()
1428 if (rdev && test_bit(WriteErrorSeen, &rdev->flags)) { in raid10_write_request()
1610 seq_printf(seq, "%s", rdev && test_bit(In_sync, &rdev->flags) ? "U" : "_"); in raid10_status()
1643 test_bit(In_sync, &rdev->flags)) in _enough()
1681 if (test_bit(In_sync, &rdev->flags) in raid10_error()
1726 i, !test_bit(In_sync, &rdev->flags), in print_conf()
1727 !test_bit(Faulty, &rdev->flags), in print_conf()
1756 && !test_bit(Faulty, &tmp->replacement->flags) in raid10_spare_active()
1774 && !test_bit(Faulty, &tmp->rdev->flags) in raid10_spare_active()
1820 if (!test_bit(WantReplacement, &p->rdev->flags) || in raid10_add_disk()
1871 if (test_bit(In_sync, &rdev->flags) || in raid10_remove_disk()
1879 if (!test_bit(Faulty, &rdev->flags) && in raid10_remove_disk()
1888 if (!test_bit(RemoveSynchronized, &rdev->flags)) { in raid10_remove_disk()
1933 if (test_bit(R10BIO_IsRecover, &r10_bio->state) || in __end_sync_read()
1967 if (test_bit(R10BIO_MadeGood, &r10_bio->state) || in end_sync_request()
1968 test_bit(R10BIO_WriteError, &r10_bio->state)) in end_sync_request()
1976 if (test_bit(R10BIO_MadeGood, &r10_bio->state) || in end_sync_request()
1977 test_bit(R10BIO_WriteError, &r10_bio->state)) in end_sync_request()
2101 if (test_bit(MD_RECOVERY_CHECK, &mddev->recovery)) in sync_request_write()
2104 } else if (test_bit(FailFast, &rdev->flags)) { in sync_request_write()
2131 if (test_bit(FailFast, &conf->mirrors[d].rdev->flags)) in sync_request_write()
2263 if (!test_bit(R10BIO_Uptodate, &r10_bio->state)) { in recovery_request_write()
2338 && (rw == READ || test_bit(WriteErrorSeen, &rdev->flags))) in r10_sync_page_io()
2376 if (test_bit(Faulty, &rdev->flags)) in fix_read_error()
2414 test_bit(In_sync, &rdev->flags) && in fix_read_error()
2415 !test_bit(Faulty, &rdev->flags) && in fix_read_error()
2469 test_bit(Faulty, &rdev->flags) || in fix_read_error()
2470 !test_bit(In_sync, &rdev->flags)) in fix_read_error()
2505 test_bit(Faulty, &rdev->flags) || in fix_read_error()
2506 !test_bit(In_sync, &rdev->flags)) in fix_read_error()
2630 else if (!test_bit(FailFast, &rdev->flags)) { in handle_read_error()
2654 if (test_bit(R10BIO_IsSync, &r10_bio->state) || in handle_write_completed()
2655 test_bit(R10BIO_IsRecover, &r10_bio->state)) { in handle_write_completed()
2736 if (test_bit(R10BIO_WriteError, in handle_write_completed()
2756 !test_bit(MD_SB_CHANGE_PENDING, &mddev->sb_flags)) { in raid10d()
2759 if (!test_bit(MD_SB_CHANGE_PENDING, &mddev->sb_flags)) { in raid10d()
2773 if (test_bit(R10BIO_WriteError, in raid10d()
2797 if (test_bit(R10BIO_MadeGood, &r10_bio->state) || in raid10d()
2798 test_bit(R10BIO_WriteError, &r10_bio->state)) in raid10d()
2800 else if (test_bit(R10BIO_IsReshape, &r10_bio->state)) in raid10d()
2802 else if (test_bit(R10BIO_IsSync, &r10_bio->state)) in raid10d()
2804 else if (test_bit(R10BIO_IsRecover, &r10_bio->state)) in raid10d()
2806 else if (test_bit(R10BIO_ReadError, &r10_bio->state)) in raid10d()
2844 if (test_bit(MD_RECOVERY_SYNC, &conf->mddev->recovery) || in raid10_alloc_init_r10buf()
2845 test_bit(MD_RECOVERY_RESHAPE, &conf->mddev->recovery)) in raid10_alloc_init_r10buf()
2960 !test_bit(MD_RECOVERY_SYNC, &mddev->recovery) && in raid10_sync_request()
2961 !test_bit(MD_RECOVERY_REQUESTED, &mddev->recovery) && in raid10_sync_request()
2962 !test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery) && in raid10_sync_request()
2970 if (test_bit(MD_RECOVERY_SYNC, &mddev->recovery) || in raid10_sync_request()
2971 test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery)) in raid10_sync_request()
2986 if (test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery)) { in raid10_sync_request()
2993 if (test_bit(MD_RECOVERY_SYNC, &mddev->recovery)) in raid10_sync_request()
3006 && test_bit(MD_RECOVERY_SYNC, &mddev->recovery)) { in raid10_sync_request()
3027 if (test_bit(MD_RECOVERY_RESHAPE, &mddev->recovery)) in raid10_sync_request()
3071 if (!test_bit(MD_RECOVERY_SYNC, &mddev->recovery)) { in raid10_sync_request()
3090 test_bit(Faulty, &mrdev->flags) || in raid10_sync_request()
3091 test_bit(In_sync, &mrdev->flags)) && in raid10_sync_request()
3093 test_bit(Faulty, &mreplace->flags))) { in raid10_sync_request()
3109 if (mreplace && test_bit(Faulty, &mreplace->flags)) in raid10_sync_request()
3155 if (rdev == NULL || test_bit(Faulty, &rdev->flags)) { in raid10_sync_request()
3174 !test_bit(In_sync, &rdev->flags)) in raid10_sync_request()
3197 if (test_bit(FailFast, &rdev->flags)) in raid10_sync_request()
3216 if (!test_bit(In_sync, &mrdev->flags)) { in raid10_sync_request()
3242 test_bit(Faulty, &mreplace->flags)) in raid10_sync_request()
3266 if (!test_bit(In_sync, in raid10_sync_request()
3309 test_bit(In_sync, in raid10_sync_request()
3344 !conf->fullsync && !test_bit(MD_RECOVERY_REQUESTED, in raid10_sync_request()
3379 if (rdev == NULL || test_bit(Faulty, &rdev->flags)) { in raid10_sync_request()
3402 if (test_bit(FailFast, &rdev->flags)) in raid10_sync_request()
3409 if (rdev == NULL || test_bit(Faulty, &rdev->flags)) { in raid10_sync_request()
3424 if (test_bit(FailFast, &rdev->flags)) in raid10_sync_request()
3475 test_bit(MD_RECOVERY_SYNC, &mddev->recovery)) { in raid10_sync_request()
3819 if (test_bit(Replacement, &rdev->flags)) { in raid10_run()
3888 !test_bit(In_sync, &disk->rdev->flags)) { in raid10_run()
3897 !test_bit(In_sync, &disk->replacement->flags) && in raid10_run()
4171 if (!rdev || test_bit(Faulty, &rdev->flags)) in calc_degraded()
4173 else if (!test_bit(In_sync, &rdev->flags)) in calc_degraded()
4187 if (!rdev || test_bit(Faulty, &rdev->flags)) in calc_degraded()
4189 else if (!test_bit(In_sync, &rdev->flags)) { in calc_degraded()
4226 if (test_bit(MD_RECOVERY_RUNNING, &mddev->recovery)) in raid10_start_reshape()
4238 if (!test_bit(In_sync, &rdev->flags) in raid10_start_reshape()
4239 && !test_bit(Faulty, &rdev->flags)) in raid10_start_reshape()
4298 !test_bit(Faulty, &rdev->flags)) { in raid10_start_reshape()
4310 && !test_bit(Faulty, &rdev->flags)) { in raid10_start_reshape()
4523 test_bit(MD_RECOVERY_INTR, &mddev->recovery)); in reshape_request()
4524 if (test_bit(MD_RECOVERY_INTR, &mddev->recovery)) { in reshape_request()
4544 BUG_ON(!test_bit(R10BIO_Previous, &r10_bio->state)); in reshape_request()
4589 if (!rdev2 || test_bit(Faulty, &rdev2->flags)) in reshape_request()
4659 if (!test_bit(R10BIO_Uptodate, &r10_bio->state)) in reshape_request_write()
4682 if (!rdev || test_bit(Faulty, &rdev->flags)) { in reshape_request_write()
4698 if (test_bit(MD_RECOVERY_INTR, &conf->mddev->recovery)) in end_reshape()
4760 test_bit(Faulty, &rdev->flags) || in handle_reshape_read_error()
4761 !test_bit(In_sync, &rdev->flags)) in handle_reshape_read_error()
4838 if (test_bit(MD_RECOVERY_INTR, &mddev->recovery)) in raid10_finish_reshape()