	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnad_open
_bnad_open:                             ## @bnad_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	%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, %r15
	callq	_netdev_priv
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_mutex_lock
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bnad_setup_tx
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_4
## %bb.1:
	xorl	%r14d, %r14d
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bnad_setup_rx
	testl	%eax, %eax
	je	LBB0_2
## %bb.3:
	movl	%eax, %r12d
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bnad_destroy_tx
	movl	%r12d, %r14d
	jmp	LBB0_4
LBB0_2:
	xorps	%xmm0, %xmm0
	movq	_ETH_HLEN@GOTPCREL(%rip), %rax
	movq	_VLAN_HLEN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	addl	(%rax), %r13d
	movaps	%xmm0, -64(%rbp)
	movq	16(%rbx), %rax
	addl	(%rax), %r13d
	movq	_ETH_FCS_LEN@GOTPCREL(%rip), %rax
	addl	(%rax), %r13d
	leaq	4(%rbx), %rdi
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	callq	_spin_lock_irqsave
	movq	%rbx, %r12
	addq	$8, %r12
	movq	%r12, %rdi
	movl	%r13d, %esi
	xorl	%edx, %edx
	callq	_bna_enet_mtu_set
	leaq	-64(%rbp), %rsi
	movq	%r12, %rdi
	xorl	%edx, %edx
	callq	_bna_enet_pause_config
	movq	%r12, %rdi
	callq	_bna_enet_enable
	movq	-48(%rbp), %r12                 ## 8-byte Reload
	movq	%r12, %rdi
	callq	_spin_unlock_irqrestore
	movq	%rbx, %rdi
	callq	_bnad_enable_default_bcast
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bnad_restore_vlans
	movq	%r12, %rdi
	callq	_spin_lock_irqsave
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_bnad_mac_addr_set_locked
	movq	%r12, %rdi
	callq	_spin_unlock_irqrestore
	movq	%rbx, %rdi
	callq	_bnad_stats_timer_start
LBB0_4:
	movq	%rbx, %rdi
	callq	_mutex_unlock
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ETH_HLEN,4,2                   ## @ETH_HLEN
	.comm	_VLAN_HLEN,4,2                  ## @VLAN_HLEN
	.comm	_ETH_FCS_LEN,4,2                ## @ETH_FCS_LEN
	.no_dead_strip	_bnad_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnad_open
_bnad_open:                             ; @bnad_open
	.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	x20, x0
	bl	_netdev_priv
	mov	x19, x0
	bl	_mutex_lock
	mov	x0, x19
	mov	w1, #0
	bl	_bnad_setup_tx
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.1:
	mov	x0, x19
	mov	w1, #0
	bl	_bnad_setup_rx
	cbz	w0, LBB0_5
; %bb.2:
	mov	x21, x0
	mov	x0, x19
	mov	w1, #0
	bl	_bnad_destroy_tx
LBB0_3:
	mov	x0, x19
	bl	_mutex_unlock
LBB0_4:
	mov	x0, x21
	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
LBB0_5:
	stp	xzr, xzr, [sp]
Lloh0:
	adrp	x8, _ETH_HLEN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ETH_HLEN@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _VLAN_HLEN@GOTPAGE
Lloh4:
	ldr	x9, [x9, _VLAN_HLEN@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	ldr	x10, [x19, #16]
	ldr	w10, [x10]
	add	w8, w9, w8
	add	w8, w8, w10
Lloh6:
	adrp	x9, _ETH_FCS_LEN@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ETH_FCS_LEN@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	add	w21, w8, w9
	add	x22, x19, #4
	mov	x0, x22
	bl	_spin_lock_irqsave
	add	x23, x19, #8
	mov	x0, x23
	mov	x1, x21
	mov	x2, #0
	bl	_bna_enet_mtu_set
	mov	x1, sp
	mov	x0, x23
	mov	x2, #0
	bl	_bna_enet_pause_config
	mov	x0, x23
	bl	_bna_enet_enable
	mov	x0, x22
	bl	_spin_unlock_irqrestore
	mov	x0, x19
	bl	_bnad_enable_default_bcast
	mov	x0, x19
	mov	w1, #0
	bl	_bnad_restore_vlans
	mov	x0, x22
	bl	_spin_lock_irqsave
	ldr	w1, [x20]
	mov	x0, x19
	bl	_bnad_mac_addr_set_locked
	mov	x0, x22
	bl	_spin_unlock_irqrestore
	mov	x0, x19
	bl	_bnad_stats_timer_start
	mov	x0, x19
	bl	_mutex_unlock
	mov	w21, #0
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_ETH_HLEN,4,2                   ; @ETH_HLEN
	.comm	_VLAN_HLEN,4,2                  ; @VLAN_HLEN
	.comm	_ETH_FCS_LEN,4,2                ; @ETH_FCS_LEN
	.no_dead_strip	_bnad_open
.subsections_via_symbols
