	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ci_ll_reset
_ci_ll_reset:                           ## @ci_ll_reset
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movl	%edx, %r12d
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movaps	l___const.ci_ll_reset.msg+16(%rip), %xmm0
	movaps	%xmm0, -64(%rbp)
	movaps	l___const.ci_ll_reset.msg(%rip), %xmm0
	movaps	%xmm0, -80(%rbp)
	movl	%edx, %ebx
	andl	$1, %ebx
	leal	(,%rbx,8), %eax
	testb	$2, %r12b
	leal	8(,%rbx,8), %r13d
	cmovel	%eax, %r13d
	callq	_dvb_ringbuffer_free
	cmpl	%r13d, %eax
	jge	LBB0_1
## %bb.7:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_5
LBB0_1:
	testl	%ebx, %ebx
	je	LBB0_3
## %bb.2:
	movl	$0, -72(%rbp)
	leaq	-80(%rbp), %rsi
	movq	%r15, %rdi
	movl	$8, %edx
	callq	_dvb_ringbuffer_write
	movq	$0, (%r14)
LBB0_3:
	xorl	%ebx, %ebx
	testb	$2, %r12b
	je	LBB0_5
## %bb.4:
	movl	$1, -72(%rbp)
	leaq	-80(%rbp), %rsi
	movq	%r15, %rdi
	movl	$8, %edx
	callq	_dvb_ringbuffer_write
	movq	$0, 8(%r14)
LBB0_5:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_8
## %bb.6:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__const
	.p2align	4                               ## @__const.ci_ll_reset.msg
l___const.ci_ll_reset.msg:
	.long	0                               ## 0x0
	.long	6                               ## 0x6
	.long	0                               ## 0x0
	.long	0                               ## 0x0
	.long	255                             ## 0xff
	.long	2                               ## 0x2
	.long	0                               ## 0x0
	.long	0                               ## 0x0

	.comm	_EBUSY,4,2                      ## @EBUSY
	.no_dead_strip	_ci_ll_reset
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ci_ll_reset
_ci_ll_reset:                           ; @ci_ll_reset
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x3
	mov	x21, x2
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
Lloh3:
	adrp	x8, l___const.ci_ll_reset.msg@PAGE
Lloh4:
	add	x8, x8, l___const.ci_ll_reset.msg@PAGEOFF
	ldp	q0, q1, [x8]
	stp	q0, q1, [sp]
	and	w22, w2, #0x1
	lsl	w8, w22, #3
	add	w9, w8, #8
	tst	w2, #0x2
	csel	w23, w8, w9, eq
	bl	_dvb_ringbuffer_free
	cmp	w0, w23
	b.ge	LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, _EBUSY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_7
LBB0_2:
	cbz	w22, LBB0_4
; %bb.3:
	str	wzr, [sp, #8]
	mov	x1, sp
	mov	x0, x20
	mov	w2, #8
	bl	_dvb_ringbuffer_write
	str	xzr, [x19]
LBB0_4:
	tbnz	w21, #1, LBB0_6
; %bb.5:
	mov	w0, #0
	b	LBB0_7
LBB0_6:
	mov	w8, #1
	str	w8, [sp, #8]
	mov	x1, sp
	mov	x0, x20
	mov	w2, #8
	bl	_dvb_ringbuffer_write
	mov	w0, #0
	str	xzr, [x19, #8]
LBB0_7:
	ldr	x8, [sp, #40]
Lloh8:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh9:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_9
; %bb.8:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_9:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__const
	.p2align	2                               ; @__const.ci_ll_reset.msg
l___const.ci_ll_reset.msg:
	.long	0                               ; 0x0
	.long	6                               ; 0x6
	.long	0                               ; 0x0
	.long	0                               ; 0x0
	.long	255                             ; 0xff
	.long	2                               ; 0x2
	.long	0                               ; 0x0
	.long	0                               ; 0x0

	.comm	_EBUSY,4,2                      ; @EBUSY
	.no_dead_strip	_ci_ll_reset
.subsections_via_symbols
