	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function videobuf_dma_contig_user_get
_videobuf_dma_contig_user_get:          ## @videobuf_dma_contig_user_get
	.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
	subq	$24, %rsp
	.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
	movq	_current@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %r14
	movl	8(%rsi), %edi
	callq	_PAGE_ALIGN
	movq	%rax, (%r15)
	movl	$0, 8(%r15)
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	%r14, %rdi
	callq	_down_read
	movq	(%r12), %rsi
	movq	%r14, %rdi
	callq	_find_vma
	testq	%rax, %rax
	je	LBB0_15
## %bb.1:
	movq	(%r12), %r12
	movq	(%r15), %rdx
	leaq	(%rdx,%r12), %rcx
	cmpq	(%rax), %rcx
	jg	LBB0_15
## %bb.2:
	movq	%r15, %rdi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarq	%cl, %rdx
	testq	%rdx, %rdx
	je	LBB0_13
## %bb.3:
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%r15, %rax
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
LBB0_11:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rdx
	addq	(%rdx), %r12
	incq	%r13
	movq	(%rdi), %rdx
                                        ## kill: def $cl killed $cl killed $rcx
	sarq	%cl, %rdx
	movq	%rsi, %r14
	cmpq	%rdx, %r13
	jae	LBB0_14
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rax, %r15
	movq	%rax, %rdi
	movq	%r12, %rsi
	leaq	-56(%rbp), %rdx
	callq	_follow_pfn
	testl	%eax, %eax
	jne	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	-56(%rbp), %rsi
	testq	%r13, %r13
	je	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	incq	%r14
	cmpq	%r14, %rsi
	je	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	_EFAULT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	testl	%ebx, %ebx
	je	LBB0_10
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_4 Depth=1
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%rsi, %rdx
	shlq	%cl, %rdx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rdx, 16(%rdi)
	movq	%r15, %rax
	jmp	LBB0_11
LBB0_5:
	movl	%eax, %ebx
	jmp	LBB0_15
LBB0_12:
	negl	%ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
LBB0_13:
	testl	%ebx, %ebx
	jne	LBB0_15
LBB0_14:
	movl	$1, 8(%rdi)
	xorl	%ebx, %ebx
LBB0_15:
	movq	_current@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rdi
	callq	_up_read
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_current,8,3                    ## @current
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_PAGE_SHIFT,8,3                 ## @PAGE_SHIFT
	.comm	_EFAULT,4,2                     ## @EFAULT
	.comm	_PAGE_SIZE,8,3                  ## @PAGE_SIZE
	.no_dead_strip	_videobuf_dma_contig_user_get
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function videobuf_dma_contig_user_get
_videobuf_dma_contig_user_get:          ; @videobuf_dma_contig_user_get
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x23, _current@GOTPAGE
Lloh1:
	ldr	x23, [x23, _current@GOTPAGEOFF]
	ldr	x8, [x23]
	ldr	x20, [x8]
	ldr	w0, [x1, #8]
	bl	_PAGE_ALIGN
	str	x0, [x19]
	str	wzr, [x19, #8]
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w22, w8
	mov	x0, x20
	bl	_down_read
	ldr	x1, [x21]
	mov	x0, x20
	bl	_find_vma
	cbz	x0, LBB0_14
; %bb.1:
	mov	x20, x0
	ldr	x21, [x21]
	ldr	x8, [x19]
	ldr	x9, [x0]
	add	x10, x8, x21
	cmp	x10, x9
	b.gt	LBB0_14
; %bb.2:
Lloh5:
	adrp	x24, _PAGE_SHIFT@GOTPAGE
Lloh6:
	ldr	x24, [x24, _PAGE_SHIFT@GOTPAGEOFF]
	ldr	x9, [x24]
	asr	x8, x8, x9
	cbz	x8, LBB0_12
; %bb.3:
	mov	x25, #0
	mov	x28, #0
Lloh7:
	adrp	x26, _PAGE_SIZE@GOTPAGE
Lloh8:
	ldr	x26, [x26, _PAGE_SIZE@GOTPAGEOFF]
Lloh9:
	adrp	x27, _EFAULT@GOTPAGE
Lloh10:
	ldr	x27, [x27, _EFAULT@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x9, [x24]
	lsl	x10, x8, x9
	str	x10, [x19, #16]
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x10, [x26]
	add	x21, x10, x21
	add	x25, x25, #1
	ldr	x10, [x19]
	asr	x9, x10, x9
	mov	x28, x8
	cmp	x25, x9
	b.hs	LBB0_13
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	add	x2, sp, #8
	mov	x0, x20
	mov	x1, x21
	bl	_follow_pfn
	cbnz	w0, LBB0_10
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [sp, #8]
	cbz	x25, LBB0_4
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x10, x28, #1
	ldr	w9, [x27]
	cmp	x8, x10
	ccmp	w9, #0, #4, ne
	b.ne	LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x9, [x24]
	b	LBB0_5
LBB0_10:
	mov	x22, x0
	b	LBB0_14
LBB0_11:
	neg	w22, w9
LBB0_12:
	cbnz	w22, LBB0_14
LBB0_13:
	mov	w22, #0
	mov	w8, #1
	str	w8, [x19, #8]
LBB0_14:
	ldr	x8, [x23]
	ldr	x0, [x8]
	bl	_up_read
	mov	x0, x22
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_current,8,3                    ; @current
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_PAGE_SHIFT,8,3                 ; @PAGE_SHIFT
	.comm	_EFAULT,4,2                     ; @EFAULT
	.comm	_PAGE_SIZE,8,3                  ; @PAGE_SIZE
	.no_dead_strip	_videobuf_dma_contig_user_get
.subsections_via_symbols
