	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cma_ib_init_qp_attr
_cma_ib_init_qp_attr:                   ## @cma_ib_init_qp_attr
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movl	16(%rdi), %esi
	movl	20(%rdi), %edi
	callq	_rdma_cap_eth_ah
	movl	$65535, %edx                    ## imm = 0xFFFF
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	24(%rbx), %rdi
	callq	_ib_addr_get_pkey
	movl	%eax, %edx
LBB0_2:
	movl	16(%rbx), %esi
	movl	20(%rbx), %edi
	leaq	16(%r15), %rcx
	callq	_ib_find_cached_pkey
	testl	%eax, %eax
	jne	LBB0_8
## %bb.3:
	movl	16(%rbx), %eax
	movl	%eax, 12(%r15)
	movq	_IB_QP_STATE@GOTPCREL(%rip), %rcx
	movq	_IB_QP_PKEY_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	(%rcx), %eax
	movq	_IB_QP_PORT@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, (%r14)
	movq	8(%rbx), %rcx
	movq	_IB_QPT_UD@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_6
## %bb.4:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_cma_set_qkey
	testl	%eax, %eax
	jne	LBB0_8
## %bb.5:
	movl	(%rbx), %eax
	movl	%eax, 8(%r15)
	movq	_IB_QP_QKEY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%r14, %rcx
	jmp	LBB0_7
LBB0_6:
	movq	$0, (%r15)
	movq	_IB_QP_ACCESS_FLAGS@GOTPCREL(%rip), %rcx
LBB0_7:
	orl	(%rcx), %eax
	movl	%eax, (%r14)
	xorl	%eax, %eax
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IB_QP_STATE,4,2                ## @IB_QP_STATE
	.comm	_IB_QP_PKEY_INDEX,4,2           ## @IB_QP_PKEY_INDEX
	.comm	_IB_QP_PORT,4,2                 ## @IB_QP_PORT
	.comm	_IB_QPT_UD,8,3                  ## @IB_QPT_UD
	.comm	_IB_QP_QKEY,4,2                 ## @IB_QP_QKEY
	.comm	_IB_QP_ACCESS_FLAGS,4,2         ## @IB_QP_ACCESS_FLAGS
	.no_dead_strip	_cma_ib_init_qp_attr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cma_ib_init_qp_attr
_cma_ib_init_qp_attr:                   ; @cma_ib_init_qp_attr
	.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	w0, [x0, #20]
	ldr	w1, [x21, #16]
	bl	_rdma_cap_eth_ah
	cbz	x0, LBB0_2
; %bb.1:
	mov	w2, #65535
	b	LBB0_3
LBB0_2:
	add	x0, x21, #24
	bl	_ib_addr_get_pkey
	mov	x2, x0
LBB0_3:
	ldp	w1, w0, [x21, #16]
	add	x3, x20, #16
	bl	_ib_find_cached_pkey
	cbnz	w0, LBB0_9
; %bb.4:
	ldr	w8, [x21, #16]
	str	w8, [x20, #12]
Lloh0:
	adrp	x8, _IB_QP_STATE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IB_QP_STATE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _IB_QP_PKEY_INDEX@GOTPAGE
Lloh4:
	ldr	x9, [x9, _IB_QP_PKEY_INDEX@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh6:
	adrp	x9, _IB_QP_PORT@GOTPAGE
Lloh7:
	ldr	x9, [x9, _IB_QP_PORT@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w8, w8, w9
	str	w8, [x19]
	ldr	x9, [x21, #8]
Lloh9:
	adrp	x10, _IB_QPT_UD@GOTPAGE
Lloh10:
	ldr	x10, [x10, _IB_QPT_UD@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_7
; %bb.5:
	mov	x0, x21
	mov	w1, #0
	bl	_cma_set_qkey
	cbnz	w0, LBB0_9
; %bb.6:
	ldr	w8, [x21]
	str	w8, [x20, #8]
Lloh12:
	adrp	x8, _IB_QP_QKEY@GOTPAGE
Lloh13:
	ldr	x8, [x8, _IB_QP_QKEY@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	mov	x9, x19
	b	LBB0_8
LBB0_7:
	str	xzr, [x20]
Lloh15:
	adrp	x9, _IB_QP_ACCESS_FLAGS@GOTPAGE
Lloh16:
	ldr	x9, [x9, _IB_QP_ACCESS_FLAGS@GOTPAGEOFF]
LBB0_8:
	mov	w0, #0
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x19]
LBB0_9:
	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	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_IB_QP_STATE,4,2                ; @IB_QP_STATE
	.comm	_IB_QP_PKEY_INDEX,4,2           ; @IB_QP_PKEY_INDEX
	.comm	_IB_QP_PORT,4,2                 ; @IB_QP_PORT
	.comm	_IB_QPT_UD,8,3                  ; @IB_QPT_UD
	.comm	_IB_QP_QKEY,4,2                 ; @IB_QP_QKEY
	.comm	_IB_QP_ACCESS_FLAGS,4,2         ; @IB_QP_ACCESS_FLAGS
	.no_dead_strip	_cma_ib_init_qp_attr
.subsections_via_symbols
