	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ice_init_ctrlq
_ice_init_ctrlq:                        ## @ice_init_ctrlq
	.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
	movl	%esi, %ebx
	movq	%rdi, %r14
	cmpl	$128, %esi
	je	LBB0_3
## %bb.1:
	cmpl	$129, %ebx
	jne	LBB0_12
## %bb.2:
	movq	%r14, %rdi
	callq	_ice_adminq_init_regs
	leaq	24(%r14), %r15
	jmp	LBB0_4
LBB0_3:
	movq	%r14, %rdi
	callq	_ice_mailbox_init_regs
	movq	%r14, %r15
LBB0_4:
	movl	%ebx, (%r15)
	cmpl	$0, 20(%r15)
	je	LBB0_11
## %bb.5:
	cmpl	$0, 16(%r15)
	je	LBB0_11
## %bb.6:
	cmpl	$0, 12(%r15)
	je	LBB0_11
## %bb.7:
	cmpl	$0, 8(%r15)
	je	LBB0_11
## %bb.8:
	movq	_ICE_CTL_Q_SQ_CMD_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%r15)
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_ice_init_sq
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_14
## %bb.9:
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_ice_init_rq
	testl	%eax, %eax
	je	LBB0_15
## %bb.10:
	movl	%eax, %ebx
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_ice_shutdown_sq
	jmp	LBB0_14
LBB0_11:
	movq	_ICE_ERR_CFG@GOTPCREL(%rip), %rax
	jmp	LBB0_13
LBB0_12:
	movq	_ICE_ERR_PARAM@GOTPCREL(%rip), %rax
LBB0_13:
	movl	(%rax), %ebx
LBB0_14:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	xorl	%ebx, %ebx
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_ICE_ERR_PARAM,4,2              ## @ICE_ERR_PARAM
	.comm	_ICE_ERR_CFG,4,2                ## @ICE_ERR_CFG
	.comm	_ICE_CTL_Q_SQ_CMD_TIMEOUT,4,2   ## @ICE_CTL_Q_SQ_CMD_TIMEOUT
	.no_dead_strip	_ice_init_ctrlq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ice_init_ctrlq
_ice_init_ctrlq:                        ; @ice_init_ctrlq
	.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
	cmp	w1, #128
	b.eq	LBB0_3
; %bb.1:
	cmp	w21, #129
	b.ne	LBB0_12
; %bb.2:
	mov	x0, x19
	bl	_ice_adminq_init_regs
	add	x20, x19, #24
	b	LBB0_4
LBB0_3:
	mov	x0, x19
	bl	_ice_mailbox_init_regs
	mov	x20, x19
LBB0_4:
	str	w21, [x20]
	ldr	w8, [x20, #20]
	cbz	w8, LBB0_11
; %bb.5:
	ldr	w8, [x20, #16]
	cbz	w8, LBB0_11
; %bb.6:
	ldr	w8, [x20, #12]
	cbz	w8, LBB0_11
; %bb.7:
	ldr	w8, [x20, #8]
	cbz	w8, LBB0_11
; %bb.8:
Lloh0:
	adrp	x8, _ICE_CTL_Q_SQ_CMD_TIMEOUT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ICE_CTL_Q_SQ_CMD_TIMEOUT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x20, #4]
	mov	x0, x19
	mov	x1, x20
	bl	_ice_init_sq
	mov	x21, x0
	cbnz	w0, LBB0_14
; %bb.9:
	mov	x0, x19
	mov	x1, x20
	bl	_ice_init_rq
	mov	x21, x0
	cbz	w0, LBB0_14
; %bb.10:
	mov	x0, x19
	mov	x1, x20
	bl	_ice_shutdown_sq
	b	LBB0_14
LBB0_11:
Lloh3:
	adrp	x8, _ICE_ERR_CFG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ICE_ERR_CFG@GOTPAGEOFF]
	b	LBB0_13
LBB0_12:
Lloh5:
	adrp	x8, _ICE_ERR_PARAM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ICE_ERR_PARAM@GOTPAGEOFF]
LBB0_13:
	ldr	w21, [x8]
LBB0_14:
	mov	x0, x21
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_ICE_ERR_PARAM,4,2              ; @ICE_ERR_PARAM
	.comm	_ICE_ERR_CFG,4,2                ; @ICE_ERR_CFG
	.comm	_ICE_CTL_Q_SQ_CMD_TIMEOUT,4,2   ; @ICE_CTL_Q_SQ_CMD_TIMEOUT
	.no_dead_strip	_ice_init_ctrlq
.subsections_via_symbols
