	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_key_unlink                     ## -- Begin function key_unlink
	.p2align	4, 0x90
_key_unlink:                            ## @key_unlink
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, %r15
	callq	_key_check
	movq	%r12, %rdi
	callq	_key_check
	movq	16(%r15), %rax
	cmpq	_key_type_keyring@GOTPCREL(%rip), %rax
	je	LBB0_3
## %bb.1:
	movq	_ENOTDIR@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_3:
	movq	%r15, %rdi
	callq	_down_write
	movq	%r15, %rdi
	callq	_rcu_dereference_locked_keyring
	testq	%rax, %rax
	je	LBB0_8
## %bb.4:
	movq	%rax, %r14
	movl	(%rax), %eax
	testl	%eax, %eax
	jle	LBB0_8
## %bb.5:
	movq	16(%r14), %rcx
	shlq	$3, %rax
	xorl	%r13d, %r13d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%r12, (%rcx,%rbx)
	je	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	addq	$8, %rbx
	incl	%r13d
	cmpq	%rbx, %rax
	jne	LBB0_6
LBB0_8:
	movq	%r15, %rdi
	callq	_up_write
	movq	_ENOENT@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_15:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movl	4(%r14), %eax
	leal	24(,%rax,8), %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_16
## %bb.10:
	movq	%rax, %r12
	movl	4(%r14), %eax
	movl	%eax, 4(%r12)
	movl	(%r14), %edx
	decl	%edx
	movl	%edx, (%r12)
	testl	%r13d, %r13d
	je	LBB0_12
## %bb.11:
	movq	16(%r12), %rdi
	movq	16(%r14), %rsi
	movl	%ebx, %edx
	callq	_memcpy
	movl	(%r12), %edx
LBB0_12:
	subl	%r13d, %edx
	jle	LBB0_14
## %bb.13:
	movq	16(%r12), %rdi
	addq	%rbx, %rdi
	movq	16(%r14), %rax
	leaq	(%rax,%rbx), %rsi
	addq	$8, %rsi
	shll	$3, %edx
	callq	_memcpy
LBB0_14:
	movq	8(%r15), %rsi
	movq	_KEYQUOTA_LINK_BYTES@GOTPCREL(%rip), %rax
	subq	(%rax), %rsi
	movq	%r15, %rdi
	callq	_key_payload_reserve
	movl	4(%r15), %edi
	movq	%r12, %rsi
	callq	_rcu_assign_pointer
	movq	%r15, %rdi
	callq	_up_write
	movl	%r13d, 8(%r14)
	addq	$12, %r14
	movq	_keyring_unlink_rcu_disposal@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_call_rcu
	xorl	%ebx, %ebx
	jmp	LBB0_15
LBB0_16:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	%r15, %rdi
	callq	_up_write
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOTDIR,4,2                    ## @ENOTDIR
	.comm	_key_type_keyring,4,2           ## @key_type_keyring
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_KEYQUOTA_LINK_BYTES,8,3        ## @KEYQUOTA_LINK_BYTES
	.comm	_keyring_unlink_rcu_disposal,4,2 ## @keyring_unlink_rcu_disposal
	.comm	_ENOMEM,4,2                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_key_unlink                     ; -- Begin function key_unlink
	.p2align	2
_key_unlink:                            ; @key_unlink
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x22, x1
	mov	x19, x0
	bl	_key_check
	mov	x0, x22
	bl	_key_check
	ldr	x8, [x19, #16]
Lloh0:
	adrp	x9, _key_type_keyring@GOTPAGE
Lloh1:
	ldr	x9, [x9, _key_type_keyring@GOTPAGEOFF]
	cmp	x8, x9
	b.eq	LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _ENOTDIR@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENOTDIR@GOTPAGEOFF]
	b	LBB0_8
LBB0_2:
	mov	x0, x19
	bl	_down_write
	mov	x0, x19
	bl	_rcu_dereference_locked_keyring
	cbz	x0, LBB0_7
; %bb.3:
	mov	x20, x0
	ldr	w9, [x0]
	cmp	w9, #1
	b.lt	LBB0_7
; %bb.4:
	mov	w23, #0
	mov	x21, #0
	ldr	x8, [x20, #16]
	lsl	x9, x9, #3
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x8, x21]
	cmp	x10, x22
	b.eq	LBB0_10
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x21, x21, #8
	add	w23, w23, #1
	cmp	x9, x21
	b.ne	LBB0_5
LBB0_7:
	mov	x0, x19
	bl	_up_write
Lloh4:
	adrp	x8, _ENOENT@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_9:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_10:
	ldr	w8, [x20, #4]
	lsl	w8, w8, #3
	add	w0, w8, #24
Lloh6:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_kmalloc
	cbz	x0, LBB0_16
; %bb.11:
	mov	x22, x0
	ldp	w8, w9, [x20]
	sub	w8, w8, #1
	stp	w8, w9, [x0]
	cbz	w23, LBB0_13
; %bb.12:
	ldr	x0, [x22, #16]
	ldr	x1, [x20, #16]
	mov	x2, x21
	bl	_memcpy
	ldr	w8, [x22]
LBB0_13:
	subs	w8, w8, w23
	b.le	LBB0_15
; %bb.14:
	ldr	x9, [x22, #16]
	add	x0, x9, x21
	ldr	x9, [x20, #16]
	add	x9, x9, x21
	add	x1, x9, #8
	lsl	w2, w8, #3
	bl	_memcpy
LBB0_15:
	ldr	x8, [x19, #8]
Lloh9:
	adrp	x9, _KEYQUOTA_LINK_BYTES@GOTPAGE
Lloh10:
	ldr	x9, [x9, _KEYQUOTA_LINK_BYTES@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	sub	x1, x8, x9
	mov	x0, x19
	bl	_key_payload_reserve
	ldr	w0, [x19, #4]
	mov	x1, x22
	bl	_rcu_assign_pointer
	mov	x0, x19
	bl	_up_write
	str	w23, [x20, #8]
	add	x0, x20, #12
Lloh12:
	adrp	x8, _keyring_unlink_rcu_disposal@GOTPAGE
Lloh13:
	ldr	x8, [x8, _keyring_unlink_rcu_disposal@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	bl	_call_rcu
	mov	w20, #0
	b	LBB0_9
LBB0_16:
Lloh15:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w20, w8
	mov	x0, x19
	bl	_up_write
	b	LBB0_9
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOTDIR,4,2                    ; @ENOTDIR
	.comm	_key_type_keyring,4,2           ; @key_type_keyring
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_KEYQUOTA_LINK_BYTES,8,3        ; @KEYQUOTA_LINK_BYTES
	.comm	_keyring_unlink_rcu_disposal,4,2 ; @keyring_unlink_rcu_disposal
	.comm	_ENOMEM,4,2                     ; @ENOMEM
.subsections_via_symbols
