	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rk3066_hdmi_i2c_write
_rk3066_hdmi_i2c_write:                 ## @rk3066_hdmi_i2c_write
	.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
	cmpl	$1, (%rsi)
	jne	LBB0_3
## %bb.1:
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	8(%rsi), %rax
	movq	_DDC_ADDR@GOTPCREL(%rip), %r15
	movq	_DDC_SEGMENT_ADDR@GOTPCREL(%rip), %r12
	cmpq	(%r15), %rax
	je	LBB0_4
## %bb.2:
	cmpq	(%r12), %rax
	je	LBB0_4
LBB0_3:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_10
LBB0_4:
	movq	(%r14), %rdi
	addq	$8, %rdi
	callq	_reinit_completion
	movq	8(%rbx), %rax
	cmpq	(%r12), %rax
	jne	LBB0_6
## %bb.5:
	movq	16(%rbx), %rcx
	movl	(%rcx), %ecx
	movq	(%r14), %rdx
	movl	%ecx, (%rdx)
LBB0_6:
	cmpq	(%r15), %rax
	jne	LBB0_7
## %bb.8:
	movq	16(%rbx), %rax
	movl	(%rax), %edx
	movq	(%r14), %rax
	movl	%edx, 4(%rax)
	jmp	LBB0_9
LBB0_7:
	movq	(%r14), %rax
	movl	4(%rax), %edx
LBB0_9:
	movq	_HDMI_EDID_WORD_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_hdmi_writeb
	movq	_HDMI_EDID_SEGMENT_POINTER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%r14), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_hdmi_writeb
	xorl	%eax, %eax
LBB0_10:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DDC_ADDR,8,3                   ## @DDC_ADDR
	.comm	_DDC_SEGMENT_ADDR,8,3           ## @DDC_SEGMENT_ADDR
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_HDMI_EDID_WORD_ADDR,4,2        ## @HDMI_EDID_WORD_ADDR
	.comm	_HDMI_EDID_SEGMENT_POINTER,4,2  ## @HDMI_EDID_SEGMENT_POINTER
	.no_dead_strip	_rk3066_hdmi_i2c_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rk3066_hdmi_i2c_write
_rk3066_hdmi_i2c_write:                 ; @rk3066_hdmi_i2c_write
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	w8, [x1]
	cmp	w8, #1
	b.ne	LBB0_6
; %bb.1:
	mov	x20, x1
	ldr	x8, [x1, #8]
Lloh0:
	adrp	x21, _DDC_ADDR@GOTPAGE
Lloh1:
	ldr	x21, [x21, _DDC_ADDR@GOTPAGEOFF]
	ldr	x9, [x21]
Lloh2:
	adrp	x22, _DDC_SEGMENT_ADDR@GOTPAGE
Lloh3:
	ldr	x22, [x22, _DDC_SEGMENT_ADDR@GOTPAGEOFF]
	ldr	x10, [x22]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_6
; %bb.2:
	mov	x19, x0
	ldr	x8, [x0]
	add	x0, x8, #8
	bl	_reinit_completion
	ldr	x8, [x20, #8]
	ldr	x9, [x22]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.3:
	ldr	x9, [x20, #16]
	ldr	w9, [x9]
	ldr	x10, [x19]
	str	w9, [x10]
LBB0_4:
	ldr	x9, [x21]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.5:
	ldr	x8, [x20, #16]
	ldr	w2, [x8]
	ldr	x8, [x19]
	str	w2, [x8, #4]
	b	LBB0_8
LBB0_6:
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_9
LBB0_7:
	ldr	x8, [x19]
	ldr	w2, [x8, #4]
LBB0_8:
Lloh7:
	adrp	x8, _HDMI_EDID_WORD_ADDR@GOTPAGE
Lloh8:
	ldr	x8, [x8, _HDMI_EDID_WORD_ADDR@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hdmi_writeb
Lloh10:
	adrp	x8, _HDMI_EDID_SEGMENT_POINTER@GOTPAGE
Lloh11:
	ldr	x8, [x8, _HDMI_EDID_SEGMENT_POINTER@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	ldr	x8, [x19]
	ldr	w2, [x8]
	mov	x0, x19
	bl	_hdmi_writeb
	mov	w0, #0
LBB0_9:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_DDC_ADDR,8,3                   ; @DDC_ADDR
	.comm	_DDC_SEGMENT_ADDR,8,3           ; @DDC_SEGMENT_ADDR
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_HDMI_EDID_WORD_ADDR,4,2        ; @HDMI_EDID_WORD_ADDR
	.comm	_HDMI_EDID_SEGMENT_POINTER,4,2  ; @HDMI_EDID_SEGMENT_POINTER
	.no_dead_strip	_rk3066_hdmi_i2c_write
.subsections_via_symbols
