	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hns_roce_cmd_init              ## -- Begin function hns_roce_cmd_init
	.p2align	4, 0x90
_hns_roce_cmd_init:                     ## @hns_roce_cmd_init
	.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	24(%rdi), %r14
	addq	$20, %rdi
	callq	_mutex_init
	leaq	16(%rbx), %rdi
	movl	$1, %esi
	callq	_sema_init
	movq	$0, 8(%rbx)
	movq	_CMD_MAX_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	movq	_HNS_ROCE_MAILBOX_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str(%rip), %rdi
	xorl	%r15d, %r15d
	movq	%r14, %rsi
	movl	%ecx, %edx
	xorl	%r8d, %r8d
	callq	_dma_pool_create
	movl	%eax, (%rbx)
	movq	_ENOMEM@GOTPCREL(%rip), %rdx
	xorl	%ecx, %ecx
	subl	(%rdx), %ecx
	testl	%eax, %eax
	cmovnel	%r15d, %ecx
	movl	%ecx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CMD_MAX_NUM,4,2                ## @CMD_MAX_NUM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"hns_roce_cmd"

	.comm	_HNS_ROCE_MAILBOX_SIZE,4,2      ## @HNS_ROCE_MAILBOX_SIZE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hns_roce_cmd_init              ; -- Begin function hns_roce_cmd_init
	.p2align	2
_hns_roce_cmd_init:                     ; @hns_roce_cmd_init
	.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, x0
	ldr	x20, [x0, #24]
	add	x0, x0, #20
	bl	_mutex_init
	add	x0, x19, #16
	mov	w1, #1
	bl	_sema_init
Lloh0:
	adrp	x8, _CMD_MAX_NUM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CMD_MAX_NUM@GOTPAGEOFF]
	str	xzr, [x19, #8]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x19, #4]
Lloh3:
	adrp	x8, _HNS_ROCE_MAILBOX_SIZE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _HNS_ROCE_MAILBOX_SIZE@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x20
	mov	x3, x2
	mov	w4, #0
	bl	_dma_pool_create
	str	w0, [x19]
Lloh8:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	cmp	w0, #0
	csneg	w0, wzr, w8, ne
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_CMD_MAX_NUM,4,2                ; @CMD_MAX_NUM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"hns_roce_cmd"

	.comm	_HNS_ROCE_MAILBOX_SIZE,4,2      ; @HNS_ROCE_MAILBOX_SIZE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
.subsections_via_symbols
