	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pvrdma_cmd_recv
_pvrdma_cmd_recv:                       ## @pvrdma_cmd_recv
	.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
	movl	%edx, %r14d
	movq	%rsi, %r15
	movq	%rdi, %r12
	movq	(%rdi), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_dbg
	leaq	16(%r12), %rbx
	movq	_PVRDMA_CMD_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_msecs_to_jiffies
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_wait_for_completion_interruptible_timeout
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rcx
	addl	(%rcx), %eax
	jne	LBB0_3
LBB0_2:
	movq	(%r12), %rdi
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_warn
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
LBB0_5:
	subl	(%rax), %ebx
LBB0_6:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	leaq	8(%r12), %rbx
	movq	%rbx, %rdi
	callq	_spin_lock
	movl	12(%r12), %esi
	movq	%r15, %rdi
	movl	$4, %edx
	callq	_memcpy
	movq	%rbx, %rdi
	callq	_spin_unlock
	movl	(%r15), %edx
	xorl	%ebx, %ebx
	cmpl	%r14d, %edx
	je	LBB0_6
## %bb.4:
	movq	(%r12), %rdi
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	movl	%r14d, %ecx
	xorl	%eax, %eax
	callq	_dev_warn
	movq	_EFAULT@GOTPCREL(%rip), %rax
	jmp	LBB0_5
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"receive response from device\n"

	.comm	_PVRDMA_CMD_TIMEOUT,4,2         ## @PVRDMA_CMD_TIMEOUT
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
L_.str.1:                               ## @.str.1
	.asciz	"completion timeout or interrupted\n"

	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
L_.str.2:                               ## @.str.2
	.asciz	"unknown response %#x expected %#x\n"

	.comm	_EFAULT,4,2                     ## @EFAULT
	.no_dead_strip	_pvrdma_cmd_recv
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pvrdma_cmd_recv
_pvrdma_cmd_recv:                       ; @pvrdma_cmd_recv
	.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, x2
	mov	x21, x1
	mov	x20, x0
	mov	x22, x0
	ldr	x0, [x22], #16
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
Lloh2:
	adrp	x8, _PVRDMA_CMD_TIMEOUT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _PVRDMA_CMD_TIMEOUT@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	bl	_msecs_to_jiffies
	mov	x1, x0
	mov	x0, x22
	bl	_wait_for_completion_interruptible_timeout
	cbz	w0, LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	cmn	w0, w8
	b.ne	LBB0_5
LBB0_2:
	ldr	x0, [x20]
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_warn
Lloh10:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
LBB0_3:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	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
	ret
LBB0_5:
	add	x22, x20, #8
	mov	x0, x22
	bl	_spin_lock
	ldr	w1, [x20, #12]
	mov	x0, x21
	mov	w2, #4
	bl	_memcpy
	mov	x0, x22
	bl	_spin_unlock
	ldr	w8, [x21]
	cmp	w8, w19
	b.ne	LBB0_7
; %bb.6:
	mov	w0, #0
	b	LBB0_4
LBB0_7:
	ldr	x0, [x20]
	stp	x8, x19, [sp]
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_warn
Lloh14:
	adrp	x8, _EFAULT@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"receive response from device\n"

	.comm	_PVRDMA_CMD_TIMEOUT,4,2         ; @PVRDMA_CMD_TIMEOUT
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
l_.str.1:                               ; @.str.1
	.asciz	"completion timeout or interrupted\n"

	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
l_.str.2:                               ; @.str.2
	.asciz	"unknown response %#x expected %#x\n"

	.comm	_EFAULT,4,2                     ; @EFAULT
	.no_dead_strip	_pvrdma_cmd_recv
.subsections_via_symbols
