	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function xgbe_prepare_tx_stop
_xgbe_prepare_tx_stop:                  ## @xgbe_prepare_tx_stop
	.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
	movl	%esi, %r13d
	movq	%rdi, %r15
	movl	4(%rdi), %edi
	movq	_MAC_VR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_SNPSVER@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_XGMAC_GET_BITS
	cmpl	$33, %eax
	jl	LBB0_1
## %bb.11:
	movq	%r15, %rdi
	movl	%r13d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_xgbe_txq_prepare_tx_stop       ## TAILCALL
LBB0_1:
	movq	_DMA_DSRX_FIRST_QUEUE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	cmpl	%r13d, %ecx
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	jbe	LBB0_3
## %bb.2:
	movq	_DMA_DSR0@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	_DMA_DSR0_TPS_START@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_3:
	subl	%ecx, %r13d
	movq	_DMA_DSRX_QPR@GOTPCREL(%rip), %rcx
	movl	%r13d, %eax
	xorl	%edx, %edx
	divl	(%rcx)
	movl	%eax, %r12d
	movl	%edx, %r13d
	movq	_DMA_DSRX_INC@GOTPCREL(%rip), %rax
	imull	(%rax), %r12d
	movq	_DMA_DSR1@GOTPCREL(%rip), %rax
	addl	(%rax), %r12d
	movq	_DMA_DSRX_TPS_START@GOTPCREL(%rip), %rax
LBB0_4:
	movq	_DMA_DSR_Q_WIDTH@GOTPCREL(%rip), %rcx
	imull	(%rcx), %r13d
	addl	(%rax), %r13d
	movq	_jiffies@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	_XGBE_DMA_STOP_TIMEOUT@GOTPCREL(%rip), %rax
	movq	_HZ@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rbx
	imulq	(%rax), %rbx
	addq	%rdi, %rbx
	movq	%rbx, %rsi
	callq	_time_before
	testq	%rax, %rax
	je	LBB0_9
## %bb.5:
	movq	_DMA_TPS_SUSPENDED@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	movl	%r12d, %esi
	callq	_XGMAC_IOREAD
	movq	_DMA_DSR_TPS_WIDTH@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%eax, %edi
	movl	%r13d, %esi
	callq	_GET_BITS
	movq	_DMA_TPS_STOPPED@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	cmpl	(%r14), %eax
	je	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	$500, %edi                      ## imm = 0x1F4
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_usleep_range
	movq	_jiffies@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	%rbx, %rsi
	callq	_time_before
	testq	%rax, %rax
	jne	LBB0_6
LBB0_9:
	movq	_jiffies@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	%rbx, %rsi
	callq	_time_before
	testq	%rax, %rax
	je	LBB0_12
## %bb.10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_netdev_info                    ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MAC_VR,4,2                     ## @MAC_VR
	.comm	_SNPSVER,4,2                    ## @SNPSVER
	.comm	_DMA_DSRX_FIRST_QUEUE,4,2       ## @DMA_DSRX_FIRST_QUEUE
	.comm	_DMA_DSR0,4,2                   ## @DMA_DSR0
	.comm	_DMA_DSR_Q_WIDTH,4,2            ## @DMA_DSR_Q_WIDTH
	.comm	_DMA_DSR0_TPS_START,4,2         ## @DMA_DSR0_TPS_START
	.comm	_DMA_DSR1,4,2                   ## @DMA_DSR1
	.comm	_DMA_DSRX_QPR,4,2               ## @DMA_DSRX_QPR
	.comm	_DMA_DSRX_INC,4,2               ## @DMA_DSRX_INC
	.comm	_DMA_DSRX_TPS_START,4,2         ## @DMA_DSRX_TPS_START
	.comm	_jiffies,8,3                    ## @jiffies
	.comm	_XGBE_DMA_STOP_TIMEOUT,8,3      ## @XGBE_DMA_STOP_TIMEOUT
	.comm	_HZ,8,3                         ## @HZ
	.comm	_DMA_DSR_TPS_WIDTH,4,2          ## @DMA_DSR_TPS_WIDTH
	.comm	_DMA_TPS_STOPPED,4,2            ## @DMA_TPS_STOPPED
	.comm	_DMA_TPS_SUSPENDED,4,2          ## @DMA_TPS_SUSPENDED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"timed out waiting for Tx DMA channel %u to stop\n"

	.no_dead_strip	_xgbe_prepare_tx_stop
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function xgbe_prepare_tx_stop
_xgbe_prepare_tx_stop:                  ; @xgbe_prepare_tx_stop
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x1
	mov	x20, x0
	ldr	w0, [x0, #4]
Lloh0:
	adrp	x8, _MAC_VR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAC_VR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _SNPSVER@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SNPSVER@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	bl	_XGMAC_GET_BITS
	cmp	w0, #33
	b.lt	LBB0_2
; %bb.1:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_xgbe_txq_prepare_tx_stop
LBB0_2:
Lloh6:
	adrp	x8, _DMA_DSRX_FIRST_QUEUE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DMA_DSRX_FIRST_QUEUE@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ls	LBB0_4
; %bb.3:
Lloh9:
	adrp	x8, _DMA_DSR0@GOTPAGE
Lloh10:
	ldr	x8, [x8, _DMA_DSR0@GOTPAGEOFF]
Lloh11:
	ldr	w21, [x8]
Lloh12:
	adrp	x8, _DMA_DSR0_TPS_START@GOTPAGE
Lloh13:
	ldr	x8, [x8, _DMA_DSR0_TPS_START@GOTPAGEOFF]
	mov	x23, x19
	b	LBB0_5
LBB0_4:
	sub	w8, w19, w8
Lloh14:
	adrp	x9, _DMA_DSR1@GOTPAGE
Lloh15:
	ldr	x9, [x9, _DMA_DSR1@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
Lloh17:
	adrp	x10, _DMA_DSRX_QPR@GOTPAGE
Lloh18:
	ldr	x10, [x10, _DMA_DSRX_QPR@GOTPAGEOFF]
Lloh19:
	ldr	w10, [x10]
Lloh20:
	adrp	x11, _DMA_DSRX_INC@GOTPAGE
Lloh21:
	ldr	x11, [x11, _DMA_DSRX_INC@GOTPAGEOFF]
	udiv	w12, w8, w10
Lloh22:
	ldr	w11, [x11]
	madd	w21, w11, w12, w9
	msub	w23, w12, w10, w8
Lloh23:
	adrp	x8, _DMA_DSRX_TPS_START@GOTPAGE
Lloh24:
	ldr	x8, [x8, _DMA_DSRX_TPS_START@GOTPAGEOFF]
LBB0_5:
Lloh25:
	adrp	x9, _DMA_DSR_Q_WIDTH@GOTPAGE
Lloh26:
	ldr	x9, [x9, _DMA_DSR_Q_WIDTH@GOTPAGEOFF]
Lloh27:
	ldr	w25, [x9]
	ldr	w26, [x8]
Lloh28:
	adrp	x24, _jiffies@GOTPAGE
Lloh29:
	ldr	x24, [x24, _jiffies@GOTPAGEOFF]
Lloh30:
	adrp	x8, _XGBE_DMA_STOP_TIMEOUT@GOTPAGE
Lloh31:
	ldr	x8, [x8, _XGBE_DMA_STOP_TIMEOUT@GOTPAGEOFF]
	ldr	x0, [x24]
Lloh32:
	ldr	x8, [x8]
Lloh33:
	adrp	x9, _HZ@GOTPAGE
Lloh34:
	ldr	x9, [x9, _HZ@GOTPAGEOFF]
Lloh35:
	ldr	x9, [x9]
	madd	x22, x9, x8, x0
	mov	x1, x22
	bl	_time_before
	cbz	x0, LBB0_9
; %bb.6:
	madd	w23, w25, w23, w26
Lloh36:
	adrp	x25, _DMA_DSR_TPS_WIDTH@GOTPAGE
Lloh37:
	ldr	x25, [x25, _DMA_DSR_TPS_WIDTH@GOTPAGEOFF]
Lloh38:
	adrp	x26, _DMA_TPS_STOPPED@GOTPAGE
Lloh39:
	ldr	x26, [x26, _DMA_TPS_STOPPED@GOTPAGEOFF]
Lloh40:
	adrp	x27, _DMA_TPS_SUSPENDED@GOTPAGE
Lloh41:
	ldr	x27, [x27, _DMA_TPS_SUSPENDED@GOTPAGEOFF]
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x21
	bl	_XGMAC_IOREAD
	ldr	w2, [x25]
	mov	x1, x23
	bl	_GET_BITS
	ldr	w8, [x26]
	ldr	w9, [x27]
	cmp	w0, w8
	ccmp	w0, w9, #4, ne
	b.eq	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	w0, #500
	mov	w1, #1000
	bl	_usleep_range
	ldr	x0, [x24]
	mov	x1, x22
	bl	_time_before
	cbnz	x0, LBB0_7
LBB0_9:
	ldr	x0, [x24]
	mov	x1, x22
	bl	_time_before
	cbz	x0, LBB0_11
; %bb.10:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_11:
	ldr	w0, [x20]
Lloh42:
	adrp	x1, l_.str@PAGE
Lloh43:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_netdev_info
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpAdd	Lloh42, Lloh43
	.cfi_endproc
                                        ; -- End function
	.comm	_MAC_VR,4,2                     ; @MAC_VR
	.comm	_SNPSVER,4,2                    ; @SNPSVER
	.comm	_DMA_DSRX_FIRST_QUEUE,4,2       ; @DMA_DSRX_FIRST_QUEUE
	.comm	_DMA_DSR0,4,2                   ; @DMA_DSR0
	.comm	_DMA_DSR_Q_WIDTH,4,2            ; @DMA_DSR_Q_WIDTH
	.comm	_DMA_DSR0_TPS_START,4,2         ; @DMA_DSR0_TPS_START
	.comm	_DMA_DSR1,4,2                   ; @DMA_DSR1
	.comm	_DMA_DSRX_QPR,4,2               ; @DMA_DSRX_QPR
	.comm	_DMA_DSRX_INC,4,2               ; @DMA_DSRX_INC
	.comm	_DMA_DSRX_TPS_START,4,2         ; @DMA_DSRX_TPS_START
	.comm	_jiffies,8,3                    ; @jiffies
	.comm	_XGBE_DMA_STOP_TIMEOUT,8,3      ; @XGBE_DMA_STOP_TIMEOUT
	.comm	_HZ,8,3                         ; @HZ
	.comm	_DMA_DSR_TPS_WIDTH,4,2          ; @DMA_DSR_TPS_WIDTH
	.comm	_DMA_TPS_STOPPED,4,2            ; @DMA_TPS_STOPPED
	.comm	_DMA_TPS_SUSPENDED,4,2          ; @DMA_TPS_SUSPENDED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"timed out waiting for Tx DMA channel %u to stop\n"

	.no_dead_strip	_xgbe_prepare_tx_stop
.subsections_via_symbols
