	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dc_i2c_init_hw
_dc_i2c_init_hw:                        ## @dc_i2c_init_hw
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movl	20(%rdi), %edi
	callq	_clk_get_rate
	movq	%rax, %r15
	movq	_II_CONTROL_LOCAL_RESET@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_II_CONTROL@GOTPCREL(%rip), %r14
	movq	(%r14), %rsi
	addq	8(%rbx), %rsi
	callq	_writeb_relaxed
	movl	$100, %edi
	callq	_udelay
	movq	(%r14), %rsi
	addq	8(%rbx), %rsi
	xorl	%r14d, %r14d
	xorl	%edi, %edi
	callq	_writeb_relaxed
	movl	$100, %edi
	callq	_udelay
	movl	(%rbx), %esi
	shll	$6, %esi
	movq	%r15, %rdi
	callq	_DIV_ROUND_UP
                                        ## kill: def $eax killed $eax def $rax
	leal	-256(%rax), %ecx
	cmpl	$-256, %ecx
	ja	LBB0_2
## %bb.1:
	movl	(%rbx), %edx
	movl	16(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_3
LBB0_2:
	decl	%eax
	movq	_II_CLOCKTIME@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rsi
	addq	8(%rbx), %rsi
	movl	%eax, %edi
	callq	_writeb_relaxed
LBB0_3:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_II_CONTROL_LOCAL_RESET,4,2     ## @II_CONTROL_LOCAL_RESET
	.comm	_II_CONTROL,8,3                 ## @II_CONTROL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"can't set bus speed of %u Hz\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_II_CLOCKTIME,8,3               ## @II_CLOCKTIME
	.no_dead_strip	_dc_i2c_init_hw
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dc_i2c_init_hw
_dc_i2c_init_hw:                        ; @dc_i2c_init_hw
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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, #20]
	bl	_clk_get_rate
	mov	x20, x0
Lloh0:
	adrp	x8, _II_CONTROL_LOCAL_RESET@GOTPAGE
Lloh1:
	ldr	x8, [x8, _II_CONTROL_LOCAL_RESET@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	ldr	x8, [x19, #8]
Lloh3:
	adrp	x21, _II_CONTROL@GOTPAGE
Lloh4:
	ldr	x21, [x21, _II_CONTROL@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x1, x9, x8
	bl	_writeb_relaxed
	mov	w0, #100
	bl	_udelay
	ldr	x8, [x19, #8]
	ldr	x9, [x21]
	add	x1, x9, x8
	mov	w0, #0
	bl	_writeb_relaxed
	mov	w0, #100
	bl	_udelay
	ldr	w8, [x19]
	lsl	w1, w8, #6
	mov	x0, x20
	bl	_DIV_ROUND_UP
	sub	w8, w0, #256
	cmn	w8, #256
	b.hi	LBB0_2
; %bb.1:
	ldr	w0, [x19, #16]
	ldr	w2, [x19]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh7:
	adrp	x8, _EINVAL@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_3
LBB0_2:
	sub	w0, w0, #1
	ldr	x8, [x19, #8]
Lloh10:
	adrp	x9, _II_CLOCKTIME@GOTPAGE
Lloh11:
	ldr	x9, [x9, _II_CLOCKTIME@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writeb_relaxed
	mov	w0, #0
LBB0_3:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_II_CONTROL_LOCAL_RESET,4,2     ; @II_CONTROL_LOCAL_RESET
	.comm	_II_CONTROL,8,3                 ; @II_CONTROL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"can't set bus speed of %u Hz\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_II_CLOCKTIME,8,3               ; @II_CLOCKTIME
	.no_dead_strip	_dc_i2c_init_hw
.subsections_via_symbols
