	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fwnet_write_complete
_fwnet_write_complete:                  ## @fwnet_write_complete
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%r8, %r14
	movq	_RCODE_COMPLETE@GOTPCREL(%rip), %rax
	cmpl	%esi, (%rax)
	jne	LBB0_1
## %bb.6:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_fwnet_transmit_packet_done     ## TAILCALL
LBB0_1:
	movl	%esi, %ebx
	leaq	_fwnet_write_complete.j(%rip), %rdi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_printk_timed_ratelimit
	testq	%rax, %rax
	jne	LBB0_3
## %bb.2:
	cmpl	%ebx, _fwnet_write_complete.last_rcode(%rip)
	jne	LBB0_3
## %bb.4:
	incl	_fwnet_write_complete.errors_skipped(%rip)
	jmp	LBB0_5
LBB0_3:
	movq	(%r14), %rax
	movq	(%rax), %rdi
	movl	_fwnet_write_complete.errors_skipped(%rip), %ecx
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	callq	_dev_err
	movl	$0, _fwnet_write_complete.errors_skipped(%rip)
	movl	%ebx, _fwnet_write_complete.last_rcode(%rip)
LBB0_5:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_fwnet_transmit_packet_failed   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_fwnet_write_complete.j,8,3 ## @fwnet_write_complete.j
.zerofill __DATA,__bss,_fwnet_write_complete.last_rcode,4,2 ## @fwnet_write_complete.last_rcode
.zerofill __DATA,__bss,_fwnet_write_complete.errors_skipped,4,2 ## @fwnet_write_complete.errors_skipped
	.comm	_RCODE_COMPLETE,4,2             ## @RCODE_COMPLETE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fwnet_write_complete failed: %x (skipped %d)\n"

	.no_dead_strip	_fwnet_write_complete
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fwnet_write_complete
_fwnet_write_complete:                  ; @fwnet_write_complete
	.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, x4
Lloh0:
	adrp	x8, _RCODE_COMPLETE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RCODE_COMPLETE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w1
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x19
	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
	b	_fwnet_transmit_packet_done
LBB0_2:
	mov	x20, x1
Lloh3:
	adrp	x0, _fwnet_write_complete.j@PAGE
Lloh4:
	add	x0, x0, _fwnet_write_complete.j@PAGEOFF
	mov	w1, #1000
	bl	_printk_timed_ratelimit
	adrp	x21, _fwnet_write_complete.last_rcode@PAGE
	cbnz	x0, LBB0_5
; %bb.3:
	ldr	w8, [x21, _fwnet_write_complete.last_rcode@PAGEOFF]
	cmp	w8, w20
	b.ne	LBB0_5
; %bb.4:
	adrp	x8, _fwnet_write_complete.errors_skipped@PAGE
	ldr	w9, [x8, _fwnet_write_complete.errors_skipped@PAGEOFF]
	add	w9, w9, #1
	str	w9, [x8, _fwnet_write_complete.errors_skipped@PAGEOFF]
	b	LBB0_6
LBB0_5:
	ldr	x8, [x19]
	ldr	x0, [x8]
	adrp	x22, _fwnet_write_complete.errors_skipped@PAGE
	ldr	w3, [x22, _fwnet_write_complete.errors_skipped@PAGEOFF]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	str	wzr, [x22, _fwnet_write_complete.errors_skipped@PAGEOFF]
	str	w20, [x21, _fwnet_write_complete.last_rcode@PAGEOFF]
LBB0_6:
	mov	x0, x19
	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
	b	_fwnet_transmit_packet_failed
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_fwnet_write_complete.j,8,3 ; @fwnet_write_complete.j
.zerofill __DATA,__bss,_fwnet_write_complete.last_rcode,4,2 ; @fwnet_write_complete.last_rcode
.zerofill __DATA,__bss,_fwnet_write_complete.errors_skipped,4,2 ; @fwnet_write_complete.errors_skipped
	.comm	_RCODE_COMPLETE,4,2             ; @RCODE_COMPLETE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fwnet_write_complete failed: %x (skipped %d)\n"

	.no_dead_strip	_fwnet_write_complete
.subsections_via_symbols
