	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function a38x_comphy_xlate
_a38x_comphy_xlate:                     ## @a38x_comphy_xlate
	.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	%rsi, %rbx
	movq	%rdi, %r14
	movq	(%rsi), %rax
	movq	(%rax), %rax
	movq	_MAX_A38X_PORTS@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	setge	%dil
	callq	_WARN_ON
	movq	_EINVAL@GOTPCREL(%rip), %r12
	testq	%rax, %rax
	je	LBB0_1
LBB0_7:
	xorl	%edi, %edi
	subl	(%r12), %edi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_1:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_of_phy_simple_xlate
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_2
LBB0_8:
	movq	%r14, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	%r14, %rdi
	callq	_phy_get_drvdata
	cmpq	$0, (%rax)
	js	LBB0_4
## %bb.3:
	movq	_EBUSY@GOTPCREL(%rip), %r12
	jmp	LBB0_7
LBB0_4:
	movq	%rax, %r15
	movq	(%rbx), %rax
	movq	(%rax), %rax
	movq	%rax, (%r15)
	movq	16(%r15), %rax
	movq	_COMPHY_SELECTOR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	addq	8(%rax), %rdi
	callq	_readl_relaxed
	movslq	8(%r15), %rdx
	movq	_gbe_mux@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rcx,%rdx,8), %rcx
	movq	(%r15), %rsi
	movl	(%rcx,%rsi,4), %esi
	testl	%esi, %esi
	je	LBB0_6
## %bb.5:
	leal	(,%rdx,4), %ecx
                                        ## kill: def $cl killed $cl killed $ecx
	sarl	%cl, %eax
	andl	$15, %eax
	cmpl	%esi, %eax
	je	LBB0_8
LBB0_6:
	movq	16(%r15), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_warn
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_A38X_PORTS,8,3             ## @MAX_A38X_PORTS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_COMPHY_SELECTOR,8,3            ## @COMPHY_SELECTOR
	.comm	_gbe_mux,8,3                    ## @gbe_mux
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"comphy%u: not configured for GBE\n"

	.no_dead_strip	_a38x_comphy_xlate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function a38x_comphy_xlate
_a38x_comphy_xlate:                     ; @a38x_comphy_xlate
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x20, x1
	mov	x19, x0
	ldr	x8, [x1]
	ldr	x8, [x8]
Lloh0:
	adrp	x9, _MAX_A38X_PORTS@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MAX_A38X_PORTS@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, ge
	bl	_WARN_ON
	cbz	x0, LBB0_3
LBB0_1:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_ERR_PTR
LBB0_3:
	mov	x0, x19
	mov	x1, x20
	bl	_of_phy_simple_xlate
	mov	x19, x0
	bl	_IS_ERR
	cbz	x0, LBB0_5
LBB0_4:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_5:
	mov	x0, x19
	bl	_phy_get_drvdata
	ldr	x8, [x0]
	tbnz	x8, #63, LBB0_7
; %bb.6:
Lloh5:
	adrp	x8, _EBUSY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_2
LBB0_7:
	mov	x21, x0
	ldr	x8, [x20]
	ldr	x8, [x8]
	str	x8, [x0]
	ldr	x8, [x0, #16]
	ldr	x8, [x8, #8]
Lloh7:
	adrp	x9, _COMPHY_SELECTOR@GOTPAGE
Lloh8:
	ldr	x9, [x9, _COMPHY_SELECTOR@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl_relaxed
	ldrsw	x2, [x21, #8]
Lloh10:
	adrp	x8, _gbe_mux@GOTPAGE
Lloh11:
	ldr	x8, [x8, _gbe_mux@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	ldr	x8, [x8, x2, lsl #3]
	ldr	x9, [x21]
	ldr	w8, [x8, x9, lsl #2]
	cmp	w8, #0
	lsl	w9, w2, #2
	asr	w9, w0, w9
	and	w9, w9, #0xf
	ccmp	w9, w8, #0, ne
	b.eq	LBB0_4
; %bb.8:
	ldr	x8, [x21, #16]
	ldr	w0, [x8]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_warn
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_A38X_PORTS,8,3             ; @MAX_A38X_PORTS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_COMPHY_SELECTOR,8,3            ; @COMPHY_SELECTOR
	.comm	_gbe_mux,8,3                    ; @gbe_mux
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"comphy%u: not configured for GBE\n"

	.no_dead_strip	_a38x_comphy_xlate
.subsections_via_symbols
