	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qed_spq_alloc                  ## -- Begin function qed_spq_alloc
	.p2align	4, 0x90
_qed_spq_alloc:                         ## @qed_spq_alloc
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	$0, -36(%rbp)
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movl	$16, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	(%r14), %rdi
	movq	_QED_CHAIN_USE_TO_PRODUCE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_QED_CHAIN_MODE_SINGLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_QED_CHAIN_CNT_TYPE_U16@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%r15d, %r15d
	xorl	%r8d, %r8d
	movl	$4, %r9d
	pushq	$0
	pushq	%rbx
	callq	_qed_chain_alloc
	addq	$16, %rsp
	testq	%rax, %rax
	je	LBB0_3
LBB0_5:
	movq	(%r14), %rdi
	movq	%rbx, %rsi
	callq	_qed_chain_free
	movq	%rbx, %rdi
	callq	_kfree
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
LBB0_6:
	subl	(%rax), %r15d
LBB0_7:
	movl	%r15d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%rbx, %rdi
	callq	_qed_chain_get_capacity
                                        ## kill: def $eax killed $eax def $rax
	movq	(%r14), %rcx
	movq	(%rcx), %rdi
	leal	(,%rax,4), %esi
	movl	(%r12), %ecx
	leaq	-36(%rbp), %rdx
	callq	_dma_alloc_coherent
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	%rax, 8(%rbx)
	movl	-36(%rbp), %eax
	movl	%eax, 4(%rbx)
	movq	%rbx, 8(%r14)
	xorl	%r15d, %r15d
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_QED_CHAIN_USE_TO_PRODUCE,4,2   ## @QED_CHAIN_USE_TO_PRODUCE
	.comm	_QED_CHAIN_MODE_SINGLE,4,2      ## @QED_CHAIN_MODE_SINGLE
	.comm	_QED_CHAIN_CNT_TYPE_U16,4,2     ## @QED_CHAIN_CNT_TYPE_U16
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qed_spq_alloc                  ; -- Begin function qed_spq_alloc
	.p2align	2
_qed_spq_alloc:                         ; @qed_spq_alloc
	.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	x19, x0
	str	wzr, [sp, #12]
Lloh0:
	adrp	x21, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	w0, #16
	bl	_kzalloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	ldr	x0, [x19]
Lloh2:
	adrp	x8, _QED_CHAIN_USE_TO_PRODUCE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _QED_CHAIN_USE_TO_PRODUCE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x8, _QED_CHAIN_MODE_SINGLE@GOTPAGE
Lloh6:
	ldr	x8, [x8, _QED_CHAIN_MODE_SINGLE@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
Lloh8:
	adrp	x8, _QED_CHAIN_CNT_TYPE_U16@GOTPAGE
Lloh9:
	ldr	x8, [x8, _QED_CHAIN_CNT_TYPE_U16@GOTPAGEOFF]
Lloh10:
	ldr	w3, [x8]
	mov	w4, #0
	mov	w5, #4
	mov	x6, x20
	mov	x7, #0
	bl	_qed_chain_alloc
	cbz	x0, LBB0_5
LBB0_2:
	ldr	x0, [x19]
	mov	x1, x20
	bl	_qed_chain_free
	mov	x0, x20
	bl	_kfree
LBB0_3:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	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
LBB0_5:
	mov	x0, x20
	bl	_qed_chain_get_capacity
	ldr	x8, [x19]
	ldr	x8, [x8]
	lsl	w1, w0, #2
	ldr	w3, [x21]
	add	x2, sp, #12
	mov	x0, x8
	bl	_dma_alloc_coherent
	cbz	x0, LBB0_2
; %bb.6:
	mov	x8, x0
	mov	w0, #0
	str	x8, [x20, #8]
	ldr	w8, [sp, #12]
	str	w8, [x20, #4]
	str	x20, [x19, #8]
	b	LBB0_4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_QED_CHAIN_USE_TO_PRODUCE,4,2   ; @QED_CHAIN_USE_TO_PRODUCE
	.comm	_QED_CHAIN_MODE_SINGLE,4,2      ; @QED_CHAIN_MODE_SINGLE
	.comm	_QED_CHAIN_CNT_TYPE_U16,4,2     ; @QED_CHAIN_CNT_TYPE_U16
.subsections_via_symbols
