	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mbox_send_message              ## -- Begin function mbox_send_message
	.p2align	4, 0x90
_mbox_send_message:                     ## @mbox_send_message
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.1:
	movq	%rdi, %rbx
	cmpq	$0, 8(%rdi)
	je	LBB0_2
## %bb.3:
	movq	%rbx, %rdi
	callq	_add_to_rbuf
	movl	%eax, %r14d
	testl	%eax, %eax
	js	LBB0_4
## %bb.5:
	movq	%rbx, %rdi
	callq	_msg_submit
	movq	8(%rbx), %rax
	cmpq	$0, 8(%rax)
	je	LBB0_8
## %bb.6:
	movl	(%rax), %eax
	testl	%eax, %eax
	movl	$3600000, %edi                  ## imm = 0x36EE80
	cmovnel	%eax, %edi
	callq	_msecs_to_jiffies
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	_wait_for_completion_timeout
	testl	%eax, %eax
	jne	LBB0_8
## %bb.7:
	movq	_ETIME@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_tx_tick
	jmp	LBB0_8
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_8:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_4:
	movq	16(%rbx), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Try increasing MBOX_TX_QUEUE_LEN\n"

	.comm	_ETIME,4,2                      ## @ETIME
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mbox_send_message              ; -- Begin function mbox_send_message
	.p2align	2
_mbox_send_message:                     ; @mbox_send_message
	.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
	cbz	x0, LBB0_6
; %bb.1:
	mov	x20, x0
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_6
; %bb.2:
	mov	x0, x20
	bl	_add_to_rbuf
	mov	x19, x0
	tbnz	w0, #31, LBB0_8
; %bb.3:
	mov	x0, x20
	bl	_msg_submit
	ldr	x8, [x20, #8]
	ldr	x9, [x8, #8]
	cbz	x9, LBB0_7
; %bb.4:
	ldr	w8, [x8]
	mov	w9, #61056
	movk	w9, #54, lsl #16
	cmp	w8, #0
	csel	w0, w9, w8, eq
	bl	_msecs_to_jiffies
	mov	x1, x0
	mov	x0, x20
	bl	_wait_for_completion_timeout
	cbnz	w0, LBB0_7
; %bb.5:
Lloh0:
	adrp	x8, _ETIME@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ETIME@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w19, w8
	mov	x0, x20
	mov	x1, x19
	bl	_tx_tick
	b	LBB0_7
LBB0_6:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w19, w8
LBB0_7:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_8:
	ldr	x8, [x20, #16]
	ldr	w0, [x8]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Try increasing MBOX_TX_QUEUE_LEN\n"

	.comm	_ETIME,4,2                      ; @ETIME
.subsections_via_symbols
