	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sii9234_rsen_change
_sii9234_rsen_change:                   ## @sii9234_rsen_change
	.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
	movq	(%rdi), %rax
	movq	_ST_RGND_1K@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.2:
	movq	_MHL_TX_SYSSTAT_REG@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_mhl_tx_readb
	movq	_ST_FAILURE@GOTPCREL(%rip), %r15
	testl	%eax, %eax
	js	LBB0_10
## %bb.3:
	movq	_RSEN_STATUS@GOTPCREL(%rip), %r12
	movl	8(%rbx), %edi
	testl	%eax, (%r12)
	je	LBB0_6
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
LBB0_5:
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_ST_RSEN_HIGH@GOTPCREL(%rip), %r15
	jmp	LBB0_10
LBB0_1:
	movl	8(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	_ST_FAILURE@GOTPCREL(%rip), %r15
LBB0_10:
	movl	(%r15), %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_T_SRC_RXSENSE_DEGLITCH@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_msleep
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_mhl_tx_readb
	testl	%eax, %eax
	js	LBB0_10
## %bb.7:
	movl	%eax, %r14d
	movl	8(%rbx), %edi
	leaq	L_.str.3(%rip), %rsi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	8(%rbx), %edi
	testl	%r14d, (%r12)
	je	LBB0_9
## %bb.8:
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_5
LBB0_9:
	leaq	L_.str.5(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_sii9234_tmds_control
	movq	%rbx, %rdi
	callq	_force_usb_id_switch_open
	movq	%rbx, %rdi
	callq	_release_usb_id_switch_open
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_ST_RGND_1K,8,3                 ## @ST_RGND_1K
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"RSEN_HIGH without RGND_1K\n"

	.comm	_ST_FAILURE,4,2                 ## @ST_FAILURE
	.comm	_MHL_TX_SYSSTAT_REG,4,2         ## @MHL_TX_SYSSTAT_REG
	.comm	_RSEN_STATUS,4,2                ## @RSEN_STATUS
L_.str.1:                               ## @.str.1
	.asciz	"MHL cable connected.. RSEN High\n"

	.comm	_ST_RSEN_HIGH,4,2               ## @ST_RSEN_HIGH
L_.str.2:                               ## @.str.2
	.asciz	"RSEN lost\n"

	.comm	_T_SRC_RXSENSE_DEGLITCH,4,2     ## @T_SRC_RXSENSE_DEGLITCH
L_.str.3:                               ## @.str.3
	.asciz	"sys_stat: %x\n"

L_.str.4:                               ## @.str.4
	.asciz	"RSEN recovery\n"

L_.str.5:                               ## @.str.5
	.asciz	"RSEN Really LOW\n"

	.no_dead_strip	_sii9234_rsen_change
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sii9234_rsen_change
_sii9234_rsen_change:                   ; @sii9234_rsen_change
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _ST_RGND_1K@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ST_RGND_1K@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.1:
Lloh3:
	adrp	x20, _MHL_TX_SYSSTAT_REG@GOTPAGE
Lloh4:
	ldr	x20, [x20, _MHL_TX_SYSSTAT_REG@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_mhl_tx_readb
	tbnz	w0, #31, LBB0_6
; %bb.2:
	mov	x8, x0
Lloh5:
	adrp	x21, _RSEN_STATUS@GOTPAGE
Lloh6:
	ldr	x21, [x21, _RSEN_STATUS@GOTPAGEOFF]
	ldr	w9, [x21]
	ldr	w0, [x19, #8]
	tst	w9, w8
	b.eq	LBB0_8
; %bb.3:
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_4:
	bl	_dev_dbg
Lloh9:
	adrp	x8, _ST_RSEN_HIGH@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ST_RSEN_HIGH@GOTPAGEOFF]
	b	LBB0_7
LBB0_5:
	ldr	w0, [x19, #8]
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
LBB0_6:
Lloh13:
	adrp	x8, _ST_FAILURE@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ST_FAILURE@GOTPAGEOFF]
LBB0_7:
	ldr	w0, [x8]
	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
	add	sp, sp, #64
	ret
LBB0_8:
Lloh15:
	adrp	x1, l_.str.2@PAGE
Lloh16:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_dbg
Lloh17:
	adrp	x8, _T_SRC_RXSENSE_DEGLITCH@GOTPAGE
Lloh18:
	ldr	x8, [x8, _T_SRC_RXSENSE_DEGLITCH@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	bl	_msleep
	ldr	w1, [x20]
	mov	x0, x19
	bl	_mhl_tx_readb
	tbnz	w0, #31, LBB0_6
; %bb.9:
	mov	x20, x0
	ldr	w0, [x19, #8]
	str	x20, [sp]
Lloh20:
	adrp	x1, l_.str.3@PAGE
Lloh21:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_dbg
	ldr	w8, [x21]
	ldr	w0, [x19, #8]
	tst	w8, w20
	b.eq	LBB0_11
; %bb.10:
Lloh22:
	adrp	x1, l_.str.4@PAGE
Lloh23:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_4
LBB0_11:
Lloh24:
	adrp	x1, l_.str.5@PAGE
Lloh25:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_dev_dbg
	mov	x0, x19
	mov	w1, #0
	bl	_sii9234_tmds_control
	mov	x0, x19
	bl	_force_usb_id_switch_open
	mov	x0, x19
	bl	_release_usb_id_switch_open
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_ST_RGND_1K,8,3                 ; @ST_RGND_1K
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"RSEN_HIGH without RGND_1K\n"

	.comm	_ST_FAILURE,4,2                 ; @ST_FAILURE
	.comm	_MHL_TX_SYSSTAT_REG,4,2         ; @MHL_TX_SYSSTAT_REG
	.comm	_RSEN_STATUS,4,2                ; @RSEN_STATUS
l_.str.1:                               ; @.str.1
	.asciz	"MHL cable connected.. RSEN High\n"

	.comm	_ST_RSEN_HIGH,4,2               ; @ST_RSEN_HIGH
l_.str.2:                               ; @.str.2
	.asciz	"RSEN lost\n"

	.comm	_T_SRC_RXSENSE_DEGLITCH,4,2     ; @T_SRC_RXSENSE_DEGLITCH
l_.str.3:                               ; @.str.3
	.asciz	"sys_stat: %x\n"

l_.str.4:                               ; @.str.4
	.asciz	"RSEN recovery\n"

l_.str.5:                               ; @.str.5
	.asciz	"RSEN Really LOW\n"

	.no_dead_strip	_sii9234_rsen_change
.subsections_via_symbols
