	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stm32f7_i2c_setup_timing
_stm32f7_i2c_setup_timing:              ## @stm32f7_i2c_setup_timing
	.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	%rsi, %r14
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movq	%rax, (%rsi)
	movq	_i2c_specs@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rcx,%rax,4), %eax
	movl	%eax, 40(%rsi)
	movl	16(%rdi), %edi
	callq	_clk_get_rate
	movl	%eax, 36(%r14)
	testl	%eax, %eax
	je	LBB0_5
## %bb.1:
	leaq	12(%rbx), %r12
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movq	%r12, %rdx
	callq	_stm32f7_i2c_compute_timing
	testl	%eax, %eax
	je	LBB0_8
## %bb.2:
	movl	%eax, %r15d
	movl	8(%rbx), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_err
	movq	(%rbx), %rax
	movq	_STM32_I2C_SPEED_STANDARD@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rax
	jbe	LBB0_4
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	leaq	-1(%rax), %rcx
	movq	%rcx, (%rbx)
	movq	%rcx, (%r14)
	movq	_i2c_specs@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	-4(%rcx,%rax,4), %edx
	movl	%edx, 40(%r14)
	movl	8(%rbx), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_dev_warn
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movq	%r12, %rdx
	callq	_stm32f7_i2c_compute_timing
	testl	%eax, %eax
	je	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	%eax, %r15d
	movl	8(%rbx), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_err
	movq	(%rbx), %rax
	cmpq	(%r13), %rax
	ja	LBB0_7
LBB0_4:
	movl	8(%rbx), %edi
	leaq	L_.str.3(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_9
LBB0_5:
	movl	8(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_9
LBB0_8:
	movl	8(%rbx), %edi
	movq	(%r14), %rdx
	movl	40(%r14), %ecx
	movl	36(%r14), %r8d
	leaq	L_.str.4(%rip), %rsi
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	8(%rbx), %edi
	movq	8(%r14), %rdx
	movl	32(%r14), %ecx
	leaq	L_.str.5(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	8(%rbx), %edi
	cmpq	$0, 24(%r14)
	leaq	L_.str.8(%rip), %rax
	leaq	L_.str.7(%rip), %rdx
	cmoveq	%rax, %rdx
	movl	16(%r14), %ecx
	leaq	L_.str.6(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
LBB0_9:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_i2c_specs,8,3                  ## @i2c_specs
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"clock rate is 0\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"failed to compute I2C timings.\n"

	.comm	_STM32_I2C_SPEED_STANDARD,8,3   ## @STM32_I2C_SPEED_STANDARD
L_.str.2:                               ## @.str.2
	.asciz	"downgrade I2C Speed Freq to (%i)\n"

L_.str.3:                               ## @.str.3
	.asciz	"Impossible to compute I2C timings.\n"

L_.str.4:                               ## @.str.4
	.asciz	"I2C Speed(%i), Freq(%i), Clk Source(%i)\n"

L_.str.5:                               ## @.str.5
	.asciz	"I2C Rise(%i) and Fall(%i) Time\n"

L_.str.6:                               ## @.str.6
	.asciz	"I2C Analog Filter(%s), DNF(%i)\n"

L_.str.7:                               ## @.str.7
	.asciz	"On"

L_.str.8:                               ## @.str.8
	.asciz	"Off"

	.no_dead_strip	_stm32f7_i2c_setup_timing
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stm32f7_i2c_setup_timing
_stm32f7_i2c_setup_timing:              ; @stm32f7_i2c_setup_timing
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x1
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x25, _i2c_specs@GOTPAGE
Lloh1:
	ldr	x25, [x25, _i2c_specs@GOTPAGEOFF]
	str	x8, [x1]
	ldr	x9, [x25]
	ldr	w8, [x9, x8, lsl #2]
	str	w8, [x1, #40]
	ldr	w0, [x0, #16]
	bl	_clk_get_rate
	str	w0, [x20, #36]
	cbz	w0, LBB0_7
; %bb.1:
	add	x21, x19, #12
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_stm32f7_i2c_compute_timing
	cbz	w0, LBB0_8
; %bb.2:
	mov	x22, x0
	ldr	w0, [x19, #8]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_err
	ldr	x8, [x19]
Lloh4:
	adrp	x26, _STM32_I2C_SPEED_STANDARD@GOTPAGE
Lloh5:
	ldr	x26, [x26, _STM32_I2C_SPEED_STANDARD@GOTPAGEOFF]
	ldr	x9, [x26]
	cmp	x8, x9
	b.ls	LBB0_6
; %bb.3:
Lloh6:
	adrp	x23, l_.str.2@PAGE
Lloh7:
	add	x23, x23, l_.str.2@PAGEOFF
Lloh8:
	adrp	x24, l_.str.1@PAGE
Lloh9:
	add	x24, x24, l_.str.1@PAGEOFF
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	sub	x8, x8, #1
	str	x8, [x19]
	str	x8, [x20]
	ldr	x9, [x25]
	ldr	w2, [x9, x8, lsl #2]
	str	w2, [x20, #40]
	ldr	w0, [x19, #8]
	mov	x1, x23
	bl	_dev_warn
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_stm32f7_i2c_compute_timing
	cbz	w0, LBB0_8
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x22, x0
	ldr	w0, [x19, #8]
	mov	x1, x24
	bl	_dev_err
	ldr	x8, [x19]
	ldr	x9, [x26]
	cmp	x8, x9
	b.hi	LBB0_4
LBB0_6:
	ldr	w0, [x19, #8]
Lloh10:
	adrp	x1, l_.str.3@PAGE
Lloh11:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_err
	b	LBB0_9
LBB0_7:
	ldr	w0, [x19, #8]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_9
LBB0_8:
	ldr	w0, [x19, #8]
	ldr	x8, [x20]
	ldp	w10, w9, [x20, #36]
	stp	x9, x10, [sp, #8]
	str	x8, [sp]
Lloh17:
	adrp	x1, l_.str.4@PAGE
Lloh18:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_dev_dbg
	ldr	w0, [x19, #8]
	ldr	x8, [x20, #8]
	ldr	w9, [x20, #32]
	stp	x8, x9, [sp]
Lloh19:
	adrp	x1, l_.str.5@PAGE
Lloh20:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_dev_dbg
	ldr	w0, [x19, #8]
Lloh21:
	adrp	x8, l_.str.7@PAGE
Lloh22:
	add	x8, x8, l_.str.7@PAGEOFF
	ldr	x9, [x20, #24]
Lloh23:
	adrp	x10, l_.str.8@PAGE
Lloh24:
	add	x10, x10, l_.str.8@PAGEOFF
	cmp	x9, #0
	csel	x8, x10, x8, eq
	ldr	w9, [x20, #16]
	stp	x8, x9, [sp]
Lloh25:
	adrp	x1, l_.str.6@PAGE
Lloh26:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_dev_dbg
	mov	w22, #0
LBB0_9:
	mov	x0, x22
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_i2c_specs,8,3                  ; @i2c_specs
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"clock rate is 0\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"failed to compute I2C timings.\n"

	.comm	_STM32_I2C_SPEED_STANDARD,8,3   ; @STM32_I2C_SPEED_STANDARD
l_.str.2:                               ; @.str.2
	.asciz	"downgrade I2C Speed Freq to (%i)\n"

l_.str.3:                               ; @.str.3
	.asciz	"Impossible to compute I2C timings.\n"

l_.str.4:                               ; @.str.4
	.asciz	"I2C Speed(%i), Freq(%i), Clk Source(%i)\n"

l_.str.5:                               ; @.str.5
	.asciz	"I2C Rise(%i) and Fall(%i) Time\n"

l_.str.6:                               ; @.str.6
	.asciz	"I2C Analog Filter(%s), DNF(%i)\n"

l_.str.7:                               ; @.str.7
	.asciz	"On"

l_.str.8:                               ; @.str.8
	.asciz	"Off"

	.no_dead_strip	_stm32f7_i2c_setup_timing
.subsections_via_symbols
