	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function smsc95xx_link_reset
_smsc95xx_link_reset:                   ## @smsc95xx_link_reset
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	8(%rdi), %rax
	movq	(%rax), %r13
	leaq	4(%rdi), %r14
	movl	(%rdi), %edi
	movl	4(%rbx), %esi
	movq	_PHY_INT_SRC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_smsc95xx_mdio_read
	movq	_INT_STS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$-1, %edx
	callq	_smsc95xx_write_reg
	movq	%r14, %rdi
	movl	$1, %esi
	movl	$1, %edx
	callq	_mii_check_media
	leaq	-56(%rbp), %rsi
	movq	%r14, %rdi
	callq	_mii_ethtool_gset
	movl	(%rbx), %edi
	movl	4(%rbx), %esi
	movq	_MII_ADVERTISE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_smsc95xx_mdio_read
	movl	%eax, %r14d
	movl	(%rbx), %edi
	movl	4(%rbx), %esi
	movq	_MII_LPA@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_smsc95xx_mdio_read
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_netif_msg_link
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	-48(%rbp), %edx
	movq	-56(%rbp), %rcx
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%r14d, %r8d
	movl	%r15d, %r9d
	callq	_devdbg
LBB0_2:
	leaq	4(%r13), %r12
	movq	%r12, %rdi
	callq	_spin_lock_irqsave
	movq	-56(%rbp), %rax
	movq	_DUPLEX_FULL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.4:
	movq	_MAC_CR_RCVOWN_@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	(%r13), %eax
	movl	%eax, (%r13)
	movq	_MAC_CR_FDPX_@GOTPCREL(%rip), %rcx
	jmp	LBB0_5
LBB0_3:
	movq	_MAC_CR_FDPX_@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	(%r13), %eax
	movl	%eax, (%r13)
	movq	_MAC_CR_RCVOWN_@GOTPCREL(%rip), %rcx
LBB0_5:
	orl	(%rcx), %eax
	movl	%eax, (%r13)
	movq	%r12, %rdi
	callq	_spin_unlock_irqrestore
	movq	_MAC_CR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r13), %edx
	movq	%rbx, %rdi
	callq	_smsc95xx_write_reg
	movq	-56(%rbp), %rsi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	movl	%r15d, %ecx
	callq	_smsc95xx_phy_update_flowcontrol
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PHY_INT_SRC,4,2                ## @PHY_INT_SRC
	.comm	_INT_STS,4,2                    ## @INT_STS
	.comm	_MII_ADVERTISE,4,2              ## @MII_ADVERTISE
	.comm	_MII_LPA,4,2                    ## @MII_LPA
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"speed: %d duplex: %d lcladv: %04x rmtadv: %04x"

	.comm	_DUPLEX_FULL,8,3                ## @DUPLEX_FULL
	.comm	_MAC_CR_FDPX_,4,2               ## @MAC_CR_FDPX_
	.comm	_MAC_CR_RCVOWN_,4,2             ## @MAC_CR_RCVOWN_
	.comm	_MAC_CR,4,2                     ## @MAC_CR
	.no_dead_strip	_smsc95xx_link_reset
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function smsc95xx_link_reset
_smsc95xx_link_reset:                   ; @smsc95xx_link_reset
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	ldr	x8, [x0, #8]
	ldr	x23, [x8]
	ldr	w0, [x0]
	mov	x21, x19
	ldr	w1, [x21, #4]!
Lloh0:
	adrp	x8, _PHY_INT_SRC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PHY_INT_SRC@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	bl	_smsc95xx_mdio_read
Lloh3:
	adrp	x8, _INT_STS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _INT_STS@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #-1
	bl	_smsc95xx_write_reg
	mov	x0, x21
	mov	w1, #1
	mov	w2, #1
	bl	_mii_check_media
	mov	x1, sp
	mov	x0, x21
	bl	_mii_ethtool_gset
	ldr	w0, [x19]
	ldr	w1, [x21]
Lloh6:
	adrp	x8, _MII_ADVERTISE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MII_ADVERTISE@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	bl	_smsc95xx_mdio_read
	mov	x20, x0
	ldr	w0, [x19]
	ldr	w1, [x21]
Lloh9:
	adrp	x8, _MII_LPA@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MII_LPA@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	bl	_smsc95xx_mdio_read
	mov	x21, x0
	mov	x0, x19
	bl	_netif_msg_link
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w2, [sp, #8]
	ldr	x3, [sp]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x4, x20
	mov	x5, x21
	bl	_devdbg
LBB0_2:
	add	x22, x23, #4
	mov	x0, x22
	bl	_spin_lock_irqsave
	ldr	x8, [sp]
Lloh14:
	adrp	x9, _DUPLEX_FULL@GOTPAGE
Lloh15:
	ldr	x9, [x9, _DUPLEX_FULL@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.3:
Lloh17:
	adrp	x8, _MAC_CR_RCVOWN_@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MAC_CR_RCVOWN_@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	ldr	w9, [x23]
	bic	w8, w9, w8
	str	w8, [x23]
Lloh20:
	adrp	x9, _MAC_CR_FDPX_@GOTPAGE
Lloh21:
	ldr	x9, [x9, _MAC_CR_FDPX_@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:
Lloh22:
	adrp	x8, _MAC_CR_FDPX_@GOTPAGE
Lloh23:
	ldr	x8, [x8, _MAC_CR_FDPX_@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	ldr	w9, [x23]
	bic	w8, w9, w8
	str	w8, [x23]
Lloh25:
	adrp	x9, _MAC_CR_RCVOWN_@GOTPAGE
Lloh26:
	ldr	x9, [x9, _MAC_CR_RCVOWN_@GOTPAGEOFF]
LBB0_5:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x23]
	mov	x0, x22
	bl	_spin_unlock_irqrestore
Lloh27:
	adrp	x8, _MAC_CR@GOTPAGE
Lloh28:
	ldr	x8, [x8, _MAC_CR@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	ldr	w2, [x23]
	mov	x0, x19
	bl	_smsc95xx_write_reg
	ldr	x1, [sp]
	mov	x0, x19
	mov	x2, x20
	mov	x3, x21
	bl	_smsc95xx_phy_update_flowcontrol
	mov	w0, #0
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_PHY_INT_SRC,4,2                ; @PHY_INT_SRC
	.comm	_INT_STS,4,2                    ; @INT_STS
	.comm	_MII_ADVERTISE,4,2              ; @MII_ADVERTISE
	.comm	_MII_LPA,4,2                    ; @MII_LPA
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"speed: %d duplex: %d lcladv: %04x rmtadv: %04x"

	.comm	_DUPLEX_FULL,8,3                ; @DUPLEX_FULL
	.comm	_MAC_CR_FDPX_,4,2               ; @MAC_CR_FDPX_
	.comm	_MAC_CR_RCVOWN_,4,2             ; @MAC_CR_RCVOWN_
	.comm	_MAC_CR,4,2                     ; @MAC_CR
	.no_dead_strip	_smsc95xx_link_reset
.subsections_via_symbols
