	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath5k_hw_set_tx_queueprops     ## -- Begin function ath5k_hw_set_tx_queueprops
	.p2align	4, 0x90
_ath5k_hw_set_tx_queueprops:            ## @ath5k_hw_set_tx_queueprops
	.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	%rdx, %r14
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movl	8(%rdi), %esi
	movl	%r15d, %edi
	callq	_AR5K_ASSERT_ENTRY
	movq	(%rbx), %r12
	movslq	%r15d, %rbx
	shlq	$6, %rbx
	movq	(%r12,%rbx), %rax
	movq	_AR5K_TX_QUEUE_INACTIVE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	_EIO@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_9
LBB0_2:
	leaq	(%r12,%rbx), %rax
	movups	(%r14), %xmm0
	movups	%xmm0, (%rax)
	movl	16(%r14), %eax
	movl	%eax, 16(%r12,%rbx)
	movl	56(%r14), %edi
	movl	$252, %esi
	callq	_min
	movl	%eax, 56(%r12,%rbx)
	movq	48(%r14), %rdi
	callq	_ath5k_cw_validate
	movq	%rax, 48(%r12,%rbx)
	movq	40(%r14), %rdi
	callq	_ath5k_cw_validate
	movq	%rax, 40(%r12,%rbx)
	movups	20(%r14), %xmm0
	movups	%xmm0, 20(%r12,%rbx)
	movq	(%r14), %rcx
	movq	_AR5K_TX_QUEUE_DATA@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jne	LBB0_6
## %bb.3:
	movq	8(%r14), %rax
	movq	_AR5K_WME_AC_VI@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_8
## %bb.4:
	movq	_AR5K_WME_AC_VO@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_8
## %bb.5:
	xorl	%eax, %eax
	movq	_AR5K_TX_QUEUE_UAPSD@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_9
	jmp	LBB0_8
LBB0_6:
	movq	_AR5K_TX_QUEUE_UAPSD@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	cmpq	(%rdx), %rcx
	jne	LBB0_9
LBB0_8:
	leaq	(%r12,%rbx), %rax
	addq	$16, %rax
	movq	_AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%ecx, (%rax)
	xorl	%eax, %eax
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AR5K_TX_QUEUE_INACTIVE,8,3     ## @AR5K_TX_QUEUE_INACTIVE
	.comm	_EIO,4,2                        ## @EIO
	.comm	_AR5K_TX_QUEUE_DATA,8,3         ## @AR5K_TX_QUEUE_DATA
	.comm	_AR5K_WME_AC_VI,8,3             ## @AR5K_WME_AC_VI
	.comm	_AR5K_WME_AC_VO,8,3             ## @AR5K_WME_AC_VO
	.comm	_AR5K_TX_QUEUE_UAPSD,8,3        ## @AR5K_TX_QUEUE_UAPSD
	.comm	_AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS,4,2 ## @AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath5k_hw_set_tx_queueprops     ; -- Begin function ath5k_hw_set_tx_queueprops
	.p2align	2
_ath5k_hw_set_tx_queueprops:            ; @ath5k_hw_set_tx_queueprops
	.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, x2
	mov	x20, x1
	mov	x21, x0
	ldr	w1, [x0, #8]
	mov	x0, x20
	bl	_AR5K_ASSERT_ENTRY
	ldr	x8, [x21]
	sxtw	x9, w20
	add	x20, x8, x9, lsl #6
	ldr	x8, [x20]
Lloh0:
	adrp	x9, _AR5K_TX_QUEUE_INACTIVE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AR5K_TX_QUEUE_INACTIVE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _EIO@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_8
LBB0_2:
	ldr	q0, [x19]
	str	q0, [x20]
	ldr	w8, [x19, #16]
	str	w8, [x20, #16]!
	ldr	w0, [x19, #56]
	mov	w1, #252
	bl	_min
	str	w0, [x20, #40]
	ldr	x0, [x19, #48]
	bl	_ath5k_cw_validate
	str	x0, [x20, #32]
	ldr	x0, [x19, #40]
	bl	_ath5k_cw_validate
	str	x0, [x20, #24]
	ldur	q0, [x19, #20]
	stur	q0, [x20, #4]
	ldr	x8, [x19]
Lloh6:
	adrp	x9, _AR5K_TX_QUEUE_DATA@GOTPAGE
Lloh7:
	ldr	x9, [x9, _AR5K_TX_QUEUE_DATA@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.3:
	ldr	x9, [x19, #8]
Lloh9:
	adrp	x10, _AR5K_WME_AC_VI@GOTPAGE
Lloh10:
	ldr	x10, [x10, _AR5K_WME_AC_VI@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	x9, x10
	b.eq	LBB0_7
; %bb.4:
Lloh12:
	adrp	x10, _AR5K_WME_AC_VO@GOTPAGE
Lloh13:
	ldr	x10, [x10, _AR5K_WME_AC_VO@GOTPAGEOFF]
Lloh14:
	ldr	x10, [x10]
	cmp	x9, x10
	b.eq	LBB0_7
LBB0_5:
Lloh15:
	adrp	x9, _AR5K_TX_QUEUE_UAPSD@GOTPAGE
Lloh16:
	ldr	x9, [x9, _AR5K_TX_QUEUE_UAPSD@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_7
; %bb.6:
	mov	w0, #0
	b	LBB0_8
LBB0_7:
	mov	w0, #0
Lloh18:
	adrp	x8, _AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	ldr	w9, [x20]
	orr	w8, w9, w8
	str	w8, [x20]
LBB0_8:
	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
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_AR5K_TX_QUEUE_INACTIVE,8,3     ; @AR5K_TX_QUEUE_INACTIVE
	.comm	_EIO,4,2                        ; @EIO
	.comm	_AR5K_TX_QUEUE_DATA,8,3         ; @AR5K_TX_QUEUE_DATA
	.comm	_AR5K_WME_AC_VI,8,3             ; @AR5K_WME_AC_VI
	.comm	_AR5K_WME_AC_VO,8,3             ; @AR5K_WME_AC_VO
	.comm	_AR5K_TX_QUEUE_UAPSD,8,3        ; @AR5K_TX_QUEUE_UAPSD
	.comm	_AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS,4,2 ; @AR5K_TXQ_FLAG_POST_FR_BKOFF_DIS
.subsections_via_symbols
