	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sii8620_irq_msc
_sii8620_irq_msc:                       ## @sii8620_irq_msc
	.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
	movq	%rdi, %r14
	movq	_REG_CBUS_INT_0@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	callq	_sii8620_readb
	movl	%eax, %ebx
	movq	_BIT_CBUS_HPD_CHG@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	movl	%eax, %edx
	notl	%edx
	andl	%ebx, %edx
	je	LBB0_2
## %bb.1:
	movl	(%r13), %esi
	movq	%r14, %rdi
	callq	_sii8620_write
	movl	(%r12), %eax
LBB0_2:
	testl	%ebx, %eax
	je	LBB0_7
## %bb.3:
	movq	_REG_CBUS_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_sii8620_readb
	movl	%eax, %r15d
	movl	(%r14), %ecx
	xorl	%eax, %ecx
	movq	_BIT_CBUS_STATUS_CBUS_HPD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %ecx
	je	LBB0_5
## %bb.4:
	movl	(%r13), %esi
	movl	(%r12), %edx
	movq	%r14, %rdi
	callq	_sii8620_write
	jmp	LBB0_6
LBB0_5:
	xorl	%eax, %ebx
	xorl	%eax, %r15d
LBB0_6:
	movl	%r15d, (%r14)
LBB0_7:
	movq	_BIT_CBUS_MSC_MR_WRITE_STAT@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_9
## %bb.8:
	movq	%r14, %rdi
	callq	_sii8620_msc_mr_write_stat
LBB0_9:
	testl	%ebx, (%r12)
	je	LBB0_13
## %bb.10:
	movq	_BIT_CBUS_STATUS_CBUS_HPD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	je	LBB0_12
## %bb.11:
	movl	$1, 4(%r14)
	movq	%r14, %rdi
	callq	_sii8620_identify_sink
	jmp	LBB0_13
LBB0_12:
	movq	%r14, %rdi
	callq	_sii8620_hpd_unplugged
LBB0_13:
	movq	_BIT_CBUS_MSC_MR_SET_INT@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_15
## %bb.14:
	movq	%r14, %rdi
	callq	_sii8620_msc_mr_set_int
LBB0_15:
	movq	_BIT_CBUS_MSC_MT_DONE@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_17
## %bb.16:
	movq	%r14, %rdi
	callq	_sii8620_msc_mt_done
LBB0_17:
	movq	_BIT_CBUS_MSC_MR_MSC_MSG@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_18
## %bb.19:
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_sii8620_msc_mr_msc_msg         ## TAILCALL
LBB0_18:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_REG_CBUS_INT_0,4,2             ## @REG_CBUS_INT_0
	.comm	_BIT_CBUS_HPD_CHG,4,2           ## @BIT_CBUS_HPD_CHG
	.comm	_REG_CBUS_STATUS,4,2            ## @REG_CBUS_STATUS
	.comm	_BIT_CBUS_STATUS_CBUS_HPD,4,2   ## @BIT_CBUS_STATUS_CBUS_HPD
	.comm	_BIT_CBUS_MSC_MR_WRITE_STAT,4,2 ## @BIT_CBUS_MSC_MR_WRITE_STAT
	.comm	_BIT_CBUS_MSC_MR_SET_INT,4,2    ## @BIT_CBUS_MSC_MR_SET_INT
	.comm	_BIT_CBUS_MSC_MT_DONE,4,2       ## @BIT_CBUS_MSC_MT_DONE
	.comm	_BIT_CBUS_MSC_MR_MSC_MSG,4,2    ## @BIT_CBUS_MSC_MR_MSC_MSG
	.no_dead_strip	_sii8620_irq_msc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sii8620_irq_msc
_sii8620_irq_msc:                       ; @sii8620_irq_msc
	.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	x19, x0
Lloh0:
	adrp	x24, _REG_CBUS_INT_0@GOTPAGE
Lloh1:
	ldr	x24, [x24, _REG_CBUS_INT_0@GOTPAGEOFF]
	ldr	w1, [x24]
	bl	_sii8620_readb
	mov	x20, x0
Lloh2:
	adrp	x22, _BIT_CBUS_HPD_CHG@GOTPAGE
Lloh3:
	ldr	x22, [x22, _BIT_CBUS_HPD_CHG@GOTPAGEOFF]
	ldr	w8, [x22]
	bics	w2, w0, w8
	b.eq	LBB0_2
; %bb.1:
	ldr	w1, [x24]
	mov	x0, x19
	bl	_sii8620_write
	ldr	w8, [x22]
LBB0_2:
Lloh4:
	adrp	x23, _BIT_CBUS_STATUS_CBUS_HPD@GOTPAGE
Lloh5:
	ldr	x23, [x23, _BIT_CBUS_STATUS_CBUS_HPD@GOTPAGEOFF]
	tst	w8, w20
	b.eq	LBB0_7
; %bb.3:
Lloh6:
	adrp	x8, _REG_CBUS_STATUS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _REG_CBUS_STATUS@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_sii8620_readb
	mov	x21, x0
	ldr	w8, [x19]
	eor	w9, w8, w0
	ldr	w8, [x23]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.4:
	ldr	w1, [x24]
	ldr	w2, [x22]
	mov	x0, x19
	bl	_sii8620_write
	b	LBB0_6
LBB0_5:
	eor	w20, w8, w20
	eor	w21, w8, w21
LBB0_6:
	str	w21, [x19]
LBB0_7:
Lloh9:
	adrp	x8, _BIT_CBUS_MSC_MR_WRITE_STAT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BIT_CBUS_MSC_MR_WRITE_STAT@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_9
; %bb.8:
	mov	x0, x19
	bl	_sii8620_msc_mr_write_stat
LBB0_9:
	ldr	w8, [x22]
	tst	w8, w20
	b.eq	LBB0_13
; %bb.10:
	ldr	w8, [x19]
	ldr	w9, [x23]
	tst	w9, w8
	b.eq	LBB0_12
; %bb.11:
	mov	w8, #1
	str	w8, [x19, #4]
	mov	x0, x19
	bl	_sii8620_identify_sink
	b	LBB0_13
LBB0_12:
	mov	x0, x19
	bl	_sii8620_hpd_unplugged
LBB0_13:
Lloh12:
	adrp	x8, _BIT_CBUS_MSC_MR_SET_INT@GOTPAGE
Lloh13:
	ldr	x8, [x8, _BIT_CBUS_MSC_MR_SET_INT@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_15
; %bb.14:
	mov	x0, x19
	bl	_sii8620_msc_mr_set_int
LBB0_15:
Lloh15:
	adrp	x8, _BIT_CBUS_MSC_MT_DONE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _BIT_CBUS_MSC_MT_DONE@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_17
; %bb.16:
	mov	x0, x19
	bl	_sii8620_msc_mt_done
LBB0_17:
Lloh18:
	adrp	x8, _BIT_CBUS_MSC_MR_MSC_MSG@GOTPAGE
Lloh19:
	ldr	x8, [x8, _BIT_CBUS_MSC_MR_MSC_MSG@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_19
; %bb.18:
	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	_sii8620_msc_mr_msc_msg
LBB0_19:
	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 AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_REG_CBUS_INT_0,4,2             ; @REG_CBUS_INT_0
	.comm	_BIT_CBUS_HPD_CHG,4,2           ; @BIT_CBUS_HPD_CHG
	.comm	_REG_CBUS_STATUS,4,2            ; @REG_CBUS_STATUS
	.comm	_BIT_CBUS_STATUS_CBUS_HPD,4,2   ; @BIT_CBUS_STATUS_CBUS_HPD
	.comm	_BIT_CBUS_MSC_MR_WRITE_STAT,4,2 ; @BIT_CBUS_MSC_MR_WRITE_STAT
	.comm	_BIT_CBUS_MSC_MR_SET_INT,4,2    ; @BIT_CBUS_MSC_MR_SET_INT
	.comm	_BIT_CBUS_MSC_MT_DONE,4,2       ; @BIT_CBUS_MSC_MT_DONE
	.comm	_BIT_CBUS_MSC_MR_MSC_MSG,4,2    ; @BIT_CBUS_MSC_MR_MSC_MSG
	.no_dead_strip	_sii8620_irq_msc
.subsections_via_symbols
