	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function max77843_muic_chg_handler
_max77843_muic_chg_handler:             ## @max77843_muic_chg_handler
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	_MAX77843_CABLE_GROUP_CHG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-36(%rbp), %rdx
	callq	_max77843_muic_get_cable_type
	movl	%eax, %ebx
	cmpl	$0, -36(%rbp)
	leaq	L_.str.2(%rip), %r12
	leaq	L_.str.1(%rip), %r14
	movq	%r14, %rdx
	cmoveq	%r12, %rdx
	movl	(%r15), %edi
	movl	8(%r15), %r8d
	leaq	L_.str(%rip), %rsi
	movl	%eax, %ecx
	callq	_dev_dbg
	leal	-128(%rbx), %eax
	cmpl	$7, %eax
	ja	LBB0_6
## %bb.1:
	xorl	%r14d, %r14d
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_2:
	movq	_MAX77843_MUIC_CONTROL1_SW_USB@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_max77843_muic_set_path
	testl	%eax, %eax
	js	LBB0_20
## %bb.3:
	movl	4(%r15), %edi
	movq	_EXTCON_USB@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	callq	_extcon_set_state_sync
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_SDP@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_4:
	movq	_MAX77843_CABLE_GROUP_ADC_GND@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-36(%rbp), %rdx
	movq	%r15, %rdi
	callq	_max77843_muic_get_cable_type
	movq	_MAX77843_MUIC_GND_MHL_VB@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_18
## %bb.5:
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_DCP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	jmp	LBB0_16
LBB0_6:
	movl	(%r15), %edi
	cmpl	$0, -36(%rbp)
	cmoveq	%r12, %r14
	leaq	L_.str.3(%rip), %rsi
	movq	%r14, %rdx
	movl	%ebx, %ecx
	callq	_dev_err
	movq	_MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_max77843_muic_set_path
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	jmp	LBB0_17
LBB0_7:
	movq	_MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_max77843_muic_set_path
	testl	%eax, %eax
	js	LBB0_20
## %bb.8:
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_SLOW@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_9:
	movq	_MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_max77843_muic_set_path
	testl	%eax, %eax
	js	LBB0_20
## %bb.10:
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_FAST@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_11:
	movq	_MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_max77843_muic_set_path
	testl	%eax, %eax
	js	LBB0_20
## %bb.12:
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_CDP@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_13:
	movq	_MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_max77843_muic_set_path
	testl	%eax, %eax
	js	LBB0_20
LBB0_14:
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_DCP@GOTPCREL(%rip), %rax
LBB0_15:
	movl	(%rax), %esi
	movl	-36(%rbp), %edx
LBB0_16:
	callq	_extcon_set_state_sync
	jmp	LBB0_17
LBB0_20:
	movl	%eax, %r14d
LBB0_17:
	movl	%r14d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movq	_MAX77843_MUIC_GND_MHL@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_17
## %bb.19:
	movl	4(%r15), %edi
	movq	_EXTCON_CHG_USB_DCP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r14d, %r14d
	xorl	%edx, %edx
	jmp	LBB0_16
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_17, LBB0_17-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_14, LBB0_14-LJTI0_0
.set L0_0_set_13, LBB0_13-LJTI0_0
LJTI0_0:
	.long	L0_0_set_2
	.long	L0_0_set_7
	.long	L0_0_set_9
	.long	L0_0_set_17
	.long	L0_0_set_4
	.long	L0_0_set_11
	.long	L0_0_set_14
	.long	L0_0_set_13
	.end_data_region
                                        ## -- End function
	.comm	_MAX77843_CABLE_GROUP_CHG,4,2   ## @MAX77843_CABLE_GROUP_CHG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"external connector is %s(chg_type:0x%x, prev_chg_type:0x%x)\n"

L_.str.1:                               ## @.str.1
	.asciz	"attached"

L_.str.2:                               ## @.str.2
	.asciz	"detached"

	.comm	_MAX77843_MUIC_CONTROL1_SW_USB,4,2 ## @MAX77843_MUIC_CONTROL1_SW_USB
	.comm	_EXTCON_USB,4,2                 ## @EXTCON_USB
	.comm	_EXTCON_CHG_USB_SDP,4,2         ## @EXTCON_CHG_USB_SDP
	.comm	_MAX77843_MUIC_CONTROL1_SW_OPEN,4,2 ## @MAX77843_MUIC_CONTROL1_SW_OPEN
	.comm	_EXTCON_CHG_USB_CDP,4,2         ## @EXTCON_CHG_USB_CDP
	.comm	_EXTCON_CHG_USB_DCP,4,2         ## @EXTCON_CHG_USB_DCP
	.comm	_EXTCON_CHG_USB_SLOW,4,2        ## @EXTCON_CHG_USB_SLOW
	.comm	_EXTCON_CHG_USB_FAST,4,2        ## @EXTCON_CHG_USB_FAST
	.comm	_MAX77843_CABLE_GROUP_ADC_GND,4,2 ## @MAX77843_CABLE_GROUP_ADC_GND
	.comm	_MAX77843_MUIC_GND_MHL_VB,4,2   ## @MAX77843_MUIC_GND_MHL_VB
	.comm	_MAX77843_MUIC_GND_MHL,4,2      ## @MAX77843_MUIC_GND_MHL
L_.str.3:                               ## @.str.3
	.asciz	"failed to detect %s accessory (chg_type:0x%x)\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_max77843_muic_chg_handler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function max77843_muic_chg_handler
_max77843_muic_chg_handler:             ; @max77843_muic_chg_handler
	.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
Lloh0:
	adrp	x8, _MAX77843_CABLE_GROUP_CHG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAX77843_CABLE_GROUP_CHG@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #12
	bl	_max77843_muic_get_cable_type
	mov	x20, x0
	ldr	w0, [x19]
Lloh3:
	adrp	x21, l_.str.1@PAGE
Lloh4:
	add	x21, x21, l_.str.1@PAGEOFF
	ldr	w8, [sp, #12]
Lloh5:
	adrp	x22, l_.str.2@PAGE
Lloh6:
	add	x22, x22, l_.str.2@PAGEOFF
	cmp	w8, #0
	csel	x2, x22, x21, eq
	ldr	w4, [x19, #8]
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	mov	x3, x20
	bl	_dev_dbg
	sub	w8, w20, #128
	cmp	w8, #7
	b.hi	LBB0_6
; %bb.1:
	mov	w0, #0
Lloh9:
	adrp	x9, lJTI0_0@PAGE
Lloh10:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
Lloh11:
	adrp	x8, _MAX77843_MUIC_CONTROL1_SW_USB@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MAX77843_MUIC_CONTROL1_SW_USB@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w3, #0
	bl	_max77843_muic_set_path
	tbnz	w0, #31, LBB0_18
; %bb.3:
	ldr	w0, [x19, #4]
Lloh14:
	adrp	x8, _EXTCON_USB@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EXTCON_USB@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	bl	_extcon_set_state_sync
	ldr	w0, [x19, #4]
Lloh17:
	adrp	x8, _EXTCON_CHG_USB_SDP@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EXTCON_CHG_USB_SDP@GOTPAGEOFF]
	b	LBB0_15
LBB0_4:
Lloh19:
	adrp	x8, _MAX77843_CABLE_GROUP_ADC_GND@GOTPAGE
Lloh20:
	ldr	x8, [x8, _MAX77843_CABLE_GROUP_ADC_GND@GOTPAGEOFF]
Lloh21:
	ldr	w1, [x8]
	add	x2, sp, #12
	mov	x0, x19
	bl	_max77843_muic_get_cable_type
Lloh22:
	adrp	x8, _MAX77843_MUIC_GND_MHL_VB@GOTPAGE
Lloh23:
	ldr	x8, [x8, _MAX77843_MUIC_GND_MHL_VB@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_19
; %bb.5:
	ldr	w0, [x19, #4]
Lloh25:
	adrp	x8, _EXTCON_CHG_USB_DCP@GOTPAGE
Lloh26:
	ldr	x8, [x8, _EXTCON_CHG_USB_DCP@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	mov	w2, #1
	b	LBB0_16
LBB0_6:
	ldr	w0, [x19]
	ldr	w8, [sp, #12]
	cmp	w8, #0
	csel	x2, x22, x21, eq
Lloh28:
	adrp	x1, l_.str.3@PAGE
Lloh29:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x3, x20
	bl	_dev_err
Lloh30:
	adrp	x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGE
Lloh31:
	ldr	x8, [x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w3, #0
	bl	_max77843_muic_set_path
Lloh33:
	adrp	x8, _EINVAL@GOTPAGE
Lloh34:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_18
LBB0_7:
Lloh36:
	adrp	x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGE
Lloh37:
	ldr	x8, [x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGEOFF]
Lloh38:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w3, #0
	bl	_max77843_muic_set_path
	tbnz	w0, #31, LBB0_18
; %bb.8:
	ldr	w0, [x19, #4]
Lloh39:
	adrp	x8, _EXTCON_CHG_USB_SLOW@GOTPAGE
Lloh40:
	ldr	x8, [x8, _EXTCON_CHG_USB_SLOW@GOTPAGEOFF]
	b	LBB0_15
LBB0_9:
Lloh41:
	adrp	x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGE
Lloh42:
	ldr	x8, [x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGEOFF]
Lloh43:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w3, #0
	bl	_max77843_muic_set_path
	tbnz	w0, #31, LBB0_18
; %bb.10:
	ldr	w0, [x19, #4]
Lloh44:
	adrp	x8, _EXTCON_CHG_USB_FAST@GOTPAGE
Lloh45:
	ldr	x8, [x8, _EXTCON_CHG_USB_FAST@GOTPAGEOFF]
	b	LBB0_15
LBB0_11:
Lloh46:
	adrp	x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGE
Lloh47:
	ldr	x8, [x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGEOFF]
Lloh48:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w3, #0
	bl	_max77843_muic_set_path
	tbnz	w0, #31, LBB0_18
; %bb.12:
	ldr	w0, [x19, #4]
Lloh49:
	adrp	x8, _EXTCON_CHG_USB_CDP@GOTPAGE
Lloh50:
	ldr	x8, [x8, _EXTCON_CHG_USB_CDP@GOTPAGEOFF]
	b	LBB0_15
LBB0_13:
Lloh51:
	adrp	x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGE
Lloh52:
	ldr	x8, [x8, _MAX77843_MUIC_CONTROL1_SW_OPEN@GOTPAGEOFF]
Lloh53:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w3, #0
	bl	_max77843_muic_set_path
	tbnz	w0, #31, LBB0_18
LBB0_14:
	ldr	w0, [x19, #4]
Lloh54:
	adrp	x8, _EXTCON_CHG_USB_DCP@GOTPAGE
Lloh55:
	ldr	x8, [x8, _EXTCON_CHG_USB_DCP@GOTPAGEOFF]
LBB0_15:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
LBB0_16:
	bl	_extcon_set_state_sync
LBB0_17:
	mov	w0, #0
LBB0_18:
	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_19:
Lloh56:
	adrp	x8, _MAX77843_MUIC_GND_MHL@GOTPAGE
Lloh57:
	ldr	x8, [x8, _MAX77843_MUIC_GND_MHL@GOTPAGEOFF]
Lloh58:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_17
; %bb.20:
	ldr	w0, [x19, #4]
Lloh59:
	adrp	x8, _EXTCON_CHG_USB_DCP@GOTPAGE
Lloh60:
	ldr	x8, [x8, _EXTCON_CHG_USB_DCP@GOTPAGEOFF]
Lloh61:
	ldr	w1, [x8]
	mov	w2, #0
	b	LBB0_16
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGot	Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGot	Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
	.byte	(LBB0_9-LBB0_2)>>2
	.byte	(LBB0_18-LBB0_2)>>2
	.byte	(LBB0_4-LBB0_2)>>2
	.byte	(LBB0_11-LBB0_2)>>2
	.byte	(LBB0_14-LBB0_2)>>2
	.byte	(LBB0_13-LBB0_2)>>2
                                        ; -- End function
	.comm	_MAX77843_CABLE_GROUP_CHG,4,2   ; @MAX77843_CABLE_GROUP_CHG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"external connector is %s(chg_type:0x%x, prev_chg_type:0x%x)\n"

l_.str.1:                               ; @.str.1
	.asciz	"attached"

l_.str.2:                               ; @.str.2
	.asciz	"detached"

	.comm	_MAX77843_MUIC_CONTROL1_SW_USB,4,2 ; @MAX77843_MUIC_CONTROL1_SW_USB
	.comm	_EXTCON_USB,4,2                 ; @EXTCON_USB
	.comm	_EXTCON_CHG_USB_SDP,4,2         ; @EXTCON_CHG_USB_SDP
	.comm	_MAX77843_MUIC_CONTROL1_SW_OPEN,4,2 ; @MAX77843_MUIC_CONTROL1_SW_OPEN
	.comm	_EXTCON_CHG_USB_CDP,4,2         ; @EXTCON_CHG_USB_CDP
	.comm	_EXTCON_CHG_USB_DCP,4,2         ; @EXTCON_CHG_USB_DCP
	.comm	_EXTCON_CHG_USB_SLOW,4,2        ; @EXTCON_CHG_USB_SLOW
	.comm	_EXTCON_CHG_USB_FAST,4,2        ; @EXTCON_CHG_USB_FAST
	.comm	_MAX77843_CABLE_GROUP_ADC_GND,4,2 ; @MAX77843_CABLE_GROUP_ADC_GND
	.comm	_MAX77843_MUIC_GND_MHL_VB,4,2   ; @MAX77843_MUIC_GND_MHL_VB
	.comm	_MAX77843_MUIC_GND_MHL,4,2      ; @MAX77843_MUIC_GND_MHL
l_.str.3:                               ; @.str.3
	.asciz	"failed to detect %s accessory (chg_type:0x%x)\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_max77843_muic_chg_handler
.subsections_via_symbols
