	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sm5502_muic_set_path
_sm5502_muic_set_path:                  ## @sm5502_muic_set_path
	.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, %r14
	testl	%ecx, %ecx
	movl	$134, %ecx
	cmovnel	%esi, %ecx
	movl	$130, %r15d
	cmovnel	%edx, %r15d
	movl	%ecx, %eax
	andl	$-4, %eax
	cmpl	$132, %eax
	jne	LBB0_3
## %bb.1:
	movl	4(%r14), %edi
	movq	_SM5502_REG_MANUAL_SW1@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	_SM5502_REG_MANUAL_SW1_DP_MASK@GOTPCREL(%rip), %rax
	movq	_SM5502_REG_MANUAL_SW1_DM_MASK@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rax), %edx
	callq	_regmap_update_bits
	testl	%eax, %eax
	js	LBB0_2
## %bb.4:
	movl	%r15d, %eax
	andl	$-4, %eax
	cmpl	$128, %eax
	jne	LBB0_7
## %bb.5:
	movl	4(%r14), %edi
	movl	(%r12), %esi
	movq	_SM5502_REG_MANUAL_SW1_VBUSIN_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r15d, %ecx
	callq	_regmap_update_bits
	xorl	%ebx, %ebx
	testl	%eax, %eax
	jns	LBB0_9
## %bb.6:
	movl	%eax, %r15d
	movl	(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_err
	movl	%r15d, %ebx
	jmp	LBB0_9
LBB0_3:
	movl	(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	movl	%ecx, %edx
	jmp	LBB0_8
LBB0_2:
	movl	%eax, %ebx
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_9
LBB0_7:
	movl	(%r14), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%ebx, %ebx
	movl	%r15d, %edx
LBB0_8:
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_9:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SM5502_REG_MANUAL_SW1,4,2      ## @SM5502_REG_MANUAL_SW1
	.comm	_SM5502_REG_MANUAL_SW1_DP_MASK,4,2 ## @SM5502_REG_MANUAL_SW1_DP_MASK
	.comm	_SM5502_REG_MANUAL_SW1_DM_MASK,4,2 ## @SM5502_REG_MANUAL_SW1_DM_MASK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cannot update DM_CON/DP_CON switch\n"

L_.str.1:                               ## @.str.1
	.asciz	"Unknown DM_CON/DP_CON switch type (%d)\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_SM5502_REG_MANUAL_SW1_VBUSIN_MASK,4,2 ## @SM5502_REG_MANUAL_SW1_VBUSIN_MASK
L_.str.2:                               ## @.str.2
	.asciz	"cannot update VBUSIN switch\n"

L_.str.3:                               ## @.str.3
	.asciz	"Unknown VBUS switch type (%d)\n"

	.no_dead_strip	_sm5502_muic_set_path
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sm5502_muic_set_path
_sm5502_muic_set_path:                  ; @sm5502_muic_set_path
	.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
	mov	w8, #134
	cmp	w3, #0
	csel	w3, w8, w1, eq
	mov	w8, #130
	csel	w20, w8, w2, eq
	and	w8, w3, #0xfffffffc
	cmp	w8, #132
	b.ne	LBB0_5
; %bb.1:
	ldr	w0, [x19, #4]
Lloh0:
	adrp	x22, _SM5502_REG_MANUAL_SW1@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SM5502_REG_MANUAL_SW1@GOTPAGEOFF]
Lloh2:
	adrp	x8, _SM5502_REG_MANUAL_SW1_DP_MASK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _SM5502_REG_MANUAL_SW1_DP_MASK@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _SM5502_REG_MANUAL_SW1_DM_MASK@GOTPAGE
Lloh6:
	ldr	x9, [x9, _SM5502_REG_MANUAL_SW1_DM_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w2, w9, w8
                                        ; kill: def $w3 killed $w3 killed $x3
	bl	_regmap_update_bits
	tbnz	w0, #31, LBB0_6
; %bb.2:
	and	w8, w20, #0xfffffffc
	cmp	w8, #128
	b.ne	LBB0_7
; %bb.3:
	ldr	w0, [x19, #4]
	ldr	w1, [x22]
Lloh8:
	adrp	x8, _SM5502_REG_MANUAL_SW1_VBUSIN_MASK@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SM5502_REG_MANUAL_SW1_VBUSIN_MASK@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x3, x20
	bl	_regmap_update_bits
	tbnz	w0, #31, LBB0_10
; %bb.4:
	mov	w21, #0
	b	LBB0_9
LBB0_5:
	ldr	w0, [x19]
	str	x3, [sp]
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_8
LBB0_6:
	mov	x21, x0
	ldr	w0, [x19]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
	b	LBB0_9
LBB0_7:
	ldr	w0, [x19]
	str	x20, [sp]
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
LBB0_8:
	bl	_dev_err
Lloh17:
	adrp	x8, _EINVAL@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_9:
	mov	x0, x21
	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_10:
	mov	x21, x0
	ldr	w0, [x19]
Lloh20:
	adrp	x1, l_.str.2@PAGE
Lloh21:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_err
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_SM5502_REG_MANUAL_SW1,4,2      ; @SM5502_REG_MANUAL_SW1
	.comm	_SM5502_REG_MANUAL_SW1_DP_MASK,4,2 ; @SM5502_REG_MANUAL_SW1_DP_MASK
	.comm	_SM5502_REG_MANUAL_SW1_DM_MASK,4,2 ; @SM5502_REG_MANUAL_SW1_DM_MASK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cannot update DM_CON/DP_CON switch\n"

l_.str.1:                               ; @.str.1
	.asciz	"Unknown DM_CON/DP_CON switch type (%d)\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_SM5502_REG_MANUAL_SW1_VBUSIN_MASK,4,2 ; @SM5502_REG_MANUAL_SW1_VBUSIN_MASK
l_.str.2:                               ; @.str.2
	.asciz	"cannot update VBUSIN switch\n"

l_.str.3:                               ; @.str.3
	.asciz	"Unknown VBUS switch type (%d)\n"

	.no_dead_strip	_sm5502_muic_set_path
.subsections_via_symbols
