	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cx18_av_initialize
_cx18_av_initialize:                    ## @cx18_av_initialize
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	callq	_to_cx18_av_state
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_v4l2_get_subdevdata
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_cx18_av_loadfw
	movq	_CXADEC_DL_CTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$50331648, %edx                 ## imm = 0x3000000
	movl	$50331648, %ecx                 ## imm = 0x3000000
	movl	$318767104, %r8d                ## imm = 0x13000000
	callq	_cx18_av_write4_expect
	movq	_CXADEC_HOST_REG1@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%r12, %rdi
	callq	_cx18_av_read4
	movl	%eax, %ebx
	movl	(%r15), %esi
	movl	%eax, %edx
	orl	$1, %edx
	movq	%r12, %rdi
	movl	%eax, %ecx
	movl	$65534, %r8d                    ## imm = 0xFFFE
	callq	_cx18_av_write4_expect
	movl	(%r15), %esi
	andl	$65534, %ebx                    ## imm = 0xFFFE
	movq	%r12, %rdi
	movl	%ebx, %edx
	movl	%ebx, %ecx
	movl	$65535, %r8d                    ## imm = 0xFFFF
	callq	_cx18_av_write4_expect
	movq	_CXADEC_DLL1_DIAG_CTRL@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%r12, %rdi
	callq	_cx18_av_read4
	movl	%eax, %ebx
	andl	$-503316737, %ebx               ## imm = 0xE1FFFEFF
	movl	(%r15), %esi
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_cx18_av_write4
	movl	(%r15), %esi
	orl	$268435712, %ebx                ## imm = 0x10000100
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_cx18_av_write4
	movq	_CXADEC_DLL2_DIAG_CTRL@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%r12, %rdi
	callq	_cx18_av_read4
	movl	%eax, %ebx
	andl	$-503316737, %ebx               ## imm = 0xE1FFFEFF
	movl	(%r15), %esi
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_cx18_av_write4
	movl	(%r15), %esi
	orl	$100663552, %ebx                ## imm = 0x6000100
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_cx18_av_write4
	movq	_CXADEC_AFE_DIAG_CTRL1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$661506, %edx                   ## imm = 0xA1802
	callq	_cx18_av_write4
	movq	_CXADEC_AFE_DIAG_CTRL3@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%r12, %rdi
	callq	_cx18_av_read4
	movl	%eax, %ebx
	movl	%eax, %ecx
	orl	$1, %ecx
	movl	(%r15), %esi
	movq	%r12, %rdi
	movl	%ecx, %edx
	movl	$50372367, %r8d                 ## imm = 0x3009F0F
	callq	_cx18_av_write4_expect
	movl	(%r15), %esi
	andl	$-2, %ebx
	movq	%r12, %rdi
	movl	%ebx, %edx
	movl	%ebx, %ecx
	movl	$50372367, %r8d                 ## imm = 0x3009F0F
	callq	_cx18_av_write4_expect
	movq	_CXADEC_PIN_CTRL1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-1, %edx
	movl	$265216, %ecx                   ## imm = 0x40C00
	callq	_cx18_av_and_or4
	movq	_CXADEC_PIN_CTRL2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-1, %edx
	movl	$2, %ecx
	callq	_cx18_av_and_or4
	movq	_CXADEC_SOFT_RST_CTRL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r12, %rdi
	movl	$32768, %edx                    ## imm = 0x8000
	callq	_cx18_av_write4
	movl	(%rbx), %esi
	movq	%r12, %rdi
	xorl	%edx, %edx
	callq	_cx18_av_write4
	movq	_CXADEC_CHIP_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-262145, %edx                  ## imm = 0xFFFBFFFF
	movl	$1179648, %ecx                  ## imm = 0x120000
	callq	_cx18_av_and_or4
	movq	%r12, %rdi
	callq	_cx18_av_init
	movq	_CXADEC_MODE_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-530448, %edx                  ## imm = 0xFFF7E7F0
	movl	$33818624, %ecx                 ## imm = 0x2040800
	callq	_cx18_av_and_or4
	movq	_CXADEC_CRUSH_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-1, %edx
	movl	$5242880, %ecx                  ## imm = 0x500000
	callq	_cx18_av_and_or4
	movq	_CXADEC_DFE_CTRL2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-65281, %edx                   ## imm = 0xFFFF00FF
	movl	$8192, %ecx                     ## imm = 0x2000
	callq	_cx18_av_and_or4
	movq	_CXADEC_OUT_CTRL1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$1074996526, %edx               ## imm = 0x4013252E
	callq	_cx18_av_write4
	movq	_CXADEC_AFE_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$-16777216, %edx                ## imm = 0xFF000000
	movl	$23808, %ecx                    ## imm = 0x5D00
	callq	_cx18_av_and_or4
	movq	_CXADEC_SRC_COMB_CFG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	$1713898015, %edx               ## imm = 0x6628021F
	callq	_cx18_av_write4
	movq	%r12, %rdi
	movl	$2260, %esi                     ## imm = 0x8D4
	callq	_cx18_av_read
	movl	$228, %r15d
	cmpl	$228, %eax
	jg	LBB0_2
## %bb.1:
	movl	$20, %r15d
	cmpl	$19, %eax
	jg	LBB0_3
LBB0_2:
	movq	%r12, %rdi
	movl	$2260, %esi                     ## imm = 0x8D4
	movl	%r15d, %edx
	callq	_cx18_av_write
	movl	%r15d, %eax
LBB0_3:
	shll	$8, %eax
	movl	$70144, %ecx                    ## imm = 0x11200
	subl	%eax, %ecx
	andl	$-512, %ecx                     ## imm = 0xFE00
	movq	8(%r14), %rax
	movl	%ecx, (%rax)
	movl	%ecx, 4(%rax)
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_v4l2_ctrl_handler_setup        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_CXADEC_DL_CTL,4,2              ## @CXADEC_DL_CTL
	.comm	_CXADEC_HOST_REG1,4,2           ## @CXADEC_HOST_REG1
	.comm	_CXADEC_DLL1_DIAG_CTRL,4,2      ## @CXADEC_DLL1_DIAG_CTRL
	.comm	_CXADEC_DLL2_DIAG_CTRL,4,2      ## @CXADEC_DLL2_DIAG_CTRL
	.comm	_CXADEC_AFE_DIAG_CTRL1,4,2      ## @CXADEC_AFE_DIAG_CTRL1
	.comm	_CXADEC_AFE_DIAG_CTRL3,4,2      ## @CXADEC_AFE_DIAG_CTRL3
	.comm	_CXADEC_PIN_CTRL1,4,2           ## @CXADEC_PIN_CTRL1
	.comm	_CXADEC_PIN_CTRL2,4,2           ## @CXADEC_PIN_CTRL2
	.comm	_CXADEC_SOFT_RST_CTRL,4,2       ## @CXADEC_SOFT_RST_CTRL
	.comm	_CXADEC_CHIP_CTRL,4,2           ## @CXADEC_CHIP_CTRL
	.comm	_CXADEC_MODE_CTRL,4,2           ## @CXADEC_MODE_CTRL
	.comm	_CXADEC_CRUSH_CTRL,4,2          ## @CXADEC_CRUSH_CTRL
	.comm	_CXADEC_DFE_CTRL2,4,2           ## @CXADEC_DFE_CTRL2
	.comm	_CXADEC_OUT_CTRL1,4,2           ## @CXADEC_OUT_CTRL1
	.comm	_CXADEC_AFE_CTRL,4,2            ## @CXADEC_AFE_CTRL
	.comm	_CXADEC_SRC_COMB_CFG,4,2        ## @CXADEC_SRC_COMB_CFG
	.no_dead_strip	_cx18_av_initialize
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cx18_av_initialize
_cx18_av_initialize:                    ; @cx18_av_initialize
	.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, x0
	bl	_to_cx18_av_state
	mov	x19, x0
	mov	x0, x20
	bl	_v4l2_get_subdevdata
	mov	x20, x0
	bl	_cx18_av_loadfw
Lloh0:
	adrp	x8, _CXADEC_DL_CTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CXADEC_DL_CTL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #50331648
	mov	w3, #50331648
	mov	w4, #318767104
	bl	_cx18_av_write4_expect
Lloh3:
	adrp	x22, _CXADEC_HOST_REG1@GOTPAGE
Lloh4:
	ldr	x22, [x22, _CXADEC_HOST_REG1@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	bl	_cx18_av_read4
	mov	x21, x0
	ldr	w1, [x22]
	orr	w2, w0, #0x1
	mov	x0, x20
	mov	x3, x21
	mov	w4, #65534
	bl	_cx18_av_write4_expect
	ldr	w1, [x22]
	and	w2, w21, #0xfffe
	mov	x0, x20
	mov	x3, x2
	mov	w4, #65535
	bl	_cx18_av_write4_expect
Lloh5:
	adrp	x22, _CXADEC_DLL1_DIAG_CTRL@GOTPAGE
Lloh6:
	ldr	x22, [x22, _CXADEC_DLL1_DIAG_CTRL@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	bl	_cx18_av_read4
	mov	w23, #65279
	movk	w23, #57855, lsl #16
	and	w21, w0, w23
	ldr	w1, [x22]
	mov	x0, x20
	mov	x2, x21
	bl	_cx18_av_write4
	ldr	w1, [x22]
	mov	w8, #256
	movk	w8, #4096, lsl #16
	orr	w2, w21, w8
	mov	x0, x20
	bl	_cx18_av_write4
Lloh7:
	adrp	x22, _CXADEC_DLL2_DIAG_CTRL@GOTPAGE
Lloh8:
	ldr	x22, [x22, _CXADEC_DLL2_DIAG_CTRL@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	bl	_cx18_av_read4
	and	w21, w0, w23
	ldr	w1, [x22]
	mov	x0, x20
	mov	x2, x21
	bl	_cx18_av_write4
	ldr	w1, [x22]
	mov	w8, #256
	movk	w8, #1536, lsl #16
	orr	w2, w21, w8
	mov	x0, x20
	bl	_cx18_av_write4
Lloh9:
	adrp	x8, _CXADEC_AFE_DIAG_CTRL1@GOTPAGE
Lloh10:
	ldr	x8, [x8, _CXADEC_AFE_DIAG_CTRL1@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #6146
	movk	w2, #10, lsl #16
	bl	_cx18_av_write4
Lloh12:
	adrp	x22, _CXADEC_AFE_DIAG_CTRL3@GOTPAGE
Lloh13:
	ldr	x22, [x22, _CXADEC_AFE_DIAG_CTRL3@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	bl	_cx18_av_read4
	mov	x21, x0
	orr	w2, w0, #0x1
	ldr	w1, [x22]
	mov	x0, x20
	mov	x3, x2
	mov	w4, #40719
	movk	w4, #768, lsl #16
	bl	_cx18_av_write4_expect
	ldr	w1, [x22]
	and	w2, w21, #0xfffffffe
	mov	x0, x20
	mov	x3, x2
	mov	w4, #40719
	movk	w4, #768, lsl #16
	bl	_cx18_av_write4_expect
Lloh14:
	adrp	x8, _CXADEC_PIN_CTRL1@GOTPAGE
Lloh15:
	ldr	x8, [x8, _CXADEC_PIN_CTRL1@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #-1
	mov	w3, #3072
	movk	w3, #4, lsl #16
	bl	_cx18_av_and_or4
Lloh17:
	adrp	x8, _CXADEC_PIN_CTRL2@GOTPAGE
Lloh18:
	ldr	x8, [x8, _CXADEC_PIN_CTRL2@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #-1
	mov	w3, #2
	bl	_cx18_av_and_or4
Lloh20:
	adrp	x21, _CXADEC_SOFT_RST_CTRL@GOTPAGE
Lloh21:
	ldr	x21, [x21, _CXADEC_SOFT_RST_CTRL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x20
	mov	w2, #32768
	bl	_cx18_av_write4
	ldr	w1, [x21]
	mov	x0, x20
	mov	w2, #0
	bl	_cx18_av_write4
Lloh22:
	adrp	x8, _CXADEC_CHIP_CTRL@GOTPAGE
Lloh23:
	ldr	x8, [x8, _CXADEC_CHIP_CTRL@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #-262145
	mov	w3, #1179648
	bl	_cx18_av_and_or4
	mov	x0, x20
	bl	_cx18_av_init
Lloh25:
	adrp	x8, _CXADEC_MODE_CTRL@GOTPAGE
Lloh26:
	ldr	x8, [x8, _CXADEC_MODE_CTRL@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #59376
	movk	w2, #65527, lsl #16
	mov	w3, #2048
	movk	w3, #516, lsl #16
	bl	_cx18_av_and_or4
Lloh28:
	adrp	x8, _CXADEC_CRUSH_CTRL@GOTPAGE
Lloh29:
	ldr	x8, [x8, _CXADEC_CRUSH_CTRL@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #-1
	mov	w3, #5242880
	bl	_cx18_av_and_or4
Lloh31:
	adrp	x8, _CXADEC_DFE_CTRL2@GOTPAGE
Lloh32:
	ldr	x8, [x8, _CXADEC_DFE_CTRL2@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #-65281
	mov	w3, #8192
	bl	_cx18_av_and_or4
Lloh34:
	adrp	x8, _CXADEC_OUT_CTRL1@GOTPAGE
Lloh35:
	ldr	x8, [x8, _CXADEC_OUT_CTRL1@GOTPAGEOFF]
Lloh36:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #9518
	movk	w2, #16403, lsl #16
	bl	_cx18_av_write4
Lloh37:
	adrp	x8, _CXADEC_AFE_CTRL@GOTPAGE
Lloh38:
	ldr	x8, [x8, _CXADEC_AFE_CTRL@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #-16777216
	mov	w3, #23808
	bl	_cx18_av_and_or4
Lloh40:
	adrp	x8, _CXADEC_SRC_COMB_CFG@GOTPAGE
Lloh41:
	ldr	x8, [x8, _CXADEC_SRC_COMB_CFG@GOTPAGEOFF]
Lloh42:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #543
	movk	w2, #26152, lsl #16
	bl	_cx18_av_write4
	mov	x0, x20
	mov	w1, #2260
	bl	_cx18_av_read
	cmp	w0, #228
	b.le	LBB0_2
; %bb.1:
	mov	w21, #228
	b	LBB0_4
LBB0_2:
	mov	x21, x0
	cmp	w0, #19
	b.gt	LBB0_5
; %bb.3:
	mov	w21, #20
LBB0_4:
	mov	x0, x20
	mov	w1, #2260
	mov	x2, x21
	bl	_cx18_av_write
LBB0_5:
	mov	w8, #4608
	movk	w8, #1, lsl #16
	sub	w8, w8, w21, lsl #8
	ldr	x9, [x19, #8]
	and	w8, w8, #0xfffffe00
	stp	w8, w8, [x9]
	mov	x0, x19
	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
	b	_v4l2_ctrl_handler_setup
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_CXADEC_DL_CTL,4,2              ; @CXADEC_DL_CTL
	.comm	_CXADEC_HOST_REG1,4,2           ; @CXADEC_HOST_REG1
	.comm	_CXADEC_DLL1_DIAG_CTRL,4,2      ; @CXADEC_DLL1_DIAG_CTRL
	.comm	_CXADEC_DLL2_DIAG_CTRL,4,2      ; @CXADEC_DLL2_DIAG_CTRL
	.comm	_CXADEC_AFE_DIAG_CTRL1,4,2      ; @CXADEC_AFE_DIAG_CTRL1
	.comm	_CXADEC_AFE_DIAG_CTRL3,4,2      ; @CXADEC_AFE_DIAG_CTRL3
	.comm	_CXADEC_PIN_CTRL1,4,2           ; @CXADEC_PIN_CTRL1
	.comm	_CXADEC_PIN_CTRL2,4,2           ; @CXADEC_PIN_CTRL2
	.comm	_CXADEC_SOFT_RST_CTRL,4,2       ; @CXADEC_SOFT_RST_CTRL
	.comm	_CXADEC_CHIP_CTRL,4,2           ; @CXADEC_CHIP_CTRL
	.comm	_CXADEC_MODE_CTRL,4,2           ; @CXADEC_MODE_CTRL
	.comm	_CXADEC_CRUSH_CTRL,4,2          ; @CXADEC_CRUSH_CTRL
	.comm	_CXADEC_DFE_CTRL2,4,2           ; @CXADEC_DFE_CTRL2
	.comm	_CXADEC_OUT_CTRL1,4,2           ; @CXADEC_OUT_CTRL1
	.comm	_CXADEC_AFE_CTRL,4,2            ; @CXADEC_AFE_CTRL
	.comm	_CXADEC_SRC_COMB_CFG,4,2        ; @CXADEC_SRC_COMB_CFG
	.no_dead_strip	_cx18_av_initialize
.subsections_via_symbols
