- ld = calloc(1, sizeof(*ld));
-
- /*
- * First try passing in 0 for queue depth, since we don't
- * care about the user ring. If that fails, the kernel is too old
- * and we need the right depth.
- */
- if (!o->userspace_reap)
- err = io_queue_init(INT_MAX, &ld->aio_ctx);
- if (o->userspace_reap || err == -EINVAL)
- err = io_queue_init(td->o.iodepth, &ld->aio_ctx);