	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function aml8726_usb_phy_mode
_aml8726_usb_phy_mode:                  ## @aml8726_usb_phy_mode
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	callq	_OF_finddevice
	cmpl	$-1, %eax
	je	LBB0_1
## %bb.2:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edi
	callq	_fdt_is_compatible_strict
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movl	$0, (%r14)
	leaq	L_.str.1(%rip), %rsi
	leaq	-32(%rbp), %rdx
	movl	%ebx, %edi
	callq	_OF_getprop_alloc
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jle	LBB0_10
## %bb.4:
	movq	-32(%rbp), %r15
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	callq	_strcasecmp
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	leaq	L_.str.3(%rip), %rsi
	movq	%r15, %rdi
	callq	_strcasecmp
	testq	%rax, %rax
	jne	LBB0_9
## %bb.7:
	movq	_AML_USB_PHY_MISC_ID_OVERIDE_DEVICE@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_1:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_10
LBB0_5:
	movq	_AML_USB_PHY_MISC_ID_OVERIDE_HOST@GOTPCREL(%rip), %rax
LBB0_8:
	movq	_AML_USB_PHY_MISC_ID_OVERIDE_EN@GOTPCREL(%rip), %rcx
	movl	(%rax), %eax
	orl	(%rcx), %eax
	movl	%eax, (%r14)
LBB0_9:
	movq	%r15, %rdi
	callq	_OF_prop_free
LBB0_10:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENXIO,4,2                      ## @ENXIO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"synopsys,designware-hs-otg2"

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

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

	.comm	_AML_USB_PHY_MISC_ID_OVERIDE_EN,4,2 ## @AML_USB_PHY_MISC_ID_OVERIDE_EN
	.comm	_AML_USB_PHY_MISC_ID_OVERIDE_HOST,4,2 ## @AML_USB_PHY_MISC_ID_OVERIDE_HOST
L_.str.3:                               ## @.str.3
	.asciz	"peripheral"

	.comm	_AML_USB_PHY_MISC_ID_OVERIDE_DEVICE,4,2 ## @AML_USB_PHY_MISC_ID_OVERIDE_DEVICE
	.no_dead_strip	_aml8726_usb_phy_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function aml8726_usb_phy_mode
_aml8726_usb_phy_mode:                  ; @aml8726_usb_phy_mode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	bl	_OF_finddevice
	cmn	w0, #1
	b.eq	LBB0_6
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_fdt_is_compatible_strict
	cbz	x0, LBB0_6
; %bb.2:
	str	wzr, [x19]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x2, sp, #8
	mov	x0, x20
	bl	_OF_getprop_alloc
	cmp	x0, #1
	b.lt	LBB0_10
; %bb.3:
	ldr	x20, [sp, #8]
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_strcasecmp
	cbz	x0, LBB0_7
; %bb.4:
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	bl	_strcasecmp
	cbnz	x0, LBB0_9
; %bb.5:
Lloh8:
	adrp	x8, _AML_USB_PHY_MISC_ID_OVERIDE_DEVICE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AML_USB_PHY_MISC_ID_OVERIDE_DEVICE@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
Lloh10:
	adrp	x8, _ENXIO@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
	b	LBB0_11
LBB0_7:
Lloh13:
	adrp	x8, _AML_USB_PHY_MISC_ID_OVERIDE_HOST@GOTPAGE
Lloh14:
	ldr	x8, [x8, _AML_USB_PHY_MISC_ID_OVERIDE_HOST@GOTPAGEOFF]
LBB0_8:
Lloh15:
	adrp	x9, _AML_USB_PHY_MISC_ID_OVERIDE_EN@GOTPAGE
Lloh16:
	ldr	x9, [x9, _AML_USB_PHY_MISC_ID_OVERIDE_EN@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	ldr	w8, [x8]
	orr	w8, w8, w9
	str	w8, [x19]
LBB0_9:
	mov	x0, x20
	bl	_OF_prop_free
LBB0_10:
	mov	w0, #0
LBB0_11:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ENXIO,4,2                      ; @ENXIO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"synopsys,designware-hs-otg2"

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

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

	.comm	_AML_USB_PHY_MISC_ID_OVERIDE_EN,4,2 ; @AML_USB_PHY_MISC_ID_OVERIDE_EN
	.comm	_AML_USB_PHY_MISC_ID_OVERIDE_HOST,4,2 ; @AML_USB_PHY_MISC_ID_OVERIDE_HOST
l_.str.3:                               ; @.str.3
	.asciz	"peripheral"

	.comm	_AML_USB_PHY_MISC_ID_OVERIDE_DEVICE,4,2 ; @AML_USB_PHY_MISC_ID_OVERIDE_DEVICE
	.no_dead_strip	_aml8726_usb_phy_mode
.subsections_via_symbols
