	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_enetc_open                     ## -- Begin function enetc_open
	.p2align	4, 0x90
_enetc_open:                            ## @enetc_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, %r14
	callq	_netdev_priv
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_enetc_setup_irqs
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_18
## %bb.1:
	movq	%r14, %rdi
	callq	_enetc_phy_connect
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_17
## %bb.2:
	movq	%r15, %rdi
	callq	_enetc_alloc_tx_resources
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.3:
	movq	%r15, %rdi
	callq	_enetc_alloc_rx_resources
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_14
## %bb.4:
	movq	%r15, %rdi
	callq	_enetc_setup_bdrs
	movl	20(%r15), %esi
	movq	%r14, %rdi
	callq	_netif_set_real_num_tx_queues
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_13
## %bb.5:
	movl	16(%r15), %esi
	movq	%r14, %rdi
	callq	_netif_set_real_num_rx_queues
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_6
LBB0_13:
	movq	%r15, %rdi
	callq	_enetc_free_rx_resources
LBB0_14:
	movq	%r15, %rdi
	callq	_enetc_free_tx_resources
LBB0_15:
	movq	(%r14), %rdi
	testq	%rdi, %rdi
	je	LBB0_17
## %bb.16:
	callq	_phy_disconnect
LBB0_17:
	movq	%r15, %rdi
	callq	_enetc_free_irqs
LBB0_18:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	cmpl	$0, (%r15)
	jle	LBB0_9
## %bb.7:
	xorl	%ebx, %ebx
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r15), %rax
	movq	(%rax,%rbx,8), %rdi
	callq	_napi_enable
	incq	%rbx
	movslq	(%r15), %rax
	cmpq	%rax, %rbx
	jl	LBB0_8
LBB0_9:
	movq	%r15, %rdi
	callq	_enetc_enable_interrupts
	movq	(%r14), %rdi
	testq	%rdi, %rdi
	je	LBB0_11
## %bb.10:
	callq	_phy_start
	jmp	LBB0_12
LBB0_11:
	movq	%r14, %rdi
	callq	_netif_carrier_on
LBB0_12:
	movq	%r14, %rdi
	callq	_netif_tx_start_all_queues
	xorl	%ebx, %ebx
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_enetc_open                     ; -- Begin function enetc_open
	.p2align	2
_enetc_open:                            ; @enetc_open
	.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
	bl	_enetc_setup_irqs
	mov	x21, x0
	cbnz	w0, LBB0_11
; %bb.1:
	mov	x0, x19
	bl	_enetc_phy_connect
	mov	x21, x0
	cbnz	w0, LBB0_10
; %bb.2:
	mov	x0, x20
	bl	_enetc_alloc_tx_resources
	mov	x21, x0
	cbnz	w0, LBB0_8
; %bb.3:
	mov	x0, x20
	bl	_enetc_alloc_rx_resources
	mov	x21, x0
	cbnz	w0, LBB0_7
; %bb.4:
	mov	x0, x20
	bl	_enetc_setup_bdrs
	ldr	w1, [x20, #20]
	mov	x0, x19
	bl	_netif_set_real_num_tx_queues
	mov	x21, x0
	cbnz	w0, LBB0_6
; %bb.5:
	ldr	w1, [x20, #16]
	mov	x0, x19
	bl	_netif_set_real_num_rx_queues
	mov	x21, x0
	cbz	w0, LBB0_12
LBB0_6:
	mov	x0, x20
	bl	_enetc_free_rx_resources
LBB0_7:
	mov	x0, x20
	bl	_enetc_free_tx_resources
LBB0_8:
	ldr	x0, [x19]
	cbz	x0, LBB0_10
; %bb.9:
	bl	_phy_disconnect
LBB0_10:
	mov	x0, x20
	bl	_enetc_free_irqs
LBB0_11:
	mov	x0, x21
	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_12:
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.13:
	mov	x21, #0
LBB0_14:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x20, #8]
	ldr	x0, [x8, x21, lsl #3]
	bl	_napi_enable
	add	x21, x21, #1
	ldrsw	x8, [x20]
	cmp	x21, x8
	b.lt	LBB0_14
LBB0_15:
	mov	x0, x20
	bl	_enetc_enable_interrupts
	ldr	x0, [x19]
	cbz	x0, LBB0_17
; %bb.16:
	bl	_phy_start
	b	LBB0_18
LBB0_17:
	mov	x0, x19
	bl	_netif_carrier_on
LBB0_18:
	mov	x0, x19
	bl	_netif_tx_start_all_queues
	mov	w21, #0
	b	LBB0_11
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
