	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dwxgmac2_prepare_tx_desc
_dwxgmac2_prepare_tx_desc:              ## @dwxgmac2_prepare_tx_desc
	.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	%r9d, -44(%rbp)                 ## 4-byte Spill
	movl	%ecx, %r12d
	movl	%edx, %ebx
	movl	%esi, %r13d
	movq	%rdi, %r15
	movl	(%rdi), %edi
	callq	_le32_to_cpu
	movl	%eax, %r14d
	movq	_XGMAC_TDES2_B1L@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	movl	%ebx, %edi
	callq	_cpu_to_le32
	orl	%eax, 4(%r15)
	movq	_XGMAC_TDES3_FL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	andl	24(%rbp), %ecx
	orl	%r14d, %ecx
	movq	_XGMAC_TDES3_FD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, %edx
	orl	%ecx, %edx
	notl	%eax
	andl	%ecx, %eax
	testl	%r13d, %r13d
	cmovnel	%edx, %eax
	testl	%r12d, %r12d
	je	LBB0_2
## %bb.1:
	movq	_XGMAC_TDES3_CIC_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movl	$3, %r14d
	shll	%cl, %r14d
	orl	%eax, %r14d
	jmp	LBB0_3
LBB0_2:
	movq	_XGMAC_TDES3_CIC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%ecx, %eax
	movl	%eax, %r14d
LBB0_3:
	movl	16(%rbp), %ecx
	movq	_XGMAC_TDES3_LD@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_XGMAC_TDES3_OWN@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	testl	%r13d, %r13d
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	je	LBB0_6
## %bb.4:
	testl	%r13d, %r13d
	je	LBB0_6
## %bb.5:
	xorl	%eax, %eax
	callq	_dma_wmb
	movl	16(%rbp), %ecx
LBB0_6:
	movl	%ebx, %eax
	notl	%eax
	andl	%r14d, %eax
	orl	%r14d, %ebx
	testl	%ecx, %ecx
	cmovel	%eax, %ebx
	testl	%r13d, %r13d
	cmovel	%r13d, %r12d
	orl	%ebx, %r12d
	movl	%r12d, %edi
	callq	_cpu_to_le32
	movl	%eax, (%r15)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_XGMAC_TDES2_B1L,4,2            ## @XGMAC_TDES2_B1L
	.comm	_XGMAC_TDES3_FL,4,2             ## @XGMAC_TDES3_FL
	.comm	_XGMAC_TDES3_FD,4,2             ## @XGMAC_TDES3_FD
	.comm	_XGMAC_TDES3_CIC_SHIFT,4,2      ## @XGMAC_TDES3_CIC_SHIFT
	.comm	_XGMAC_TDES3_CIC,4,2            ## @XGMAC_TDES3_CIC
	.comm	_XGMAC_TDES3_LD,4,2             ## @XGMAC_TDES3_LD
	.comm	_XGMAC_TDES3_OWN,4,2            ## @XGMAC_TDES3_OWN
	.no_dead_strip	_dwxgmac2_prepare_tx_desc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dwxgmac2_prepare_tx_desc
_dwxgmac2_prepare_tx_desc:              ; @dwxgmac2_prepare_tx_desc
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x23, x7
	mov	x21, x6
	mov	x20, x5
	mov	x24, x3
	mov	x25, x2
	mov	x22, x1
	mov	x19, x0
	ldr	w0, [x0]
	bl	_le32_to_cpu
	mov	x26, x0
Lloh0:
	adrp	x8, _XGMAC_TDES2_B1L@GOTPAGE
Lloh1:
	ldr	x8, [x8, _XGMAC_TDES2_B1L@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	and	w0, w8, w25
	bl	_cpu_to_le32
	ldr	w8, [x19, #4]
	orr	w8, w8, w0
	str	w8, [x19, #4]
Lloh3:
	adrp	x8, _XGMAC_TDES3_FL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _XGMAC_TDES3_FL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	and	w8, w8, w23
Lloh6:
	adrp	x9, _XGMAC_TDES3_FD@GOTPAGE
Lloh7:
	ldr	x9, [x9, _XGMAC_TDES3_FD@GOTPAGEOFF]
	orr	w8, w8, w26
Lloh8:
	ldr	w9, [x9]
	orr	w10, w9, w8
	bic	w8, w8, w9
	cmp	w22, #0
	csel	w8, w10, w8, ne
	cbz	w24, LBB0_2
; %bb.1:
Lloh9:
	adrp	x9, _XGMAC_TDES3_CIC_SHIFT@GOTPAGE
Lloh10:
	ldr	x9, [x9, _XGMAC_TDES3_CIC_SHIFT@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	mov	w10, #3
	lsl	w9, w10, w9
	orr	w23, w9, w8
	b	LBB0_3
LBB0_2:
Lloh12:
	adrp	x9, _XGMAC_TDES3_CIC@GOTPAGE
Lloh13:
	ldr	x9, [x9, _XGMAC_TDES3_CIC@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	bic	w23, w8, w9
LBB0_3:
Lloh15:
	adrp	x8, _XGMAC_TDES3_LD@GOTPAGE
Lloh16:
	ldr	x8, [x8, _XGMAC_TDES3_LD@GOTPAGEOFF]
Lloh17:
	ldr	w25, [x8]
Lloh18:
	adrp	x8, _XGMAC_TDES3_OWN@GOTPAGE
Lloh19:
	ldr	x8, [x8, _XGMAC_TDES3_OWN@GOTPAGEOFF]
Lloh20:
	ldr	w24, [x8]
	cbz	w22, LBB0_6
; %bb.4:
	cbz	w20, LBB0_6
; %bb.5:
	bl	_dma_wmb
LBB0_6:
	bic	w8, w23, w25
	orr	w9, w25, w23
	cmp	w21, #0
	csel	w8, w8, w9, eq
	cmp	w20, #0
	csel	w9, w24, wzr, ne
	orr	w0, w9, w8
	bl	_cpu_to_le32
	str	w0, [x19]
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_XGMAC_TDES2_B1L,4,2            ; @XGMAC_TDES2_B1L
	.comm	_XGMAC_TDES3_FL,4,2             ; @XGMAC_TDES3_FL
	.comm	_XGMAC_TDES3_FD,4,2             ; @XGMAC_TDES3_FD
	.comm	_XGMAC_TDES3_CIC_SHIFT,4,2      ; @XGMAC_TDES3_CIC_SHIFT
	.comm	_XGMAC_TDES3_CIC,4,2            ; @XGMAC_TDES3_CIC
	.comm	_XGMAC_TDES3_LD,4,2             ; @XGMAC_TDES3_LD
	.comm	_XGMAC_TDES3_OWN,4,2            ; @XGMAC_TDES3_OWN
	.no_dead_strip	_dwxgmac2_prepare_tx_desc
.subsections_via_symbols
