	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ibmvmc_reset_crq_queue
_ibmvmc_reset_crq_queue:                ## @ibmvmc_reset_crq_queue
	.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
	movl	(%rdi), %edi
	callq	_to_vio_dev
	movq	%rax, %r14
	movl	(%rax), %edi
	callq	_h_free_crq
	movl	24(%rbx), %edi
	movq	_PAGE_SIZE@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	xorl	%esi, %esi
	callq	_memset
	movq	$0, 16(%rbx)
	movq	_H_REG_CRQ@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r14), %esi
	movl	8(%rbx), %edx
	movl	(%r15), %ecx
	callq	_plpar_hcall_norets
	movl	%eax, %r14d
	testl	%eax, %eax
	je	LBB0_4
## %bb.1:
	cmpl	$2, %r14d
	jne	LBB0_3
## %bb.2:
	movl	(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_warn
	jmp	LBB0_4
LBB0_3:
	movl	(%rbx), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edx
	callq	_dev_err
LBB0_4:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_H_REG_CRQ,4,2                  ## @H_REG_CRQ
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Partner adapter not ready\n"

L_.str.1:                               ## @.str.1
	.asciz	"couldn't register crq--rc 0x%x\n"

	.no_dead_strip	_ibmvmc_reset_crq_queue
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ibmvmc_reset_crq_queue
_ibmvmc_reset_crq_queue:                ; @ibmvmc_reset_crq_queue
	.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, x0
	ldr	w0, [x0]
	bl	_to_vio_dev
	mov	x20, x0
	ldr	w0, [x0]
	bl	_h_free_crq
	ldr	w0, [x19, #24]
Lloh0:
	adrp	x21, _PAGE_SIZE@GOTPAGE
Lloh1:
	ldr	x21, [x21, _PAGE_SIZE@GOTPAGEOFF]
	ldr	w2, [x21]
	mov	w1, #0
	bl	_memset
	str	xzr, [x19, #16]
Lloh2:
	adrp	x8, _H_REG_CRQ@GOTPAGE
Lloh3:
	ldr	x8, [x8, _H_REG_CRQ@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	ldr	w1, [x20]
	ldr	w2, [x19, #8]
	ldr	w3, [x21]
	bl	_plpar_hcall_norets
	mov	x20, x0
	cbz	w0, LBB0_4
; %bb.1:
	cmp	w20, #2
	b.ne	LBB0_3
; %bb.2:
	ldr	w0, [x19]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_warn
	b	LBB0_4
LBB0_3:
	ldr	w0, [x19]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x20
	bl	_dev_err
LBB0_4:
	mov	x0, x20
	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	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_H_REG_CRQ,4,2                  ; @H_REG_CRQ
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Partner adapter not ready\n"

l_.str.1:                               ; @.str.1
	.asciz	"couldn't register crq--rc 0x%x\n"

	.no_dead_strip	_ibmvmc_reset_crq_queue
.subsections_via_symbols
