	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function kvmgt_page_track_remove
_kvmgt_page_track_remove:               ## @kvmgt_page_track_remove
	.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
	movl	%esi, %r15d
	movq	%rdi, %rbx
	callq	_handle_valid
	xorl	%ecx, %ecx
	testl	%eax, %eax
	je	LBB0_6
## %bb.1:
	movq	(%rbx), %r12
	movq	%r12, %rdi
	callq	_srcu_read_lock
	movl	%eax, %r14d
	movq	%r12, %rdi
	movl	%r15d, %esi
	callq	_gfn_to_memslot
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	movq	%rax, %r13
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	leaq	4(%r12), %r14
	movq	%r14, %rdi
	callq	_spin_lock
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_kvmgt_gfn_is_write_protected
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	movq	_KVM_PAGE_TRACK_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r12, %rdi
	movq	%r13, %rsi
	movl	%r15d, %edx
	callq	_kvm_slot_page_track_remove_page
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_kvmgt_protect_table_del
LBB0_5:
	movq	%r14, %rdi
	callq	_spin_unlock
	movq	%r12, %rdi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	callq	_srcu_read_unlock
	xorl	%ecx, %ecx
	jmp	LBB0_6
LBB0_2:
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	_srcu_read_unlock
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	subl	(%rax), %ecx
LBB0_6:
	movl	%ecx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_KVM_PAGE_TRACK_WRITE,4,2       ## @KVM_PAGE_TRACK_WRITE
	.no_dead_strip	_kvmgt_page_track_remove
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function kvmgt_page_track_remove
_kvmgt_page_track_remove:               ; @kvmgt_page_track_remove
	.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	x20, x1
	mov	x22, x0
	bl	_handle_valid
	cbz	w0, LBB0_6
; %bb.1:
	ldr	x19, [x22]
	mov	x0, x19
	bl	_srcu_read_lock
	mov	x21, x0
	mov	x0, x19
	mov	x1, x20
	bl	_gfn_to_memslot
	cbz	x0, LBB0_5
; %bb.2:
	mov	x24, x0
	add	x23, x19, #4
	mov	x0, x23
	bl	_spin_lock
	mov	x0, x22
	mov	x1, x20
	bl	_kvmgt_gfn_is_write_protected
	cbz	w0, LBB0_4
; %bb.3:
Lloh0:
	adrp	x8, _KVM_PAGE_TRACK_WRITE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _KVM_PAGE_TRACK_WRITE@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	mov	x0, x19
	mov	x1, x24
	mov	x2, x20
	bl	_kvm_slot_page_track_remove_page
	mov	x0, x22
	mov	x1, x20
	bl	_kvmgt_protect_table_del
LBB0_4:
	mov	x0, x23
	bl	_spin_unlock
	mov	x0, x19
	mov	x1, x21
	bl	_srcu_read_unlock
	mov	w0, #0
	b	LBB0_6
LBB0_5:
	mov	x0, x19
	mov	x1, x21
	bl	_srcu_read_unlock
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_6:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_KVM_PAGE_TRACK_WRITE,4,2       ; @KVM_PAGE_TRACK_WRITE
	.no_dead_strip	_kvmgt_page_track_remove
.subsections_via_symbols
