	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ar_read
_ar_read:                               ## @ar_read
	.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, %r13
	callq	_video_devdata
	movq	%rax, %rdi
	callq	_video_get_drvdata
	movq	%rax, %r14
	movq	(%rax), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_DEBUG
	movq	_AR_SIZE_QVGA@GOTPCREL(%rip), %rsi
	movq	8(%r14), %rdi
	movq	16(%r14), %rcx
	movq	_AR_MODE_NORMAL@GOTPCREL(%rip), %rdx
	movl	$0, %eax
	cmpq	(%rsi), %rdi
	jne	LBB0_2
## %bb.1:
	movq	_ARVCR1_QVGA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_2:
	cmpq	(%rdx), %rcx
	jne	LBB0_4
## %bb.3:
	movq	_ARVCR1_NORMAL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
LBB0_4:
	orl	%eax, %ebx
	leaq	48(%r14), %rdi
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	callq	_mutex_lock
	movq	_ARVCR1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	callq	_ar_outl
	xorl	%eax, %eax
	callq	_disable_dma
	movq	_M32R_DMAEDET_PORTL@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movl	$32768, %edi                    ## imm = 0x8000
	callq	_ar_outl
	movq	_M32R_DMA0CR0_PORTL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movl	$-1601826048, %edi              ## imm = 0xA0861300
	callq	_ar_outl
	movq	_M32R_DMA0CR1_PORTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16777216, %edi                 ## imm = 0x1000000
	callq	_ar_outl
	movq	_ARDATA32@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movq	_M32R_DMA0CSA_PORTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ar_outl
	movl	(%rbx), %edi
	movq	_M32R_DMA0RSA_PORTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ar_outl
	movl	28(%r14), %edi
	movq	_M32R_DMA0CBCUT_PORTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ar_outl
	movl	28(%r14), %edi
	movq	_M32R_DMA0RBCUT_PORTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ar_outl
	callq	_local_irq_save
	movq	_ARVHCOUNT@GOTPCREL(%rip), %rbx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rbx), %edi
	callq	_ar_inl
	testl	%eax, %eax
	je	LBB0_7
## %bb.5:                               ##   in Loop: Header=BB0_6 Depth=1
	xorl	%eax, %eax
	callq	_cpu_relax
	jmp	LBB0_6
LBB0_7:
	movq	16(%r14), %rax
	movq	_AR_MODE_INTERLACE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	jne	LBB0_15
## %bb.8:
	movq	8(%r14), %rax
	movq	_AR_SIZE_VGA@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_15
## %bb.9:
	cmpl	$0, 32(%r14)
	jle	LBB0_21
## %bb.10:
	movq	_M32R_DMA0CDA_PORTL@GOTPCREL(%rip), %rbx
	xorl	%r13d, %r13d
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_11 Depth=1
	xorl	%eax, %eax
	callq	_disable_dma
	xorl	%eax, %eax
	callq	_clear_dma_status
	movl	(%r12), %esi
	movl	$-1601826048, %edi              ## imm = 0xA0861300
	callq	_ar_outl
	incl	%r13d
	cmpl	32(%r14), %r13d
	jge	LBB0_21
LBB0_11:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_13 Depth 2
	movl	%r13d, %edi
	callq	_wait_for_vertical_sync
	movq	_AR_HEIGHT_VGA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%eax, %ecx
	sarl	%ecx
	leal	(%r13,%r13), %eax
	movl	%r13d, %edx
	subl	%ecx, %edx
	leal	1(%rdx,%rdx), %ecx
	cmovll	%eax, %ecx
	movq	40(%r14), %rax
	movslq	%ecx, %rcx
	movq	(%rax,%rcx,8), %rdi
	callq	_virt_to_phys
	movl	(%rbx), %esi
	movl	%eax, %edi
	callq	_ar_outl
	xorl	%eax, %eax
	callq	_enable_dma
	.p2align	4, 0x90
LBB0_13:                                ##   Parent Loop BB0_11 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r15), %edi
	callq	_ar_inl
	testl	$32768, %eax                    ## imm = 0x8000
	jne	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_13 Depth=2
	xorl	%eax, %eax
	callq	_cpu_relax
	jmp	LBB0_13
LBB0_15:
	cmpl	$0, 32(%r14)
	jle	LBB0_21
## %bb.16:
	movq	_M32R_DMA0CDA_PORTL@GOTPCREL(%rip), %r13
	xorl	%ebx, %ebx
	jmp	LBB0_17
	.p2align	4, 0x90
LBB0_20:                                ##   in Loop: Header=BB0_17 Depth=1
	xorl	%eax, %eax
	callq	_disable_dma
	xorl	%eax, %eax
	callq	_clear_dma_status
	movl	(%r12), %esi
	movl	$-1601826048, %edi              ## imm = 0xA0861300
	callq	_ar_outl
	incq	%rbx
	movslq	32(%r14), %rax
	cmpq	%rax, %rbx
	jge	LBB0_21
LBB0_17:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_19 Depth 2
	movl	%ebx, %edi
	callq	_wait_for_vertical_sync
	movq	40(%r14), %rax
	movq	(%rax,%rbx,8), %rdi
	callq	_virt_to_phys
	movl	(%r13), %esi
	movl	%eax, %edi
	callq	_ar_outl
	xorl	%eax, %eax
	callq	_enable_dma
	.p2align	4, 0x90
LBB0_19:                                ##   Parent Loop BB0_17 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r15), %edi
	callq	_ar_inl
	testl	$32768, %eax                    ## imm = 0x8000
	jne	LBB0_20
## %bb.18:                              ##   in Loop: Header=BB0_19 Depth=2
	xorl	%eax, %eax
	callq	_cpu_relax
	jmp	LBB0_19
LBB0_21:
	callq	_local_irq_restore
	movl	32(%r14), %r9d
	testl	%r9d, %r9d
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	jle	LBB0_28
## %bb.22:
	movq	_yuv@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%r14), %rsi
	movq	%rsi, %r10
	shrq	$63, %r10
	addq	%rsi, %r10
	sarq	%r10
	addq	%rax, %r10
	leaq	3(%rsi), %rdx
	testq	%rsi, %rsi
	cmovnsq	%rsi, %rdx
	sarq	$2, %rdx
	addq	%r10, %rdx
	movl	28(%r14), %ebx
	xorl	%r8d, %r8d
	jmp	LBB0_23
	.p2align	4, 0x90
LBB0_27:                                ##   in Loop: Header=BB0_23 Depth=1
	incq	%r8
	movslq	%r9d, %rsi
	cmpq	%rsi, %r8
	jge	LBB0_28
LBB0_23:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_25 Depth 2
	testl	%ebx, %ebx
	jle	LBB0_27
## %bb.24:                              ##   in Loop: Header=BB0_23 Depth=1
	movq	40(%r14), %rsi
	movq	(%rsi,%r8,8), %rcx
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_25:                                ##   Parent Loop BB0_23 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movzbl	(%rcx,%rsi), %ebx
	movb	%bl, (%rax)
	movzbl	1(%rcx,%rsi), %ebx
	movb	%bl, (%r10)
	incq	%r10
	movzbl	2(%rcx,%rsi), %ebx
	movb	%bl, 1(%rax)
	addq	$2, %rax
	movzbl	3(%rcx,%rsi), %ebx
	movb	%bl, (%rdx)
	incq	%rdx
	movl	28(%r14), %ebx
	addq	$4, %rsi
	cmpl	%ebx, %esi
	jl	LBB0_25
## %bb.26:                              ##   in Loop: Header=BB0_23 Depth=1
	movl	32(%r14), %r9d
	jmp	LBB0_27
LBB0_28:
	movq	_yuv@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movl	(%r14), %edx
	callq	_copy_to_user
	testq	%rax, %rax
	je	LBB0_30
## %bb.29:
	leaq	L_.str.1(%rip), %rdi
	callq	_printk
	movq	_EFAULT@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subq	(%rax), %rbx
	jmp	LBB0_31
LBB0_30:
	leaq	L_.str.2(%rip), %rsi
	movl	$1, %edi
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_DEBUG
LBB0_31:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_mutex_unlock
	movq	%rbx, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ar_read()\n"

	.comm	_AR_SIZE_QVGA,8,3               ## @AR_SIZE_QVGA
	.comm	_ARVCR1_QVGA,8,3                ## @ARVCR1_QVGA
	.comm	_AR_MODE_NORMAL,8,3             ## @AR_MODE_NORMAL
	.comm	_ARVCR1_NORMAL,8,3              ## @ARVCR1_NORMAL
	.comm	_ARVCR1,4,2                     ## @ARVCR1
	.comm	_M32R_DMAEDET_PORTL,4,2         ## @M32R_DMAEDET_PORTL
	.comm	_M32R_DMA0CR0_PORTL,4,2         ## @M32R_DMA0CR0_PORTL
	.comm	_M32R_DMA0CR1_PORTL,4,2         ## @M32R_DMA0CR1_PORTL
	.comm	_ARDATA32,4,2                   ## @ARDATA32
	.comm	_M32R_DMA0CSA_PORTL,4,2         ## @M32R_DMA0CSA_PORTL
	.comm	_M32R_DMA0RSA_PORTL,4,2         ## @M32R_DMA0RSA_PORTL
	.comm	_M32R_DMA0CBCUT_PORTL,4,2       ## @M32R_DMA0CBCUT_PORTL
	.comm	_M32R_DMA0RBCUT_PORTL,4,2       ## @M32R_DMA0RBCUT_PORTL
	.comm	_ARVHCOUNT,4,2                  ## @ARVHCOUNT
	.comm	_AR_MODE_INTERLACE,8,3          ## @AR_MODE_INTERLACE
	.comm	_AR_SIZE_VGA,8,3                ## @AR_SIZE_VGA
	.comm	_AR_HEIGHT_VGA,4,2              ## @AR_HEIGHT_VGA
	.comm	_M32R_DMA0CDA_PORTL,4,2         ## @M32R_DMA0CDA_PORTL
	.comm	_yuv,8,3                        ## @yuv
L_.str.1:                               ## @.str.1
	.asciz	"arv: failed while copy_to_user yuv.\n"

	.comm	_EFAULT,8,3                     ## @EFAULT
L_.str.2:                               ## @.str.2
	.asciz	"ret = %d\n"

	.comm	_ARVCR1_HIEN,8,3                ## @ARVCR1_HIEN
	.comm	_EINTR,8,3                      ## @EINTR
	.comm	_M32R_DMA0RDA_PORTL,4,2         ## @M32R_DMA0RDA_PORTL
	.comm	_current,4,2                    ## @current
	.no_dead_strip	_ar_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ar_read
_ar_read:                               ; @ar_read
	.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	x20, x1
	bl	_video_devdata
	bl	_video_get_drvdata
	mov	x22, x0
	ldr	x19, [x0]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_DEBUG
Lloh2:
	adrp	x8, _AR_SIZE_QVGA@GOTPAGE
Lloh3:
	ldr	x8, [x8, _AR_SIZE_QVGA@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
Lloh5:
	adrp	x9, _ARVCR1_QVGA@GOTPAGE
Lloh6:
	ldr	x9, [x9, _ARVCR1_QVGA@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	ldp	x10, x11, [x22, #8]
Lloh8:
	adrp	x12, _AR_MODE_NORMAL@GOTPAGE
Lloh9:
	ldr	x12, [x12, _AR_MODE_NORMAL@GOTPAGEOFF]
Lloh10:
	ldr	x12, [x12]
Lloh11:
	adrp	x13, _ARVCR1_NORMAL@GOTPAGE
Lloh12:
	ldr	x13, [x13, _ARVCR1_NORMAL@GOTPAGEOFF]
Lloh13:
	ldr	w13, [x13]
	cmp	x10, x8
	csel	w8, w9, wzr, eq
	cmp	x11, x12
	csel	w9, w13, wzr, eq
	orr	w23, w9, w8
	add	x21, x22, #48
	mov	x0, x21
	bl	_mutex_lock
Lloh14:
	adrp	x8, _ARVCR1@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ARVCR1@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	x0, x23
	bl	_ar_outl
	bl	_disable_dma
Lloh17:
	adrp	x24, _M32R_DMAEDET_PORTL@GOTPAGE
Lloh18:
	ldr	x24, [x24, _M32R_DMAEDET_PORTL@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	w0, #32768
	bl	_ar_outl
Lloh19:
	adrp	x25, _M32R_DMA0CR0_PORTL@GOTPAGE
Lloh20:
	ldr	x25, [x25, _M32R_DMA0CR0_PORTL@GOTPAGEOFF]
	ldr	w1, [x25]
	mov	w0, #4864
	movk	w0, #41094, lsl #16
	bl	_ar_outl
Lloh21:
	adrp	x8, _M32R_DMA0CR1_PORTL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _M32R_DMA0CR1_PORTL@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	mov	w0, #16777216
	bl	_ar_outl
Lloh24:
	adrp	x23, _ARDATA32@GOTPAGE
Lloh25:
	ldr	x23, [x23, _ARDATA32@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh26:
	adrp	x8, _M32R_DMA0CSA_PORTL@GOTPAGE
Lloh27:
	ldr	x8, [x8, _M32R_DMA0CSA_PORTL@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
	bl	_ar_outl
	ldr	w0, [x23]
Lloh29:
	adrp	x8, _M32R_DMA0RSA_PORTL@GOTPAGE
Lloh30:
	ldr	x8, [x8, _M32R_DMA0RSA_PORTL@GOTPAGEOFF]
Lloh31:
	ldr	w1, [x8]
	bl	_ar_outl
	ldr	w0, [x22, #28]
Lloh32:
	adrp	x8, _M32R_DMA0CBCUT_PORTL@GOTPAGE
Lloh33:
	ldr	x8, [x8, _M32R_DMA0CBCUT_PORTL@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	bl	_ar_outl
	ldr	w0, [x22, #28]
Lloh35:
	adrp	x8, _M32R_DMA0RBCUT_PORTL@GOTPAGE
Lloh36:
	ldr	x8, [x8, _M32R_DMA0RBCUT_PORTL@GOTPAGEOFF]
Lloh37:
	ldr	w1, [x8]
	bl	_ar_outl
	bl	_local_irq_save
Lloh38:
	adrp	x23, _ARVHCOUNT@GOTPAGE
Lloh39:
	ldr	x23, [x23, _ARVHCOUNT@GOTPAGEOFF]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x23]
	bl	_ar_inl
	cbz	w0, LBB0_3
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	bl	_cpu_relax
	b	LBB0_1
LBB0_3:
	ldr	x8, [x22, #16]
Lloh40:
	adrp	x9, _AR_MODE_INTERLACE@GOTPAGE
Lloh41:
	ldr	x9, [x9, _AR_MODE_INTERLACE@GOTPAGEOFF]
Lloh42:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_11
; %bb.4:
	ldr	x8, [x22, #8]
Lloh43:
	adrp	x9, _AR_SIZE_VGA@GOTPAGE
Lloh44:
	ldr	x9, [x9, _AR_SIZE_VGA@GOTPAGEOFF]
Lloh45:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_11
; %bb.5:
	ldr	w8, [x22, #32]
	cmp	w8, #1
	b.lt	LBB0_17
; %bb.6:
	mov	w23, #0
Lloh46:
	adrp	x26, _AR_HEIGHT_VGA@GOTPAGE
Lloh47:
	ldr	x26, [x26, _AR_HEIGHT_VGA@GOTPAGEOFF]
Lloh48:
	adrp	x27, _M32R_DMA0CDA_PORTL@GOTPAGE
Lloh49:
	ldr	x27, [x27, _M32R_DMA0CDA_PORTL@GOTPAGEOFF]
	b	LBB0_8
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	bl	_disable_dma
	bl	_clear_dma_status
	ldr	w1, [x25]
	mov	w0, #4864
	movk	w0, #41094, lsl #16
	bl	_ar_outl
	add	w23, w23, #1
	ldr	w8, [x22, #32]
	cmp	w23, w8
	b.ge	LBB0_17
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	mov	x0, x23
	bl	_wait_for_vertical_sync
	ldr	w8, [x26]
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w8, w8, #1
	lsl	w9, w23, #1
	subs	w8, w23, w8
	mov	w10, #1
	bfi	w10, w8, #1, #31
	csel	w8, w9, w10, lt
	ldr	x9, [x22, #40]
	ldr	x0, [x9, w8, sxtw #3]
	bl	_virt_to_phys
	ldr	w1, [x27]
	bl	_ar_outl
	bl	_enable_dma
LBB0_9:                                 ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w0, [x24]
	bl	_ar_inl
	tbnz	w0, #15, LBB0_7
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=2
	bl	_cpu_relax
	b	LBB0_9
LBB0_11:
	ldr	w8, [x22, #32]
	cmp	w8, #1
	b.lt	LBB0_17
; %bb.12:
	mov	x23, #0
Lloh50:
	adrp	x26, _M32R_DMA0CDA_PORTL@GOTPAGE
Lloh51:
	ldr	x26, [x26, _M32R_DMA0CDA_PORTL@GOTPAGEOFF]
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=1
	bl	_disable_dma
	bl	_clear_dma_status
	ldr	w1, [x25]
	mov	w0, #4864
	movk	w0, #41094, lsl #16
	bl	_ar_outl
	add	x23, x23, #1
	ldrsw	x8, [x22, #32]
	cmp	x23, x8
	b.ge	LBB0_17
LBB0_14:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_15 Depth 2
	mov	x0, x23
	bl	_wait_for_vertical_sync
	ldr	x8, [x22, #40]
	ldr	x0, [x8, x23, lsl #3]
	bl	_virt_to_phys
	ldr	w1, [x26]
	bl	_ar_outl
	bl	_enable_dma
LBB0_15:                                ;   Parent Loop BB0_14 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w0, [x24]
	bl	_ar_inl
	tbnz	w0, #15, LBB0_13
; %bb.16:                               ;   in Loop: Header=BB0_15 Depth=2
	bl	_cpu_relax
	b	LBB0_15
LBB0_17:
	bl	_local_irq_restore
	ldr	w13, [x22, #32]
Lloh52:
	adrp	x8, _yuv@GOTPAGE
Lloh53:
	ldr	x8, [x8, _yuv@GOTPAGEOFF]
	cmp	w13, #1
	b.lt	LBB0_24
; %bb.18:
	mov	x9, #0
	ldr	x12, [x8]
	ldr	x10, [x22]
	add	x11, x10, #3
	cmp	x10, #0
	csel	x11, x11, x10, lt
	cinc	x10, x10, lt
	add	x10, x12, x10, asr #1
	add	x11, x10, x11, asr #2
	ldr	w14, [x22, #28]
	b	LBB0_20
LBB0_19:                                ;   in Loop: Header=BB0_20 Depth=1
	add	x9, x9, #1
	cmp	x9, w13, sxtw
	b.ge	LBB0_24
LBB0_20:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_22 Depth 2
	cmp	w14, #1
	b.lt	LBB0_19
; %bb.21:                               ;   in Loop: Header=BB0_20 Depth=1
	mov	x13, #0
	ldr	x14, [x22, #40]
	ldr	x15, [x14, x9, lsl #3]
LBB0_22:                                ;   Parent Loop BB0_20 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	x14, x15, x13
	ldrb	w16, [x14]
	strb	w16, [x12]
	ldrb	w16, [x14, #1]
	strb	w16, [x10], #1
	ldrb	w17, [x14, #2]
	add	x16, x12, #2
	strb	w17, [x12, #1]
	ldrb	w12, [x14, #3]
	strb	w12, [x11], #1
	ldr	w14, [x22, #28]
	add	x13, x13, #4
	mov	x12, x16
	cmp	w13, w14
	b.lt	LBB0_22
; %bb.23:                               ;   in Loop: Header=BB0_20 Depth=1
	ldr	w13, [x22, #32]
	mov	x12, x16
	b	LBB0_19
LBB0_24:
	ldr	x1, [x8]
	ldr	w2, [x22]
	mov	x0, x20
	bl	_copy_to_user
	cbz	x0, LBB0_26
; %bb.25:
Lloh54:
	adrp	x0, l_.str.1@PAGE
Lloh55:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_printk
Lloh56:
	adrp	x8, _EFAULT@GOTPAGE
Lloh57:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
Lloh58:
	ldr	x8, [x8]
	neg	x19, x8
	b	LBB0_27
LBB0_26:
	str	x19, [sp]
Lloh59:
	adrp	x1, l_.str.2@PAGE
Lloh60:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_DEBUG
LBB0_27:
	mov	x0, x21
	bl	_mutex_unlock
	mov	x0, x19
	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 AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGot	Lloh48, Lloh49
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh50, Lloh51
	.loh AdrpLdrGot	Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpAdd	Lloh54, Lloh55
	.loh AdrpAdd	Lloh59, Lloh60
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ar_read()\n"

	.comm	_AR_SIZE_QVGA,8,3               ; @AR_SIZE_QVGA
	.comm	_ARVCR1_QVGA,8,3                ; @ARVCR1_QVGA
	.comm	_AR_MODE_NORMAL,8,3             ; @AR_MODE_NORMAL
	.comm	_ARVCR1_NORMAL,8,3              ; @ARVCR1_NORMAL
	.comm	_ARVCR1,4,2                     ; @ARVCR1
	.comm	_M32R_DMAEDET_PORTL,4,2         ; @M32R_DMAEDET_PORTL
	.comm	_M32R_DMA0CR0_PORTL,4,2         ; @M32R_DMA0CR0_PORTL
	.comm	_M32R_DMA0CR1_PORTL,4,2         ; @M32R_DMA0CR1_PORTL
	.comm	_ARDATA32,4,2                   ; @ARDATA32
	.comm	_M32R_DMA0CSA_PORTL,4,2         ; @M32R_DMA0CSA_PORTL
	.comm	_M32R_DMA0RSA_PORTL,4,2         ; @M32R_DMA0RSA_PORTL
	.comm	_M32R_DMA0CBCUT_PORTL,4,2       ; @M32R_DMA0CBCUT_PORTL
	.comm	_M32R_DMA0RBCUT_PORTL,4,2       ; @M32R_DMA0RBCUT_PORTL
	.comm	_ARVHCOUNT,4,2                  ; @ARVHCOUNT
	.comm	_AR_MODE_INTERLACE,8,3          ; @AR_MODE_INTERLACE
	.comm	_AR_SIZE_VGA,8,3                ; @AR_SIZE_VGA
	.comm	_AR_HEIGHT_VGA,4,2              ; @AR_HEIGHT_VGA
	.comm	_M32R_DMA0CDA_PORTL,4,2         ; @M32R_DMA0CDA_PORTL
	.comm	_yuv,8,3                        ; @yuv
l_.str.1:                               ; @.str.1
	.asciz	"arv: failed while copy_to_user yuv.\n"

	.comm	_EFAULT,8,3                     ; @EFAULT
l_.str.2:                               ; @.str.2
	.asciz	"ret = %d\n"

	.comm	_ARVCR1_HIEN,8,3                ; @ARVCR1_HIEN
	.comm	_EINTR,8,3                      ; @EINTR
	.comm	_M32R_DMA0RDA_PORTL,4,2         ; @M32R_DMA0RDA_PORTL
	.comm	_current,4,2                    ; @current
	.no_dead_strip	_ar_read
.subsections_via_symbols
