	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function a10hdmi_ddc_xfer
_a10hdmi_ddc_xfer:                      ## @a10hdmi_ddc_xfer
	.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	%r8d, -44(%rbp)                 ## 4-byte Spill
	movl	%ecx, %r15d
	movl	%edx, %r12d
	movl	%esi, %r13d
	movq	%rdi, %r14
	movq	_DDC_CTRL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	callq	_HDMI_READ
	movq	_CTRL_DDC_FIFO_DIR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	notl	%edx
	andl	%eax, %edx
	movq	_CTRL_DDC_FIFO_DIR_READ@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	(%rbx), %esi
	movq	%r14, %rdi
	callq	_HDMI_WRITE
	movq	_SLAVE_ADDR_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %r13d
	movq	_SLAVE_ADDR_SEG_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %r12d
	orl	%r13d, %r12d
	movq	%rbx, %r13
	movq	_EDDC_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_SLAVE_ADDR_EDDC_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %eax
	movq	_SLAVE_ADDR_OFFSET_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %r15d
	orl	%eax, %r15d
	orl	%r12d, %r15d
	movq	_DDC_SLAVE_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%r15d, %edx
	callq	_HDMI_WRITE
	movq	_DDC_FIFO_CTRL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r14, %rdi
	callq	_HDMI_READ
	movq	_FIFO_CTRL_CLEAR@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%rbx), %esi
	movq	%r14, %rdi
	movl	%eax, %edx
	callq	_HDMI_WRITE
	movq	_DDC_BYTE_COUNTER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	callq	_HDMI_WRITE
	movq	_DDC_COMMAND@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_COMMAND_EOREAD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_HDMI_WRITE
	movl	(%r13), %esi
	movq	%r14, %rdi
	callq	_HDMI_READ
	movq	_CTRL_DDC_ACMD_START@GOTPCREL(%rip), %r15
	orl	(%r15), %eax
	movl	(%r13), %esi
	movq	%r14, %rdi
	movl	%eax, %edx
	callq	_HDMI_WRITE
	movq	_DDC_RETRY@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	cmpl	$2, %ebx
	jl	LBB0_4
## %bb.1:
	movq	_DDC_DELAY@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %esi
	movq	%r14, %rdi
	callq	_HDMI_READ
	testl	%eax, (%r15)
	je	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r12), %edi
	callq	_DELAY
	decl	%ebx
	cmpl	$1, %ebx
	jg	LBB0_2
	jmp	LBB0_5
LBB0_4:
	decl	%ebx
	je	LBB0_5
LBB0_6:
	movq	_DDC_INT_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_HDMI_READ
	movl	%eax, %ecx
	movq	_INT_STATUS_XFER_DONE@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	testl	%ecx, (%rdx)
	jne	LBB0_9
## %bb.7:
	movq	_EIO@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_5:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DDC_CTRL,4,2                   ## @DDC_CTRL
	.comm	_CTRL_DDC_FIFO_DIR,4,2          ## @CTRL_DDC_FIFO_DIR
	.comm	_CTRL_DDC_FIFO_DIR_READ,4,2     ## @CTRL_DDC_FIFO_DIR_READ
	.comm	_SLAVE_ADDR_SHIFT,4,2           ## @SLAVE_ADDR_SHIFT
	.comm	_SLAVE_ADDR_SEG_SHIFT,4,2       ## @SLAVE_ADDR_SEG_SHIFT
	.comm	_EDDC_ADDR,4,2                  ## @EDDC_ADDR
	.comm	_SLAVE_ADDR_EDDC_SHIFT,4,2      ## @SLAVE_ADDR_EDDC_SHIFT
	.comm	_SLAVE_ADDR_OFFSET_SHIFT,4,2    ## @SLAVE_ADDR_OFFSET_SHIFT
	.comm	_DDC_SLAVE_ADDR,4,2             ## @DDC_SLAVE_ADDR
	.comm	_DDC_FIFO_CTRL,4,2              ## @DDC_FIFO_CTRL
	.comm	_FIFO_CTRL_CLEAR,4,2            ## @FIFO_CTRL_CLEAR
	.comm	_DDC_BYTE_COUNTER,4,2           ## @DDC_BYTE_COUNTER
	.comm	_DDC_COMMAND,4,2                ## @DDC_COMMAND
	.comm	_COMMAND_EOREAD,4,2             ## @COMMAND_EOREAD
	.comm	_CTRL_DDC_ACMD_START,4,2        ## @CTRL_DDC_ACMD_START
	.comm	_DDC_RETRY,4,2                  ## @DDC_RETRY
	.comm	_DDC_DELAY,4,2                  ## @DDC_DELAY
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_DDC_INT_STATUS,4,2             ## @DDC_INT_STATUS
	.comm	_INT_STATUS_XFER_DONE,4,2       ## @INT_STATUS_XFER_DONE
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_a10hdmi_ddc_xfer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function a10hdmi_ddc_xfer
_a10hdmi_ddc_xfer:                      ; @a10hdmi_ddc_xfer
	.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, x4
	mov	x21, x3
	mov	x22, x2
	mov	x23, x1
	mov	x19, x0
Lloh0:
	adrp	x24, _DDC_CTRL@GOTPAGE
Lloh1:
	ldr	x24, [x24, _DDC_CTRL@GOTPAGEOFF]
	ldr	w1, [x24]
	bl	_HDMI_READ
Lloh2:
	adrp	x8, _CTRL_DDC_FIFO_DIR@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CTRL_DDC_FIFO_DIR@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	bic	w8, w0, w8
Lloh5:
	adrp	x9, _CTRL_DDC_FIFO_DIR_READ@GOTPAGE
Lloh6:
	ldr	x9, [x9, _CTRL_DDC_FIFO_DIR_READ@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w2, w8, w9
	ldr	w1, [x24]
	mov	x0, x19
	bl	_HDMI_WRITE
Lloh8:
	adrp	x8, _SLAVE_ADDR_SHIFT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SLAVE_ADDR_SHIFT@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	lsl	w8, w23, w8
Lloh11:
	adrp	x9, _SLAVE_ADDR_SEG_SHIFT@GOTPAGE
Lloh12:
	ldr	x9, [x9, _SLAVE_ADDR_SEG_SHIFT@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	lsl	w9, w22, w9
	orr	w8, w9, w8
Lloh14:
	adrp	x9, _EDDC_ADDR@GOTPAGE
Lloh15:
	ldr	x9, [x9, _EDDC_ADDR@GOTPAGEOFF]
Lloh16:
	adrp	x10, _SLAVE_ADDR_EDDC_SHIFT@GOTPAGE
Lloh17:
	ldr	x10, [x10, _SLAVE_ADDR_EDDC_SHIFT@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
Lloh19:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w8, w8, w9
Lloh20:
	adrp	x9, _SLAVE_ADDR_OFFSET_SHIFT@GOTPAGE
Lloh21:
	ldr	x9, [x9, _SLAVE_ADDR_OFFSET_SHIFT@GOTPAGEOFF]
Lloh22:
	ldr	w9, [x9]
	lsl	w9, w21, w9
	orr	w2, w8, w9
Lloh23:
	adrp	x8, _DDC_SLAVE_ADDR@GOTPAGE
Lloh24:
	ldr	x8, [x8, _DDC_SLAVE_ADDR@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_HDMI_WRITE
Lloh26:
	adrp	x21, _DDC_FIFO_CTRL@GOTPAGE
Lloh27:
	ldr	x21, [x21, _DDC_FIFO_CTRL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_HDMI_READ
Lloh28:
	adrp	x8, _FIFO_CTRL_CLEAR@GOTPAGE
Lloh29:
	ldr	x8, [x8, _FIFO_CTRL_CLEAR@GOTPAGEOFF]
Lloh30:
	ldr	w8, [x8]
	orr	w2, w8, w0
	ldr	w1, [x21]
	mov	x0, x19
	bl	_HDMI_WRITE
Lloh31:
	adrp	x8, _DDC_BYTE_COUNTER@GOTPAGE
Lloh32:
	ldr	x8, [x8, _DDC_BYTE_COUNTER@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_HDMI_WRITE
Lloh34:
	adrp	x8, _DDC_COMMAND@GOTPAGE
Lloh35:
	ldr	x8, [x8, _DDC_COMMAND@GOTPAGEOFF]
Lloh36:
	ldr	w1, [x8]
Lloh37:
	adrp	x8, _COMMAND_EOREAD@GOTPAGE
Lloh38:
	ldr	x8, [x8, _COMMAND_EOREAD@GOTPAGEOFF]
Lloh39:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_HDMI_WRITE
	ldr	w1, [x24]
	mov	x0, x19
	bl	_HDMI_READ
Lloh40:
	adrp	x20, _CTRL_DDC_ACMD_START@GOTPAGE
Lloh41:
	ldr	x20, [x20, _CTRL_DDC_ACMD_START@GOTPAGEOFF]
	ldr	w8, [x20]
	orr	w2, w8, w0
	ldr	w1, [x24]
	mov	x0, x19
	bl	_HDMI_WRITE
Lloh42:
	adrp	x8, _DDC_RETRY@GOTPAGE
Lloh43:
	ldr	x8, [x8, _DDC_RETRY@GOTPAGEOFF]
Lloh44:
	ldr	w21, [x8]
	cmp	w21, #2
	b.lt	LBB0_4
; %bb.1:
Lloh45:
	adrp	x22, _DDC_DELAY@GOTPAGE
Lloh46:
	ldr	x22, [x22, _DDC_DELAY@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x24]
	mov	x0, x19
	bl	_HDMI_READ
	ldr	w8, [x20]
	tst	w8, w0
	b.eq	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w0, [x22]
	bl	_DELAY
	sub	w21, w21, #1
	cmp	w21, #1
	b.gt	LBB0_2
	b	LBB0_6
LBB0_4:
	sub	w8, w21, #1
	cbz	w8, LBB0_6
LBB0_5:
Lloh47:
	adrp	x8, _DDC_INT_STATUS@GOTPAGE
Lloh48:
	ldr	x8, [x8, _DDC_INT_STATUS@GOTPAGEOFF]
Lloh49:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_HDMI_READ
Lloh50:
	adrp	x8, _INT_STATUS_XFER_DONE@GOTPAGE
Lloh51:
	ldr	x8, [x8, _INT_STATUS_XFER_DONE@GOTPAGEOFF]
Lloh52:
	ldr	w8, [x8]
Lloh53:
	adrp	x9, _EIO@GOTPAGE
Lloh54:
	ldr	x9, [x9, _EIO@GOTPAGEOFF]
Lloh55:
	ldr	w9, [x9]
	tst	w8, w0
	csel	w0, w9, wzr, eq
	b	LBB0_7
LBB0_6:
Lloh56:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh57:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh58:
	ldr	w0, [x8]
LBB0_7:
	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	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh18
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.cfi_endproc
                                        ; -- End function
	.comm	_DDC_CTRL,4,2                   ; @DDC_CTRL
	.comm	_CTRL_DDC_FIFO_DIR,4,2          ; @CTRL_DDC_FIFO_DIR
	.comm	_CTRL_DDC_FIFO_DIR_READ,4,2     ; @CTRL_DDC_FIFO_DIR_READ
	.comm	_SLAVE_ADDR_SHIFT,4,2           ; @SLAVE_ADDR_SHIFT
	.comm	_SLAVE_ADDR_SEG_SHIFT,4,2       ; @SLAVE_ADDR_SEG_SHIFT
	.comm	_EDDC_ADDR,4,2                  ; @EDDC_ADDR
	.comm	_SLAVE_ADDR_EDDC_SHIFT,4,2      ; @SLAVE_ADDR_EDDC_SHIFT
	.comm	_SLAVE_ADDR_OFFSET_SHIFT,4,2    ; @SLAVE_ADDR_OFFSET_SHIFT
	.comm	_DDC_SLAVE_ADDR,4,2             ; @DDC_SLAVE_ADDR
	.comm	_DDC_FIFO_CTRL,4,2              ; @DDC_FIFO_CTRL
	.comm	_FIFO_CTRL_CLEAR,4,2            ; @FIFO_CTRL_CLEAR
	.comm	_DDC_BYTE_COUNTER,4,2           ; @DDC_BYTE_COUNTER
	.comm	_DDC_COMMAND,4,2                ; @DDC_COMMAND
	.comm	_COMMAND_EOREAD,4,2             ; @COMMAND_EOREAD
	.comm	_CTRL_DDC_ACMD_START,4,2        ; @CTRL_DDC_ACMD_START
	.comm	_DDC_RETRY,4,2                  ; @DDC_RETRY
	.comm	_DDC_DELAY,4,2                  ; @DDC_DELAY
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_DDC_INT_STATUS,4,2             ; @DDC_INT_STATUS
	.comm	_INT_STATUS_XFER_DONE,4,2       ; @INT_STATUS_XFER_DONE
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_a10hdmi_ddc_xfer
.subsections_via_symbols
