	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcmgenet_mii_probe             ## -- Begin function bcmgenet_mii_probe
	.p2align	4, 0x90
_bcmgenet_mii_probe:                    ## @bcmgenet_mii_probe
	.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
	callq	_netdev_priv
	movq	%rax, %rbx
	movq	40(%rax), %rax
	movq	(%rax), %rax
	cmpq	$0, 16(%rbx)
	je	LBB0_1
## %bb.2:
	movl	32(%rbx), %ecx
	jmp	LBB0_3
LBB0_1:
	xorl	%ecx, %ecx
LBB0_3:
	pcmpeqd	%xmm0, %xmm0
	movdqu	%xmm0, (%rbx)
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movl	24(%rbx), %r8d
	movl	28(%rbx), %esi
	movq	_bcmgenet_mii_setup@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_of_phy_connect
	movq	%rax, %r12
	testq	%rax, %rax
	je	LBB0_5
LBB0_7:
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_bcmgenet_mii_config
	testl	%eax, %eax
	je	LBB0_9
## %bb.8:
	movl	%eax, %r15d
	movq	(%r14), %rdi
	callq	_phy_disconnect
	jmp	LBB0_12
LBB0_6:
	movq	(%r14), %r12
	movl	%ecx, 12(%r12)
	movq	_bcmgenet_mii_setup@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	24(%rbx), %ecx
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_phy_connect_direct
	testl	%eax, %eax
	je	LBB0_7
LBB0_5:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_12:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movl	4(%r12), %esi
	movl	8(%r12), %edi
	callq	_linkmode_copy
	xorl	%r15d, %r15d
	cmpq	$0, 16(%rbx)
	je	LBB0_12
## %bb.10:
	movq	%rbx, %rdi
	callq	_GENET_IS_V5
	testl	%eax, %eax
	jne	LBB0_12
## %bb.11:
	movq	_PHY_IGNORE_INTERRUPT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	(%r14), %rcx
	movl	%eax, (%rcx)
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_bcmgenet_mii_setup,4,2         ## @bcmgenet_mii_setup
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"could not attach to PHY\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_PHY_IGNORE_INTERRUPT,4,2       ## @PHY_IGNORE_INTERRUPT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcmgenet_mii_probe             ; -- Begin function bcmgenet_mii_probe
	.p2align	2
_bcmgenet_mii_probe:                    ; @bcmgenet_mii_probe
	.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	x19, x0
	bl	_netdev_priv
	mov	x20, x0
	ldr	x8, [x0, #40]
	ldr	x8, [x8]
	ldr	x9, [x0, #16]
	cbz	x9, LBB0_2
; %bb.1:
	ldr	w3, [x20, #32]
	b	LBB0_3
LBB0_2:
	mov	w3, #0
LBB0_3:
	mov	x9, #-1
	stp	x9, x9, [x20]
	cbz	x8, LBB0_7
; %bb.4:
Lloh0:
	adrp	x8, _bcmgenet_mii_setup@GOTPAGE
Lloh1:
	ldr	x8, [x8, _bcmgenet_mii_setup@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	ldp	w4, w1, [x20, #24]
	mov	x0, x19
	bl	_of_phy_connect
	mov	x21, x0
	cbz	x0, LBB0_8
LBB0_5:
	mov	x0, x19
	mov	w1, #1
	bl	_bcmgenet_mii_config
	cbz	w0, LBB0_10
; %bb.6:
	mov	x22, x0
	ldr	x0, [x19]
	bl	_phy_disconnect
	b	LBB0_9
LBB0_7:
	ldr	x21, [x19]
	str	w3, [x21, #12]
Lloh3:
	adrp	x8, _bcmgenet_mii_setup@GOTPAGE
Lloh4:
	ldr	x8, [x8, _bcmgenet_mii_setup@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	ldr	w3, [x20, #24]
	mov	x0, x19
	mov	x1, x21
	bl	_phy_connect_direct
	cbz	w0, LBB0_5
LBB0_8:
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
Lloh8:
	adrp	x8, _ENODEV@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_9:
	mov	x0, x22
	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_10:
	ldp	w1, w0, [x21, #4]
	bl	_linkmode_copy
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_13
; %bb.11:
	mov	x0, x20
	bl	_GENET_IS_V5
	mov	w22, #0
	cbnz	w0, LBB0_9
; %bb.12:
Lloh11:
	adrp	x8, _PHY_IGNORE_INTERRUPT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _PHY_IGNORE_INTERRUPT@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	ldr	x9, [x19]
	str	w8, [x9]
	b	LBB0_9
LBB0_13:
	mov	w22, #0
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_bcmgenet_mii_setup,4,2         ; @bcmgenet_mii_setup
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"could not attach to PHY\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_PHY_IGNORE_INTERRUPT,4,2       ; @PHY_IGNORE_INTERRUPT
.subsections_via_symbols
