	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fimc_setup_clocks
_fimc_setup_clocks:                     ## @fimc_setup_clocks
	.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, %r12
	movq	_FIMC_CLKS_MAX@GOTPCREL(%rip), %r15
	cmpl	$0, (%r15)
	jle	LBB0_12
## %bb.1:
	movq	8(%r12), %r14
	xorl	%ebx, %ebx
	movq	_EINVAL@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%edi, %edi
	subl	(%r13), %edi
	callq	_ERR_PTR
	movq	(%r12), %rcx
	movl	%eax, (%rcx,%rbx,4)
	incq	%rbx
	movslq	(%r15), %rax
	cmpq	%rax, %rbx
	jl	LBB0_2
## %bb.3:
	testl	%eax, %eax
	jle	LBB0_12
## %bb.4:
	xorl	%ebx, %ebx
	movq	_FIMC_CLK_WB_A@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %eax
	cmpq	%rax, %rbx
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	_FIMC_CLK_WB_B@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%r14, %rdi
	cmpq	%rax, %rbx
	jne	LBB0_8
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	(%r14), %rdi
LBB0_8:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	_fimc_clock_names@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax,%rbx,4), %esi
	callq	_clk_get
	movq	(%r12), %rcx
	movl	%eax, (%rcx,%rbx,4)
	movl	%eax, %edi
	callq	_IS_ERR
	testq	%rax, %rax
	jne	LBB0_9
## %bb.11:                              ##   in Loop: Header=BB0_5 Depth=1
	incq	%rbx
	movslq	(%r15), %rax
	cmpq	%rax, %rbx
	jl	LBB0_5
LBB0_12:
	movq	(%r12), %rax
	movq	_FIMC_CLK_LCLK@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rax,%rcx,4), %edi
	callq	_clk_prepare_enable
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.13:
	xorl	%r15d, %r15d
	jmp	LBB0_14
LBB0_9:
	movq	(%r12), %rax
	movl	(%rax,%rbx,4), %edi
	callq	_PTR_ERR
	movl	%eax, %r15d
	movq	_fimc_clock_names@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax,%rbx,4), %edx
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_err
LBB0_10:
	movq	%r12, %rdi
	callq	_fimc_put_clocks
LBB0_14:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FIMC_CLKS_MAX,4,2              ## @FIMC_CLKS_MAX
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_FIMC_CLK_WB_A,4,2              ## @FIMC_CLK_WB_A
	.comm	_FIMC_CLK_WB_B,4,2              ## @FIMC_CLK_WB_B
	.comm	_fimc_clock_names,8,3           ## @fimc_clock_names
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to get clock: %s\n"

	.comm	_FIMC_CLK_LCLK,8,3              ## @FIMC_CLK_LCLK
	.no_dead_strip	_fimc_setup_clocks
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fimc_setup_clocks
_fimc_setup_clocks:                     ; @fimc_setup_clocks
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x0
Lloh0:
	adrp	x21, _FIMC_CLKS_MAX@GOTPAGE
Lloh1:
	ldr	x21, [x21, _FIMC_CLKS_MAX@GOTPAGEOFF]
	ldr	w8, [x21]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.1:
	mov	x22, #0
	ldr	x20, [x19, #8]
Lloh2:
	adrp	x23, _EINVAL@GOTPAGE
Lloh3:
	ldr	x23, [x23, _EINVAL@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x23]
	neg	w0, w8
	bl	_ERR_PTR
	ldr	x8, [x19]
	str	w0, [x8, x22, lsl #2]
	add	x22, x22, #1
	ldrsw	x8, [x21]
	cmp	x22, x8
	b.lt	LBB0_2
; %bb.3:
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.4:
	mov	x23, #0
Lloh4:
	adrp	x24, _FIMC_CLK_WB_A@GOTPAGE
Lloh5:
	ldr	x24, [x24, _FIMC_CLK_WB_A@GOTPAGEOFF]
Lloh6:
	adrp	x25, _FIMC_CLK_WB_B@GOTPAGE
Lloh7:
	ldr	x25, [x25, _FIMC_CLK_WB_B@GOTPAGEOFF]
Lloh8:
	adrp	x22, _fimc_clock_names@GOTPAGE
Lloh9:
	ldr	x22, [x22, _fimc_clock_names@GOTPAGEOFF]
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x24]
	ldr	w9, [x25]
	cmp	x23, x8
	ccmp	x23, x9, #4, ne
	mov	x0, x20
	b.ne	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x20]
LBB0_7:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x22]
	lsl	x26, x23, #2
	ldr	w1, [x8, x26]
	bl	_clk_get
	ldr	x8, [x19]
	str	w0, [x8, x26]
	bl	_IS_ERR
	cbnz	x0, LBB0_10
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x23, x23, #1
	ldrsw	x8, [x21]
	cmp	x23, x8
	b.lt	LBB0_5
LBB0_9:
	ldr	x8, [x19]
Lloh10:
	adrp	x9, _FIMC_CLK_LCLK@GOTPAGE
Lloh11:
	ldr	x9, [x9, _FIMC_CLK_LCLK@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	ldr	w0, [x8, x9, lsl #2]
	bl	_clk_prepare_enable
	mov	x21, x0
	cbnz	w0, LBB0_11
	b	LBB0_12
LBB0_10:
	ldr	x8, [x19]
	ldr	w0, [x8, x26]
	bl	_PTR_ERR
	mov	x21, x0
	ldr	x8, [x22]
	ldr	w2, [x8, x26]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_dev_err
LBB0_11:
	mov	x0, x19
	bl	_fimc_put_clocks
LBB0_12:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_FIMC_CLKS_MAX,4,2              ; @FIMC_CLKS_MAX
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_FIMC_CLK_WB_A,4,2              ; @FIMC_CLK_WB_A
	.comm	_FIMC_CLK_WB_B,4,2              ; @FIMC_CLK_WB_B
	.comm	_fimc_clock_names,8,3           ; @fimc_clock_names
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to get clock: %s\n"

	.comm	_FIMC_CLK_LCLK,8,3              ; @FIMC_CLK_LCLK
	.no_dead_strip	_fimc_setup_clocks
.subsections_via_symbols
