	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cr0014114_recount
_cr0014114_recount:                     ## @cr0014114_recount
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	8(%rdi), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_dbg
	movq	_CR_INIT_REENUMERATE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movl	12(%r14), %edi
	leaq	-44(%rbp), %rsi
	movl	$4, %edx
	callq	_spi_write
	movl	%eax, %r12d
	testl	%eax, %eax
	je	LBB0_1
LBB0_6:
	movl	8(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_dbg
	movl	8(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	movl	%r12d, %edx
	callq	_dev_err
	jmp	LBB0_7
LBB0_1:
	movq	_CR_NEXT_REENUMERATE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	cmpq	$0, (%r14)
	je	LBB0_8
## %bb.2:
	xorl	%ebx, %ebx
	movq	_CR_FW_DELAY_MSEC@GOTPCREL(%rip), %r13
	leaq	-44(%rbp), %r15
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %edi
	callq	_msleep
	movl	12(%r14), %edi
	movq	%r15, %rsi
	movl	$4, %edx
	callq	_spi_write
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_4 Depth=1
	incq	%rbx
	cmpq	(%r14), %rbx
	jb	LBB0_4
LBB0_8:
	movl	8(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_dbg
	xorl	%r12d, %r12d
LBB0_7:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movl	%eax, %r12d
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"LEDs recount is started\n"

	.comm	_CR_INIT_REENUMERATE,4,2        ## @CR_INIT_REENUMERATE
	.comm	_CR_NEXT_REENUMERATE,4,2        ## @CR_NEXT_REENUMERATE
	.comm	_CR_FW_DELAY_MSEC,4,2           ## @CR_FW_DELAY_MSEC
L_.str.1:                               ## @.str.1
	.asciz	"LEDs recount is finished\n"

L_.str.2:                               ## @.str.2
	.asciz	"with error %d"

	.no_dead_strip	_cr0014114_recount
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cr0014114_recount
_cr0014114_recount:                     ; @cr0014114_recount
	.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, x0
	ldr	w0, [x0, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
Lloh2:
	adrp	x8, _CR_INIT_REENUMERATE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CR_INIT_REENUMERATE@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	ldr	w0, [x19, #12]
	add	x1, sp, #12
	mov	w2, #4
	bl	_spi_write
	mov	x20, x0
	cbz	w0, LBB0_2
LBB0_1:
	ldr	w0, [x19, #8]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_dbg
	ldr	w0, [x19, #8]
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	b	LBB0_7
LBB0_2:
Lloh9:
	adrp	x8, _CR_NEXT_REENUMERATE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _CR_NEXT_REENUMERATE@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	ldr	x8, [x19]
	cbz	x8, LBB0_6
; %bb.3:
	mov	x21, #0
Lloh12:
	adrp	x22, _CR_FW_DELAY_MSEC@GOTPAGE
Lloh13:
	ldr	x22, [x22, _CR_FW_DELAY_MSEC@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x22]
	bl	_msleep
	ldr	w0, [x19, #12]
	add	x1, sp, #12
	mov	w2, #4
	bl	_spi_write
	cbnz	w0, LBB0_8
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	x21, x21, #1
	ldr	x8, [x19]
	cmp	x21, x8
	b.lo	LBB0_4
LBB0_6:
	ldr	w0, [x19, #8]
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_dbg
	mov	w20, #0
LBB0_7:
	mov	x0, x20
	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_8:
	mov	x20, x0
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"LEDs recount is started\n"

	.comm	_CR_INIT_REENUMERATE,4,2        ; @CR_INIT_REENUMERATE
	.comm	_CR_NEXT_REENUMERATE,4,2        ; @CR_NEXT_REENUMERATE
	.comm	_CR_FW_DELAY_MSEC,4,2           ; @CR_FW_DELAY_MSEC
l_.str.1:                               ; @.str.1
	.asciz	"LEDs recount is finished\n"

l_.str.2:                               ; @.str.2
	.asciz	"with error %d"

	.no_dead_strip	_cr0014114_recount
.subsections_via_symbols
