	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function emac_open
_emac_open:                             ## @emac_open
	.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	%rdi, %rbx
	callq	_netdev_priv
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_netif_msg_ifup
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	(%r15), %edi
	movl	8(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	callq	_dev_dbg
LBB0_2:
	movl	4(%rbx), %edi
	movl	8(%rbx), %ecx
	movq	_emac_interrupt@GOTPCREL(%rip), %rsi
	xorl	%r14d, %r14d
	xorl	%edx, %edx
	movq	%rbx, %r8
	callq	_request_irq
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	jmp	LBB0_7
LBB0_4:
	movq	%r15, %rdi
	callq	_emac_reset
	movq	%rbx, %rdi
	callq	_emac_init_device
	movq	%rbx, %rdi
	callq	_emac_mdio_probe
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:
	movl	(%rbx), %edi
	callq	_phy_start
	movq	%rbx, %rdi
	callq	_netif_start_queue
	xorl	%r14d, %r14d
	jmp	LBB0_7
LBB0_5:
	movl	%eax, %r14d
	movl	4(%rbx), %edi
	movq	%rbx, %rsi
	callq	_free_irq
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_netdev_err
LBB0_7:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"enabling %s\n"

	.comm	_emac_interrupt,4,2             ## @emac_interrupt
	.comm	_EAGAIN,4,2                     ## @EAGAIN
L_.str.1:                               ## @.str.1
	.asciz	"cannot probe MDIO bus\n"

	.no_dead_strip	_emac_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function emac_open
_emac_open:                             ; @emac_open
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_netdev_priv
	mov	x20, x0
	bl	_netif_msg_ifup
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x20]
	ldr	w2, [x19, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
LBB0_2:
	ldp	w0, w3, [x19, #4]
Lloh2:
	adrp	x1, _emac_interrupt@GOTPAGE
Lloh3:
	ldr	x1, [x1, _emac_interrupt@GOTPAGEOFF]
	mov	w2, #0
	mov	x4, x19
	bl	_request_irq
	cbz	x0, LBB0_4
; %bb.3:
Lloh4:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_7
LBB0_4:
	mov	x0, x20
	bl	_emac_reset
	mov	x0, x19
	bl	_emac_init_device
	mov	x0, x19
	bl	_emac_mdio_probe
	tbnz	w0, #31, LBB0_6
; %bb.5:
	ldr	w0, [x19]
	bl	_phy_start
	mov	x0, x19
	bl	_netif_start_queue
	mov	w20, #0
	b	LBB0_7
LBB0_6:
	mov	x20, x0
	ldr	w0, [x19, #4]
	mov	x1, x19
	bl	_free_irq
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_netdev_err
LBB0_7:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"enabling %s\n"

	.comm	_emac_interrupt,4,2             ; @emac_interrupt
	.comm	_EAGAIN,4,2                     ; @EAGAIN
l_.str.1:                               ; @.str.1
	.asciz	"cannot probe MDIO bus\n"

	.no_dead_strip	_emac_open
.subsections_via_symbols
