
static int io_register_personality(struct io_ring_ctx *ctx)
{
	const struct cred *creds;
	int ret;

	creds = get_current_cred();

	ret = idr_alloc_cyclic(&ctx->personality_idr, (void *) creds, 1,
				USHRT_MAX, GFP_KERNEL);
	if (ret < 0)
		put_cred(creds);
	return ret;

static int io_register_personality(struct io_ring_ctx *ctx)
{
	const struct cred *creds;
	int ret;

	creds = get_current_cred();

	ret = idr_alloc_cyclic(&ctx->personality_idr, (void *) creds, 1,
				USHRT_MAX, GFP_KERNEL);
	if (ret < 0)
		put_cred(creds);
	return ret;