	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qed_mcp_cmd_init               ## -- Begin function qed_mcp_cmd_init
	.p2align	4, 0x90
_qed_mcp_cmd_init:                      ## @qed_mcp_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movl	$32, %edi
	callq	_kzalloc
	movq	%rax, (%r14)
	testq	%rax, %rax
	je	LBB0_5
## %bb.1:
	movq	%rax, %rbx
	leaq	28(%rax), %rdi
	callq	_spin_lock_init
	leaq	24(%rbx), %rdi
	callq	_spin_lock_init
	leaq	20(%rbx), %rdi
	callq	_INIT_LIST_HEAD
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_qed_load_mcp_offsets
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_DP_NOTICE
	xorl	%eax, %eax
	jmp	LBB0_6
LBB0_3:
	movl	16(%rbx), %edi
	callq	_MFW_DRV_MSG_MAX_DWORDS
                                        ## kill: def $eax killed $eax def $rax
	leal	(,%rax,4), %r15d
	movl	(%r12), %esi
	movl	%r15d, %edi
	callq	_kzalloc
	movq	%rax, 8(%rbx)
	movl	(%r12), %esi
	movl	%r15d, %edi
	callq	_kzalloc
	movq	%rax, (%rbx)
	cmpq	$0, 8(%rbx)
	je	LBB0_5
## %bb.4:
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	jne	LBB0_6
LBB0_5:
	movq	%r14, %rdi
	callq	_qed_mcp_free
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_6:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"MCP is not initialized\n"

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

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qed_mcp_cmd_init               ; -- Begin function qed_mcp_cmd_init
	.p2align	2
_qed_mcp_cmd_init:                      ; @qed_mcp_cmd_init
	.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	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x22, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x22, [x22, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	w0, #32
	bl	_kzalloc
	str	x0, [x19]
	cbz	x0, LBB0_4
; %bb.1:
	mov	x20, x0
	add	x0, x0, #28
	bl	_spin_lock_init
	add	x0, x20, #24
	bl	_spin_lock_init
	add	x0, x20, #20
	bl	_INIT_LIST_HEAD
	mov	x0, x19
	mov	x1, x21
	bl	_qed_load_mcp_offsets
	cbz	x0, LBB0_3
; %bb.2:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_DP_NOTICE
	b	LBB0_5
LBB0_3:
	ldr	w0, [x20, #16]
	bl	_MFW_DRV_MSG_MAX_DWORDS
	lsl	w21, w0, #2
	ldr	w1, [x22]
	mov	x0, x21
	bl	_kzalloc
	str	x0, [x20, #8]
	ldr	w1, [x22]
	mov	x0, x21
	bl	_kzalloc
	str	x0, [x20]
	ldr	x8, [x20, #8]
	cmp	x8, #0
	ccmp	x0, #0, #4, ne
	b.ne	LBB0_5
LBB0_4:
	mov	x0, x19
	bl	_qed_mcp_free
Lloh4:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_6
LBB0_5:
	mov	w0, #0
LBB0_6:
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"MCP is not initialized\n"

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