	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx4_en_free_tx_buf            ## -- Begin function mlx4_en_free_tx_buf
	.p2align	4, 0x90
_mlx4_en_free_tx_buf:                   ## @mlx4_en_free_tx_buf
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	callq	_netdev_priv
	movq	%rax, %r14
	movl	(%rbx), %ecx
	addl	4(%rbx), %ecx
	movl	8(%rbx), %r8d
	movl	%ecx, (%rbx)
	movq	_DRV@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	leaq	L_.str(%rip), %rdx
	xorl	%r15d, %r15d
	movq	%rax, %rsi
	xorl	%eax, %eax
	callq	_en_dbg
	movl	(%rbx), %eax
	movl	8(%rbx), %ecx
	movl	%ecx, %edx
	subl	%eax, %edx
	movslq	%edx, %rdx
	cmpq	%rdx, 16(%rbx)
	jge	LBB0_1
## %bb.8:
	movq	%r14, %rdi
	callq	_netif_msg_tx_err
	xorl	%r15d, %r15d
	testq	%rax, %rax
	je	LBB0_11
## %bb.9:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_en_warn
	jmp	LBB0_11
LBB0_1:
	cmpl	%eax, %ecx
	je	LBB0_4
## %bb.2:
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	andl	32(%rbx), %eax
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	*24(%rbx)
	movl	%eax, 4(%rbx)
	addl	(%rbx), %eax
	movl	%eax, (%rbx)
	incl	%r15d
	cmpl	8(%rbx), %eax
	jne	LBB0_3
LBB0_4:
	movq	40(%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_6
## %bb.5:
	callq	_netdev_tx_reset_queue
LBB0_6:
	testl	%r15d, %r15d
	je	LBB0_7
## %bb.10:
	movl	(%r12), %edi
	leaq	L_.str.2(%rip), %rdx
	movq	%r14, %rsi
	movl	%r15d, %ecx
	xorl	%eax, %eax
	callq	_en_dbg
	jmp	LBB0_11
LBB0_7:
	xorl	%r15d, %r15d
LBB0_11:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DRV,4,2                        ## @DRV
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Freeing Tx buf - cons:0x%x prod:0x%x\n"

L_.str.1:                               ## @.str.1
	.asciz	"Tx consumer passed producer!\n"

L_.str.2:                               ## @.str.2
	.asciz	"Freed %d uncompleted tx descriptors\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx4_en_free_tx_buf            ; -- Begin function mlx4_en_free_tx_buf
	.p2align	2
_mlx4_en_free_tx_buf:                   ; @mlx4_en_free_tx_buf
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x20, x1
	bl	_netdev_priv
	mov	x19, x0
	ldp	w9, w8, [x20]
	add	w3, w9, w8
	str	w3, [x20]
Lloh0:
	adrp	x22, _DRV@GOTPAGE
Lloh1:
	ldr	x22, [x22, _DRV@GOTPAGEOFF]
	ldr	w0, [x22]
	ldr	w8, [x20, #8]
	str	x8, [sp]
Lloh2:
	adrp	x2, l_.str@PAGE
Lloh3:
	add	x2, x2, l_.str@PAGEOFF
	mov	x1, x19
	bl	_en_dbg
	ldr	w9, [x20, #8]
	ldr	w8, [x20]
	sub	w10, w9, w8
	ldr	x11, [x20, #16]
	cmp	x11, w10, sxtw
	b.ge	LBB0_4
; %bb.1:
	mov	x0, x19
	bl	_netif_msg_tx_err
	cbz	x0, LBB0_3
; %bb.2:
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_en_warn
LBB0_3:
	mov	w21, #0
	b	LBB0_12
LBB0_4:
	cmp	w9, w8
	b.ne	LBB0_6
; %bb.5:
	mov	w21, #0
	b	LBB0_8
LBB0_6:
	mov	w21, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x20, #24]
	ldr	w10, [x20, #32]
	and	w2, w10, w8
	mov	x0, x19
	mov	x1, x20
	mov	w3, #0
	mov	w4, #0
	blr	x9
	ldr	w8, [x20]
	ldr	w9, [x20, #8]
	add	w8, w8, w0
	cmp	w8, w9
	stp	w8, w0, [x20]
	add	w21, w21, #1
	b.ne	LBB0_7
LBB0_8:
	ldr	x0, [x20, #40]
	cbz	x0, LBB0_10
; %bb.9:
	bl	_netdev_tx_reset_queue
LBB0_10:
	cbz	w21, LBB0_12
; %bb.11:
	ldr	w0, [x22]
Lloh6:
	adrp	x2, l_.str.2@PAGE
Lloh7:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x1, x19
	mov	x3, x21
	bl	_en_dbg
LBB0_12:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_DRV,4,2                        ; @DRV
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Freeing Tx buf - cons:0x%x prod:0x%x\n"

l_.str.1:                               ; @.str.1
	.asciz	"Tx consumer passed producer!\n"

l_.str.2:                               ; @.str.2
	.asciz	"Freed %d uncompleted tx descriptors\n"

.subsections_via_symbols
