	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __ena_com_submit_admin_cmd
___ena_com_submit_admin_cmd:            ## @__ena_com_submit_admin_cmd
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, %rbx
	movq	(%rdi), %r15
	decq	%r15
	movq	16(%rdi), %r13
	andq	%r15, %r13
	addq	$48, %rdi
	callq	_atomic_read
	cmpq	(%rbx), %rax
	jge	LBB0_1
## %bb.2:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	_ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	24(%rbx), %eax
	movq	8(%rbx), %rsi
	orl	%eax, (%r12)
	movq	_ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	andq	%rsi, %rax
	orq	%rax, 8(%r12)
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_get_comp_ctxt
	movq	%rax, %r14
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_5
## %bb.3:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_pr_debug
	incl	44(%rbx)
	movq	_ENOSPC@GOTPCREL(%rip), %rax
LBB0_4:
	xorl	%edi, %edi
	subl	(%rax), %edi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_5:
	movq	_ENA_CMD_SUBMITTED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%r14)
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, 16(%r14)
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, 8(%r14)
	movl	16(%r12), %eax
	movl	%eax, 4(%r14)
	movq	%r14, %rdi
	callq	_reinit_completion
	shlq	$2, %r13
	addq	32(%rbx), %r13
	movq	%r13, %rdi
	movq	%r12, %rsi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	_memcpy
	movq	8(%rbx), %rax
	movq	16(%rbx), %rcx
	incq	%rax
	andq	%r15, %rax
	movq	%rax, 8(%rbx)
	incq	%rcx
	movq	%rcx, 16(%rbx)
	incl	40(%rbx)
	xorl	%edi, %edi
	testq	%r15, %rcx
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	xorl	%eax, %eax
	cmpl	$0, 24(%rbx)
	sete	%al
	movl	%eax, 24(%rbx)
LBB0_7:
	movq	16(%rbx), %rdi
	movl	28(%rbx), %esi
	callq	_writel
	movq	%r14, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"admin queue is full.\n"

	.comm	_ENOSPC,4,2                     ## @ENOSPC
	.comm	_ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK,4,2 ## @ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK
	.comm	_ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK,8,3 ## @ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENA_CMD_SUBMITTED,4,2          ## @ENA_CMD_SUBMITTED
	.no_dead_strip	___ena_com_submit_admin_cmd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __ena_com_submit_admin_cmd
___ena_com_submit_admin_cmd:            ; @__ena_com_submit_admin_cmd
	.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	x24, x4
	mov	x23, x3
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	ldr	x25, [x0]
	ldr	x26, [x0, #16]
	add	x0, x0, #48
	bl	_atomic_read
	ldr	x8, [x19]
	cmp	x0, x8
	b.ge	LBB0_3
; %bb.1:
	ldr	x1, [x19, #8]
	ldr	w8, [x19, #24]
Lloh0:
	adrp	x9, _ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	and	w8, w9, w8
	ldr	w9, [x21]
	orr	w8, w9, w8
Lloh3:
	adrp	x9, _ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK@GOTPAGEOFF]
	str	w8, [x21]
Lloh5:
	ldr	x8, [x9]
	and	x8, x8, x1
	ldr	x9, [x21, #8]
	orr	x8, x9, x8
	str	x8, [x21, #8]
	mov	x0, x19
	mov	w2, #1
	bl	_get_comp_ctxt
	mov	x22, x0
	cmp	x0, #0
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_5
; %bb.2:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_debug
	ldr	w8, [x19, #44]
	add	w8, w8, #1
	str	w8, [x19, #44]
Lloh10:
	adrp	x8, _ENOSPC@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOSPC@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w0, w8
	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
	b	_ERR_PTR
LBB0_5:
	sub	x25, x25, #1
	and	x26, x26, x25
Lloh12:
	adrp	x8, _ENA_CMD_SUBMITTED@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENA_CMD_SUBMITTED@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	str	w8, [x22, #24]
	stp	x23, x24, [x22, #8]
	ldr	w8, [x21, #16]
	str	w8, [x22, #4]
	mov	x0, x22
	bl	_reinit_completion
	ldr	x8, [x19, #32]
	add	x0, x8, x26, lsl #2
	mov	x1, x21
	mov	x2, x20
	bl	_memcpy
	ldp	x8, x9, [x19, #8]
	add	x8, x8, #1
	and	x8, x8, x25
	add	x9, x9, #1
	stp	x8, x9, [x19, #8]
	ldr	w8, [x19, #40]
	add	w8, w8, #1
	str	w8, [x19, #40]
	tst	x9, x25
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_7
; %bb.6:
	ldr	w8, [x19, #24]
	cmp	w8, #0
	cset	w8, eq
	str	w8, [x19, #24]
LBB0_7:
	ldr	x0, [x19, #16]
	ldr	w1, [x19, #28]
	bl	_writel
	mov	x0, x22
	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	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"admin queue is full.\n"

	.comm	_ENOSPC,4,2                     ; @ENOSPC
	.comm	_ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK,4,2 ; @ENA_ADMIN_AQ_COMMON_DESC_PHASE_MASK
	.comm	_ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK,8,3 ; @ENA_ADMIN_AQ_COMMON_DESC_COMMAND_ID_MASK
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENA_CMD_SUBMITTED,4,2          ; @ENA_CMD_SUBMITTED
	.no_dead_strip	___ena_com_submit_admin_cmd
.subsections_via_symbols
