Re: [patch] remove redundant kioctx->users ref count

From: Benjamin LaHaise
Date: Fri Oct 13 2006 - 10:34:50 EST


On Thu, Oct 12, 2006 at 04:54:46PM -0700, Chen, Kenneth W wrote:
> @@ -1015,9 +1010,6 @@ put_rq:
> if (waitqueue_active(&ctx->wait))
> wake_up(&ctx->wait);
>
> - if (ret)
> - put_ioctx(ctx);
> -
> return ret;
> }

This part makes me worry -- at this point we no longer have anything
pinning the ioctx, yet we touch ->wait after dropping the lock. The
only way around this is if rcu is introduced in the final free of an
ioctx to ensure the structure remains around for a sufficient grace
period.

-ben
--
"Time is of no importance, Mr. President, only life is important."
Don't Email: <dont@xxxxxxxxx>.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/