	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx5_fpga_conn_destroy         ## -- Begin function mlx5_fpga_conn_destroy
	.p2align	4, 0x90
_mlx5_fpga_conn_destroy:                ## @mlx5_fpga_conn_destroy
	.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	%rdi, %rbx
	movq	16(%rdi), %r14
	movq	(%r14), %r15
	movl	$0, (%rdi)
	addq	$32, %rdi
	callq	_tasklet_disable
	movl	28(%rbx), %edi
	callq	_synchronize_irq
	movq	16(%rbx), %rax
	movq	(%rax), %rdi
	movl	24(%rbx), %esi
	callq	_mlx5_fpga_destroy_qp
	movq	_MLX5_CMD_OP_2ERR_QP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	8(%rbx), %r8
	movq	%r15, %rdi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_mlx5_core_qp_modify
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %edx
	callq	_mlx5_fpga_warn
LBB0_2:
	movq	%rbx, %rdi
	callq	_mlx5_fpga_conn_destroy_qp
	movq	%rbx, %rdi
	callq	_mlx5_fpga_conn_destroy_cq
	movq	16(%rbx), %rax
	movq	(%rax), %rdi
	movl	4(%rbx), %esi
	movq	_MLX5_FPGA_PORT_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	subq	$8, %rsp
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	pushq	%rax
	pushq	$0
	pushq	$0
	callq	_mlx5_core_roce_gid_set
	addq	$32, %rsp
	movq	16(%rbx), %rax
	movq	(%rax), %rdi
	movl	4(%rbx), %esi
	callq	_mlx5_core_reserved_gid_free
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_kfree                          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MLX5_CMD_OP_2ERR_QP,4,2        ## @MLX5_CMD_OP_2ERR_QP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"qp_modify 2ERR failed: %d\n"

	.comm	_MLX5_FPGA_PORT_NUM,4,2         ## @MLX5_FPGA_PORT_NUM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx5_fpga_conn_destroy         ; -- Begin function mlx5_fpga_conn_destroy
	.p2align	2
_mlx5_fpga_conn_destroy:                ; @mlx5_fpga_conn_destroy
	.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
	ldr	x20, [x0, #16]
	ldr	x21, [x20]
	str	wzr, [x0], #32
	bl	_tasklet_disable
	ldr	w0, [x19, #28]
	bl	_synchronize_irq
	ldr	x8, [x19, #16]
	ldr	x0, [x8]
	ldr	w1, [x19, #24]
	bl	_mlx5_fpga_destroy_qp
Lloh0:
	adrp	x8, _MLX5_CMD_OP_2ERR_QP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MLX5_CMD_OP_2ERR_QP@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x4, x19, #8
	mov	x0, x21
	mov	w2, #0
	mov	x3, #0
	bl	_mlx5_core_qp_modify
	cbz	w0, LBB0_2
; %bb.1:
	mov	x2, x0
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_mlx5_fpga_warn
LBB0_2:
	mov	x0, x19
	bl	_mlx5_fpga_conn_destroy_qp
	mov	x0, x19
	bl	_mlx5_fpga_conn_destroy_cq
	ldr	x8, [x19, #16]
	ldr	x0, [x8]
	ldr	w1, [x19, #4]
Lloh5:
	adrp	x8, _MLX5_FPGA_PORT_NUM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MLX5_FPGA_PORT_NUM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	str	w8, [sp]
	mov	w2, #0
	mov	w3, #0
	mov	x4, #0
	mov	x5, #0
	mov	w6, #0
	mov	w7, #0
	bl	_mlx5_core_roce_gid_set
	ldr	x8, [x19, #16]
	ldr	x0, [x8]
	ldr	w1, [x19, #4]
	bl	_mlx5_core_reserved_gid_free
	mov	x0, x19
	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
	b	_kfree
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_MLX5_CMD_OP_2ERR_QP,4,2        ; @MLX5_CMD_OP_2ERR_QP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"qp_modify 2ERR failed: %d\n"

	.comm	_MLX5_FPGA_PORT_NUM,4,2         ; @MLX5_FPGA_PORT_NUM
.subsections_via_symbols
