	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mvebu_comphy_power_on
_mvebu_comphy_power_on:                 ## @mvebu_comphy_power_on
	.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
	callq	_phy_get_drvdata
	movq	%rax, %rbx
	movq	16(%rax), %r13
	movl	(%rax), %edx
	movl	4(%rax), %edi
	movl	12(%rax), %esi
	movl	8(%rax), %ecx
	callq	_mvebu_comphy_get_fw_mode
	testl	%eax, %eax
	js	LBB0_22
## %bb.1:
	movl	%eax, %r15d
	movl	(%rbx), %edx
	leal	-128(%rdx), %eax
	cmpl	$4, %eax
	ja	LBB0_4
## %bb.2:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_3:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	leaq	L_.str.5(%rip), %rsi
	jmp	LBB0_7
LBB0_4:
	movl	(%r13), %edi
	leaq	L_.str.8(%rip), %rsi
LBB0_5:
	xorl	%ebx, %ebx
                                        ## kill: def $edx killed $edx killed $rdx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ENOTSUPP@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_24
LBB0_6:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	leaq	L_.str.6(%rip), %rsi
LBB0_7:
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	12(%rbx), %esi
	movl	%r15d, %edi
	callq	_COMPHY_FW_PARAM
	jmp	LBB0_18
LBB0_8:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	movl	8(%rbx), %ecx
	leaq	L_.str.7(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	8(%rbx), %edx
	movl	12(%rbx), %esi
	movl	%r15d, %edi
	callq	_COMPHY_FW_PARAM_PCIE
	jmp	LBB0_18
LBB0_9:
	movl	8(%rbx), %edx
	leal	-133(%rdx), %eax
	cmpl	$3, %eax
	ja	LBB0_12
## %bb.10:
	leaq	LJTI0_1(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_11:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_COMPHY_FW_SPEED_1250@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_12:
	movl	(%r13), %edi
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_5
LBB0_13:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	callq	_dev_dbg
	jmp	LBB0_17
LBB0_14:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_COMPHY_FW_SPEED_3125@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_15:
	movl	(%r13), %edi
	movl	4(%rbx), %edx
	leaq	L_.str.3(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_COMPHY_FW_SPEED_103125@GOTPCREL(%rip), %rax
LBB0_16:
	movl	(%rax), %r12d
LBB0_17:
	movl	12(%rbx), %esi
	movl	%r15d, %edi
	movl	%r12d, %edx
	callq	_COMPHY_FW_PARAM_ETH
LBB0_18:
	movq	_COMPHY_SIP_POWER_ON@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	movl	4(%r13), %esi
	movl	4(%rbx), %edx
	movl	%eax, %ecx
	callq	_mvebu_comphy_smc
	testl	%eax, %eax
	je	LBB0_23
## %bb.19:
	movl	%eax, %r15d
	movq	_COMPHY_FW_NOT_SUPPORTED@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r15d
	jne	LBB0_21
## %bb.20:
	movl	(%r13), %edi
	leaq	L_.str.9(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_err
LBB0_21:
	movl	(%r13), %edi
	movl	(%rbx), %ecx
	movl	4(%rbx), %edx
	leaq	L_.str.10(%rip), %rsi
	movl	%r15d, %r8d
	callq	_dev_warn
LBB0_22:
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mvebu_comphy_power_on_legacy   ## TAILCALL
LBB0_23:
	xorl	%ebx, %ebx
LBB0_24:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
LJTI0_0:
	.long	L0_0_set_3
	.long	L0_0_set_3
	.long	L0_0_set_6
	.long	L0_0_set_8
	.long	L0_0_set_9
.set L0_1_set_11, LBB0_11-LJTI0_1
.set L0_1_set_13, LBB0_13-LJTI0_1
.set L0_1_set_14, LBB0_14-LJTI0_1
.set L0_1_set_15, LBB0_15-LJTI0_1
LJTI0_1:
	.long	L0_1_set_11
	.long	L0_1_set_13
	.long	L0_1_set_14
	.long	L0_1_set_15
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"set lane %d to RXAUI mode\n"

L_.str.1:                               ## @.str.1
	.asciz	"set lane %d to 1000BASE-X mode\n"

	.comm	_COMPHY_FW_SPEED_1250,4,2       ## @COMPHY_FW_SPEED_1250
L_.str.2:                               ## @.str.2
	.asciz	"set lane %d to 2500BASE-X mode\n"

	.comm	_COMPHY_FW_SPEED_3125,4,2       ## @COMPHY_FW_SPEED_3125
L_.str.3:                               ## @.str.3
	.asciz	"set lane %d to 10G-KR mode\n"

	.comm	_COMPHY_FW_SPEED_103125,4,2     ## @COMPHY_FW_SPEED_103125
L_.str.4:                               ## @.str.4
	.asciz	"unsupported Ethernet mode (%d)\n"

	.comm	_ENOTSUPP,4,2                   ## @ENOTSUPP
L_.str.5:                               ## @.str.5
	.asciz	"set lane %d to USB3 mode\n"

L_.str.6:                               ## @.str.6
	.asciz	"set lane %d to SATA mode\n"

L_.str.7:                               ## @.str.7
	.asciz	"set lane %d to PCIe mode (x%d)\n"

L_.str.8:                               ## @.str.8
	.asciz	"unsupported PHY mode (%d)\n"

	.comm	_COMPHY_SIP_POWER_ON,4,2        ## @COMPHY_SIP_POWER_ON
	.comm	_COMPHY_FW_NOT_SUPPORTED,4,2    ## @COMPHY_FW_NOT_SUPPORTED
L_.str.9:                               ## @.str.9
	.asciz	"unsupported SMC call, try updating your firmware\n"

L_.str.10:                              ## @.str.10
	.asciz	"Firmware could not configure PHY %d with mode %d (ret: %d), trying legacy method\n"

	.no_dead_strip	_mvebu_comphy_power_on
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mvebu_comphy_power_on
_mvebu_comphy_power_on:                 ; @mvebu_comphy_power_on
	.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
	bl	_phy_get_drvdata
	mov	x20, x0
	ldr	x22, [x0, #16]
	ldr	w0, [x0, #4]
	ldr	w2, [x20]
	ldp	w3, w1, [x20, #8]
	bl	_mvebu_comphy_get_fw_mode
	tbnz	w0, #31, LBB0_22
; %bb.1:
	ldr	w8, [x20]
	sub	w9, w8, #128
	cmp	w9, #4
	b.hi	LBB0_4
; %bb.2:
	mov	x21, x0
Lloh0:
	adrp	x8, lJTI0_0@PAGE
Lloh1:
	add	x8, x8, lJTI0_0@PAGEOFF
	adr	x10, LBB0_3
	ldrb	w11, [x8, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_3:
	ldr	w0, [x22]
	ldr	w2, [x20, #4]
Lloh2:
	adrp	x1, l_.str.5@PAGE
Lloh3:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_7
LBB0_4:
	ldr	w0, [x22]
	str	x8, [sp]
Lloh4:
	adrp	x1, l_.str.8@PAGE
Lloh5:
	add	x1, x1, l_.str.8@PAGEOFF
LBB0_5:
	bl	_dev_err
Lloh6:
	adrp	x8, _ENOTSUPP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOTSUPP@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_23
LBB0_6:
	ldr	w0, [x22]
	ldr	w2, [x20, #4]
Lloh9:
	adrp	x1, l_.str.6@PAGE
Lloh10:
	add	x1, x1, l_.str.6@PAGEOFF
LBB0_7:
	bl	_dev_dbg
	ldr	w1, [x20, #12]
	mov	x0, x21
	bl	_COMPHY_FW_PARAM
	b	LBB0_18
LBB0_8:
	ldr	w0, [x22]
	ldp	w2, w8, [x20, #4]
	str	x8, [sp]
Lloh11:
	adrp	x1, l_.str.7@PAGE
Lloh12:
	add	x1, x1, l_.str.7@PAGEOFF
	bl	_dev_dbg
	ldp	w2, w1, [x20, #8]
	mov	x0, x21
	bl	_COMPHY_FW_PARAM_PCIE
	b	LBB0_18
LBB0_9:
	ldr	w8, [x20, #8]
	sub	w9, w8, #133
	cmp	w9, #3
	b.hi	LBB0_12
; %bb.10:
Lloh13:
	adrp	x8, lJTI0_1@PAGE
Lloh14:
	add	x8, x8, lJTI0_1@PAGEOFF
	adr	x10, LBB0_11
	ldrb	w11, [x8, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_11:
	ldr	w0, [x22]
	ldr	w2, [x20, #4]
Lloh15:
	adrp	x1, l_.str.1@PAGE
Lloh16:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_dbg
Lloh17:
	adrp	x8, _COMPHY_FW_SPEED_1250@GOTPAGE
Lloh18:
	ldr	x8, [x8, _COMPHY_FW_SPEED_1250@GOTPAGEOFF]
	b	LBB0_16
LBB0_12:
	ldr	w0, [x22]
	str	x8, [sp]
Lloh19:
	adrp	x1, l_.str.4@PAGE
Lloh20:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_5
LBB0_13:
	ldr	w0, [x22]
	ldr	w2, [x20, #4]
Lloh21:
	adrp	x1, l_.str@PAGE
Lloh22:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
	mov	w2, #0
	b	LBB0_17
LBB0_14:
	ldr	w0, [x22]
	ldr	w2, [x20, #4]
Lloh23:
	adrp	x1, l_.str.2@PAGE
Lloh24:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_dbg
Lloh25:
	adrp	x8, _COMPHY_FW_SPEED_3125@GOTPAGE
Lloh26:
	ldr	x8, [x8, _COMPHY_FW_SPEED_3125@GOTPAGEOFF]
	b	LBB0_16
LBB0_15:
	ldr	w0, [x22]
	ldr	w2, [x20, #4]
Lloh27:
	adrp	x1, l_.str.3@PAGE
Lloh28:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_dbg
Lloh29:
	adrp	x8, _COMPHY_FW_SPEED_103125@GOTPAGE
Lloh30:
	ldr	x8, [x8, _COMPHY_FW_SPEED_103125@GOTPAGEOFF]
LBB0_16:
	ldr	w2, [x8]
LBB0_17:
	ldr	w1, [x20, #12]
	mov	x0, x21
	bl	_COMPHY_FW_PARAM_ETH
LBB0_18:
	mov	x3, x0
Lloh31:
	adrp	x8, _COMPHY_SIP_POWER_ON@GOTPAGE
Lloh32:
	ldr	x8, [x8, _COMPHY_SIP_POWER_ON@GOTPAGEOFF]
Lloh33:
	ldr	w0, [x8]
	ldr	w1, [x22, #4]
	ldr	w2, [x20, #4]
	bl	_mvebu_comphy_smc
	cbz	w0, LBB0_23
; %bb.19:
	mov	x21, x0
Lloh34:
	adrp	x8, _COMPHY_FW_NOT_SUPPORTED@GOTPAGE
Lloh35:
	ldr	x8, [x8, _COMPHY_FW_NOT_SUPPORTED@GOTPAGEOFF]
Lloh36:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_21
; %bb.20:
	ldr	w0, [x22]
Lloh37:
	adrp	x1, l_.str.9@PAGE
Lloh38:
	add	x1, x1, l_.str.9@PAGEOFF
	bl	_dev_err
LBB0_21:
	ldr	w0, [x22]
	ldp	w3, w2, [x20]
Lloh39:
	adrp	x1, l_.str.10@PAGE
Lloh40:
	add	x1, x1, l_.str.10@PAGEOFF
	mov	x4, x21
	bl	_dev_warn
LBB0_22:
	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
	add	sp, sp, #64
	b	_mvebu_comphy_power_on_legacy
LBB0_23:
	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
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_3)>>2
	.byte	(LBB0_3-LBB0_3)>>2
	.byte	(LBB0_6-LBB0_3)>>2
	.byte	(LBB0_8-LBB0_3)>>2
	.byte	(LBB0_9-LBB0_3)>>2
lJTI0_1:
	.byte	(LBB0_11-LBB0_11)>>2
	.byte	(LBB0_13-LBB0_11)>>2
	.byte	(LBB0_14-LBB0_11)>>2
	.byte	(LBB0_15-LBB0_11)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"set lane %d to RXAUI mode\n"

l_.str.1:                               ; @.str.1
	.asciz	"set lane %d to 1000BASE-X mode\n"

	.comm	_COMPHY_FW_SPEED_1250,4,2       ; @COMPHY_FW_SPEED_1250
l_.str.2:                               ; @.str.2
	.asciz	"set lane %d to 2500BASE-X mode\n"

	.comm	_COMPHY_FW_SPEED_3125,4,2       ; @COMPHY_FW_SPEED_3125
l_.str.3:                               ; @.str.3
	.asciz	"set lane %d to 10G-KR mode\n"

	.comm	_COMPHY_FW_SPEED_103125,4,2     ; @COMPHY_FW_SPEED_103125
l_.str.4:                               ; @.str.4
	.asciz	"unsupported Ethernet mode (%d)\n"

	.comm	_ENOTSUPP,4,2                   ; @ENOTSUPP
l_.str.5:                               ; @.str.5
	.asciz	"set lane %d to USB3 mode\n"

l_.str.6:                               ; @.str.6
	.asciz	"set lane %d to SATA mode\n"

l_.str.7:                               ; @.str.7
	.asciz	"set lane %d to PCIe mode (x%d)\n"

l_.str.8:                               ; @.str.8
	.asciz	"unsupported PHY mode (%d)\n"

	.comm	_COMPHY_SIP_POWER_ON,4,2        ; @COMPHY_SIP_POWER_ON
	.comm	_COMPHY_FW_NOT_SUPPORTED,4,2    ; @COMPHY_FW_NOT_SUPPORTED
l_.str.9:                               ; @.str.9
	.asciz	"unsupported SMC call, try updating your firmware\n"

l_.str.10:                              ; @.str.10
	.asciz	"Firmware could not configure PHY %d with mode %d (ret: %d), trying legacy method\n"

	.no_dead_strip	_mvebu_comphy_power_on
.subsections_via_symbols
