	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function send_packet
_send_packet:                           ## @send_packet
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r13
	callq	_netdev_priv
	movq	%rax, %rbx
	movl	(%r14), %eax
	leal	1(%rax), %ecx
	andl	$-2, %ecx
	cmpl	$60, %eax
	movl	$60, %r15d
	cmovgel	%ecx, %r15d
	leaq	40(%rbx), %r12
	xorl	%edi, %edi
	movq	%r12, %rsi
	callq	_test_and_set_bit
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	_elp_debug@GOTPCREL(%rip), %rax
	cmpl	$2, (%rax)
	movl	$0, %ebx
	jl	LBB0_13
## %bb.2:
	movl	(%r13), %esi
	leaq	L_.str(%rip), %rdi
	xorl	%ebx, %ebx
	jmp	LBB0_12
LBB0_3:
	addl	%r15d, 8(%r13)
	movq	_CMD_TRANSMIT_PACKET@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	leaq	48(%rbx), %rsi
	movl	%eax, 80(%rbx)
	movl	$4, 48(%rbx)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 64(%rbx)
	movl	%r15d, 56(%rbx)
	movq	%r13, -48(%rbp)                 ## 8-byte Spill
	movq	%r13, %rdi
	callq	_send_pcb
	testl	%eax, %eax
	je	LBB0_4
## %bb.5:
	movq	%rbx, %rsi
	addq	$32, %rsi
	xorl	%edi, %edi
	callq	_test_and_set_bit
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %esi
	movl	8(%rbx), %edx
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_pr_debug
LBB0_7:
	movl	$1, 8(%rbx)
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movl	4(%r14), %edi
	leal	(%rdi,%r15), %eax
	movq	_MAX_DMA_ADDRESS@GOTPCREL(%rip), %rcx
	cmpq	%rax, (%rcx)
	jbe	LBB0_9
## %bb.8:
	cmpl	(%r14), %r15d
	je	LBB0_10
LBB0_9:
	movl	(%rbx), %esi
	movq	%r14, %rdi
	movl	%r15d, %edx
	callq	_skb_copy_from_linear_data
	movl	(%r14), %eax
	movl	(%rbx), %edi
	addl	%eax, %edi
	movl	%r15d, %edx
	subl	%eax, %edx
	xorl	%esi, %esi
	callq	_memset
	movl	(%rbx), %edi
LBB0_10:
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_isa_virt_to_bus
	movq	%rax, %r13
	movq	%r14, 16(%rbx)
	xorl	%eax, %eax
	callq	_claim_dma_lock
	movq	%rax, %r12
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movl	4(%r14), %edi
	callq	_disable_dma
	movl	4(%r14), %edi
	callq	_clear_dma_ff
	movl	4(%r14), %edi
	movl	$72, %esi
	callq	_set_dma_mode
	movl	4(%r14), %edi
	movq	%r13, %rsi
	callq	_set_dma_addr
	movl	4(%r14), %edi
	movl	%r15d, %esi
	callq	_set_dma_count
	movq	_DMAE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	orl	4(%rbx), %edi
	movq	_TCEN@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	movq	%r14, %rsi
	callq	_outb_control
	movl	4(%r14), %edi
	callq	_enable_dma
	movq	%r12, %rdi
	callq	_release_dma_lock
	movq	_elp_debug@GOTPCREL(%rip), %rax
	movl	$1, %ebx
	cmpl	$3, (%rax)
	jl	LBB0_13
## %bb.11:
	movl	(%r14), %esi
	leaq	L_.str.2(%rip), %rdi
LBB0_12:
	xorl	%eax, %eax
	callq	_pr_debug
	jmp	LBB0_13
LBB0_4:
	movq	$0, (%r12)
	xorl	%ebx, %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_elp_debug,4,2                  ## @elp_debug
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: transmit blocked\n"

	.comm	_CMD_TRANSMIT_PACKET,4,2        ## @CMD_TRANSMIT_PACKET
L_.str.1:                               ## @.str.1
	.asciz	"%s: tx: DMA %d in progress\n"

	.comm	_jiffies,4,2                    ## @jiffies
	.comm	_MAX_DMA_ADDRESS,8,3            ## @MAX_DMA_ADDRESS
	.comm	_DMAE,4,2                       ## @DMAE
	.comm	_TCEN,4,2                       ## @TCEN
L_.str.2:                               ## @.str.2
	.asciz	"%s: DMA transfer started\n"

	.no_dead_strip	_send_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function send_packet
_send_packet:                           ; @send_packet
	.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	x22, x1
	mov	x19, x0
	bl	_netdev_priv
	mov	x20, x0
	ldr	w8, [x22]
	add	w9, w8, #1
	and	w9, w9, #0xfffffffe
	mov	w10, #60
	cmp	w8, #60
	csel	w21, w10, w9, lt
	add	x23, x0, #40
	mov	w0, #0
	mov	x1, x23
	bl	_test_and_set_bit
	cbz	x0, LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _elp_debug@GOTPAGE
Lloh1:
	ldr	x8, [x8, _elp_debug@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, #2
	b.lt	LBB0_12
; %bb.2:
	ldr	w1, [x19]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_debug
	mov	w0, #0
	b	LBB0_14
LBB0_3:
	ldr	w8, [x19, #8]
	add	w8, w8, w21
	str	w8, [x19, #8]
Lloh5:
	adrp	x8, _CMD_TRANSMIT_PACKET@GOTPAGE
Lloh6:
	ldr	x8, [x8, _CMD_TRANSMIT_PACKET@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	mov	w9, #4
	mov	x1, x20
	str	w9, [x1, #48]!
	str	w8, [x1, #32]
	stp	xzr, xzr, [x1, #16]
	str	w21, [x1, #8]
	mov	x0, x19
	bl	_send_pcb
	cbz	w0, LBB0_13
; %bb.4:
	add	x1, x20, #32
	mov	w0, #0
	bl	_test_and_set_bit
	cbz	x0, LBB0_6
; %bb.5:
	ldr	w1, [x19]
	ldr	w8, [x20, #8]
	str	x8, [sp]
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_debug
LBB0_6:
	mov	w8, #1
	str	w8, [x20, #8]
Lloh10:
	adrp	x8, _jiffies@GOTPAGE
Lloh11:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	str	w8, [x20, #24]
	ldr	w0, [x22, #4]
Lloh13:
	adrp	x8, _MAX_DMA_ADDRESS@GOTPAGE
Lloh14:
	ldr	x8, [x8, _MAX_DMA_ADDRESS@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
	add	w9, w0, w21
	cmp	x8, x9
	b.ls	LBB0_8
; %bb.7:
	ldr	w8, [x22]
	cmp	w21, w8
	b.eq	LBB0_9
LBB0_8:
	ldr	w1, [x20]
	mov	x0, x22
	mov	x2, x21
	bl	_skb_copy_from_linear_data
	ldr	w8, [x20]
	ldr	w9, [x22]
	add	w0, w9, w8
	sub	w2, w21, w9
	mov	w1, #0
	bl	_memset
	ldr	w0, [x20]
LBB0_9:
	bl	_isa_virt_to_bus
	mov	x23, x0
	str	x22, [x20, #16]
	bl	_claim_dma_lock
	mov	x22, x0
	ldr	w0, [x19, #4]
	bl	_disable_dma
	ldr	w0, [x19, #4]
	bl	_clear_dma_ff
	ldr	w0, [x19, #4]
	mov	w1, #72
	bl	_set_dma_mode
	ldr	w0, [x19, #4]
	mov	x1, x23
	bl	_set_dma_addr
	ldr	w0, [x19, #4]
	mov	x1, x21
	bl	_set_dma_count
	ldr	w8, [x20, #4]
Lloh16:
	adrp	x9, _DMAE@GOTPAGE
Lloh17:
	ldr	x9, [x9, _DMAE@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh19:
	adrp	x9, _TCEN@GOTPAGE
Lloh20:
	ldr	x9, [x9, _TCEN@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	orr	w0, w8, w9
	mov	x1, x19
	bl	_outb_control
	ldr	w0, [x19, #4]
	bl	_enable_dma
	mov	x0, x22
	bl	_release_dma_lock
Lloh22:
	adrp	x8, _elp_debug@GOTPAGE
Lloh23:
	ldr	x8, [x8, _elp_debug@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	cmp	w8, #3
	b.lt	LBB0_11
; %bb.10:
	ldr	w1, [x19]
Lloh25:
	adrp	x0, l_.str.2@PAGE
Lloh26:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pr_debug
LBB0_11:
	mov	w0, #1
	b	LBB0_14
LBB0_12:
	mov	w0, #0
	b	LBB0_14
LBB0_13:
	str	xzr, [x23]
LBB0_14:
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_elp_debug,4,2                  ; @elp_debug
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: transmit blocked\n"

	.comm	_CMD_TRANSMIT_PACKET,4,2        ; @CMD_TRANSMIT_PACKET
l_.str.1:                               ; @.str.1
	.asciz	"%s: tx: DMA %d in progress\n"

	.comm	_jiffies,4,2                    ; @jiffies
	.comm	_MAX_DMA_ADDRESS,8,3            ; @MAX_DMA_ADDRESS
	.comm	_DMAE,4,2                       ; @DMAE
	.comm	_TCEN,4,2                       ; @TCEN
l_.str.2:                               ; @.str.2
	.asciz	"%s: DMA transfer started\n"

	.no_dead_strip	_send_packet
.subsections_via_symbols
