	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function blink_set
_blink_set:                             ## @blink_set
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	(%rdi), %rax
	movl	(%rax), %edi
	callq	_to_platform_device
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_mfd_get_cell
	movq	%rax, %r13
	movl	(%rbx), %edi
	callq	_dev_get_drvdata
	movq	%rax, %r15
	movq	(%r12), %rdi
	movq	_MAX_MS@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	cmpq	%rcx, %rdi
	ja	LBB0_2
## %bb.1:
	movq	(%r14), %rax
	cmpq	%rcx, %rax
	ja	LBB0_2
## %bb.3:
	orq	%rdi, %rax
	jne	LBB0_5
## %bb.4:
	movl	$500, %edi                      ## imm = 0x1F4
	callq	_MS_TO_CLK
	movq	%rax, %rbx
	movl	$500, %edi                      ## imm = 0x1F4
	callq	_MS_TO_CLK
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	%rax, %rdx
	addq	%rbx, %rdx
	jmp	LBB0_7
LBB0_5:
	callq	_MS_TO_CLK
	movq	%rax, %rbx
	movq	(%r14), %rdi
	callq	_MS_TO_CLK
	leaq	(%rax,%rbx), %rdx
	movq	_MAX_CLK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rdx
	jle	LBB0_6
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_8:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
LBB0_7:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	_led_n_base@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%r13), %rcx
	movl	(%rax,%rcx,4), %r13d
	movq	_ASIC3_LED_PeriodTime@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	%r13, %rsi
	movq	%r15, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_asic3_write_register
	movq	_ASIC3_LED_DutyTime@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	%r13, %rsi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_asic3_write_register
	movq	_ASIC3_LED_AutoStopCount@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	%r13, %rsi
	xorl	%ebx, %ebx
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_asic3_write_register
	movq	_ASIC3_LED_TimeBase@GOTPCREL(%rip), %rax
	addq	(%rax), %r13
	movq	_LED_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	$4, %edx
	movq	%r15, %rdi
	movq	%r13, %rsi
	callq	_asic3_write_register
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_CLK_TO_MS
	movq	%rax, (%r12)
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_CLK_TO_MS
	movq	%rax, (%r14)
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_MS,8,3                     ## @MAX_MS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_MAX_CLK,8,3                    ## @MAX_CLK
	.comm	_led_n_base,8,3                 ## @led_n_base
	.comm	_ASIC3_LED_PeriodTime,8,3       ## @ASIC3_LED_PeriodTime
	.comm	_ASIC3_LED_DutyTime,8,3         ## @ASIC3_LED_DutyTime
	.comm	_ASIC3_LED_AutoStopCount,8,3    ## @ASIC3_LED_AutoStopCount
	.comm	_ASIC3_LED_TimeBase,8,3         ## @ASIC3_LED_TimeBase
	.comm	_LED_EN,4,2                     ## @LED_EN
	.no_dead_strip	_blink_set
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function blink_set
_blink_set:                             ; @blink_set
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x2
	mov	x20, x1
	ldr	x8, [x0]
	ldr	w0, [x8]
	bl	_to_platform_device
	mov	x21, x0
	bl	_mfd_get_cell
	mov	x24, x0
	ldr	w0, [x21]
	bl	_dev_get_drvdata
	mov	x21, x0
	ldr	x0, [x20]
Lloh0:
	adrp	x8, _MAX_MS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAX_MS@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x0, x8
	b.hi	LBB0_5
; %bb.1:
	ldr	x9, [x19]
	cmp	x9, x8
	b.hi	LBB0_5
; %bb.2:
	orr	x8, x0, x9
	cbnz	x8, LBB0_4
; %bb.3:
	mov	w0, #500
	bl	_MS_TO_CLK
	mov	x22, x0
	mov	w0, #500
	bl	_MS_TO_CLK
	mov	x23, x0
	add	x2, x0, x22
	b	LBB0_8
LBB0_4:
	bl	_MS_TO_CLK
	mov	x22, x0
	ldr	x0, [x19]
	bl	_MS_TO_CLK
Lloh3:
	adrp	x8, _MAX_CLK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_CLK@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	add	x2, x0, x22
	cmp	x2, x8
	b.le	LBB0_7
LBB0_5:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_6:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_7:
	mov	x23, x0
LBB0_8:
Lloh9:
	adrp	x8, _led_n_base@GOTPAGE
Lloh10:
	ldr	x8, [x8, _led_n_base@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	ldr	x9, [x24]
	ldr	w24, [x8, x9, lsl #2]
Lloh12:
	adrp	x8, _ASIC3_LED_PeriodTime@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ASIC3_LED_PeriodTime@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	add	x1, x8, x24
	mov	x0, x21
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_asic3_write_register
Lloh15:
	adrp	x8, _ASIC3_LED_DutyTime@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ASIC3_LED_DutyTime@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	add	x1, x8, x24
	mov	x0, x21
	mov	x2, x22
	bl	_asic3_write_register
Lloh18:
	adrp	x8, _ASIC3_LED_AutoStopCount@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ASIC3_LED_AutoStopCount@GOTPAGEOFF]
Lloh20:
	ldr	x8, [x8]
	add	x1, x8, x24
	mov	x0, x21
	mov	w2, #0
	bl	_asic3_write_register
Lloh21:
	adrp	x8, _ASIC3_LED_TimeBase@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ASIC3_LED_TimeBase@GOTPAGEOFF]
Lloh23:
	ldr	x8, [x8]
	add	x1, x8, x24
Lloh24:
	adrp	x8, _LED_EN@GOTPAGE
Lloh25:
	ldr	x8, [x8, _LED_EN@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	orr	w2, w8, #0x4
	mov	x0, x21
	bl	_asic3_write_register
	mov	x0, x22
	bl	_CLK_TO_MS
	str	x0, [x20]
	mov	x0, x23
	bl	_CLK_TO_MS
	mov	x8, x0
	mov	w0, #0
	str	x8, [x19]
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_MS,8,3                     ; @MAX_MS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_MAX_CLK,8,3                    ; @MAX_CLK
	.comm	_led_n_base,8,3                 ; @led_n_base
	.comm	_ASIC3_LED_PeriodTime,8,3       ; @ASIC3_LED_PeriodTime
	.comm	_ASIC3_LED_DutyTime,8,3         ; @ASIC3_LED_DutyTime
	.comm	_ASIC3_LED_AutoStopCount,8,3    ; @ASIC3_LED_AutoStopCount
	.comm	_ASIC3_LED_TimeBase,8,3         ; @ASIC3_LED_TimeBase
	.comm	_LED_EN,4,2                     ; @LED_EN
	.no_dead_strip	_blink_set
.subsections_via_symbols
