I didn't buy this. Is there any better argument why you need redundantI think because this judgement is in the general IO process, there are also+ if (test_bit(QUEUE_FLAG_HCTX_ACTIVE, &q->queue_flags) ||Whoever wrote this code did too much defensive programming, because the first
+ test_and_set_bit(QUEUE_FLAG_HCTX_ACTIVE, &q->queue_flags)) {
conditional doesn't make much sense here. Am I right?
some performance considerations here.
test_bit() call?