	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ehca_mmap_cq
_ehca_mmap_cq:                          ## @ehca_mmap_cq
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	cmpl	$1, %edx
	je	LBB0_4
## %bb.1:
	testl	%edx, %edx
	jne	LBB0_7
## %bb.2:
	movl	(%rbx), %edx
	movl	4(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_ehca_dbg
	leaq	20(%rbx), %rsi
	leaq	16(%rbx), %rdx
	movq	%r14, %rdi
	callq	_ehca_mmap_fw
	movl	%eax, %r14d
	movl	%eax, %edi
	callq	_unlikely
	testl	%eax, %eax
	je	LBB0_9
## %bb.3:
	movl	(%rbx), %ecx
	movl	4(%rbx), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_6
LBB0_4:
	movl	(%rbx), %edx
	movl	4(%rbx), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_ehca_dbg
	leaq	12(%rbx), %rsi
	leaq	8(%rbx), %rdx
	movq	%r14, %rdi
	callq	_ehca_mmap_queue
	movl	%eax, %r14d
	movl	%eax, %edi
	callq	_unlikely
	testl	%eax, %eax
	je	LBB0_9
## %bb.5:
	movl	(%rbx), %ecx
	movl	4(%rbx), %edi
	leaq	L_.str.3(%rip), %rsi
LBB0_6:
	movl	%r14d, %edx
	callq	_ehca_err
	jmp	LBB0_10
LBB0_7:
	movl	(%rbx), %ecx
	movl	4(%rbx), %edi
	leaq	L_.str.4(%rip), %rsi
	callq	_ehca_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_10
LBB0_9:
	xorl	%r14d, %r14d
LBB0_10:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cq_num=%x fw"

L_.str.1:                               ## @.str.1
	.asciz	"ehca_mmap_fw() failed rc=%i cq_num=%x"

L_.str.2:                               ## @.str.2
	.asciz	"cq_num=%x queue"

L_.str.3:                               ## @.str.3
	.asciz	"ehca_mmap_queue() failed rc=%i cq_num=%x"

L_.str.4:                               ## @.str.4
	.asciz	"bad resource type=%x cq_num=%x"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_ehca_mmap_cq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ehca_mmap_cq
_ehca_mmap_cq:                          ; @ehca_mmap_cq
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	mov	x20, x0
	cmp	w2, #1
	b.eq	LBB0_4
; %bb.1:
	cbnz	w2, LBB0_7
; %bb.2:
	ldp	w2, w0, [x19]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_ehca_dbg
	add	x1, x19, #20
	add	x2, x19, #16
	mov	x0, x20
	bl	_ehca_mmap_fw
	mov	x20, x0
	bl	_unlikely
	cbz	w0, LBB0_8
; %bb.3:
	ldp	w3, w0, [x19]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_6
LBB0_4:
	ldp	w2, w0, [x19]
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_ehca_dbg
	add	x1, x19, #12
	add	x2, x19, #8
	mov	x0, x20
	bl	_ehca_mmap_queue
	mov	x20, x0
	bl	_unlikely
	cbz	w0, LBB0_8
; %bb.5:
	ldp	w3, w0, [x19]
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
LBB0_6:
	mov	x2, x20
	bl	_ehca_err
	b	LBB0_9
LBB0_7:
	ldp	w3, w0, [x19]
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_ehca_err
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_9
LBB0_8:
	mov	w20, #0
LBB0_9:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cq_num=%x fw"

l_.str.1:                               ; @.str.1
	.asciz	"ehca_mmap_fw() failed rc=%i cq_num=%x"

l_.str.2:                               ; @.str.2
	.asciz	"cq_num=%x queue"

l_.str.3:                               ; @.str.3
	.asciz	"ehca_mmap_queue() failed rc=%i cq_num=%x"

l_.str.4:                               ; @.str.4
	.asciz	"bad resource type=%x cq_num=%x"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_ehca_mmap_cq
.subsections_via_symbols
