	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function octeon_i2c_reg_read
_octeon_i2c_reg_read:                   ## @octeon_i2c_reg_read
	.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	%rdx, -48(%rbp)                 ## 8-byte Spill
	movl	%esi, %r15d
	movq	%rdi, %r13
	movq	_SW_TWSI_V@GOTPCREL(%rip), %r14
	orl	(%r14), %r15d
	movq	_SW_TWSI_R@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	(%rdi), %r12
	callq	_SW_TWSI
	addq	%rax, %r12
	movl	%r15d, %edi
	movq	%r12, %rsi
	callq	___raw_writeq
	movl	$-1001, %r15d                   ## imm = 0xFC17
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rbx
	movq	%r13, %rdi
	callq	_SW_TWSI
	addq	%rax, %rbx
	movq	%rbx, %rdi
	callq	___raw_readq
	incl	%r15d
	je	LBB0_2
## %bb.5:                               ##   in Loop: Header=BB0_1 Depth=1
	testl	%eax, (%r14)
	jne	LBB0_1
## %bb.6:
	movzbl	%al, %eax
	jmp	LBB0_7
LBB0_2:
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	testq	%rsi, %rsi
	je	LBB0_3
## %bb.4:
	movq	_EIO@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	xorl	%edx, %edx
	subl	(%rcx), %edx
	movl	%edx, (%rsi)
	jmp	LBB0_7
LBB0_3:
	xorl	%eax, %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SW_TWSI_V,4,2                  ## @SW_TWSI_V
	.comm	_SW_TWSI_R,4,2                  ## @SW_TWSI_R
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_octeon_i2c_reg_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function octeon_i2c_reg_read
_octeon_i2c_reg_read:                   ; @octeon_i2c_reg_read
	.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, x0
Lloh0:
	adrp	x22, _SW_TWSI_V@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SW_TWSI_V@GOTPAGEOFF]
	ldr	w8, [x22]
	orr	w8, w8, w1
Lloh2:
	adrp	x9, _SW_TWSI_R@GOTPAGE
Lloh3:
	ldr	x9, [x9, _SW_TWSI_R@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	orr	w21, w8, w9
	ldr	x23, [x0]
	bl	_SW_TWSI
	add	x1, x0, x23
	mov	x0, x21
	bl	___raw_writeq
	mov	w21, #-1001
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x23, [x20]
	mov	x0, x20
	bl	_SW_TWSI
	add	x0, x0, x23
	bl	___raw_readq
	adds	w21, w21, #1
	b.hs	LBB0_4
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	w8, [x22]
	tst	w8, w0
	b.ne	LBB0_1
; %bb.3:
	and	w0, w0, #0xff
	b	LBB0_6
LBB0_4:
	mov	w0, #0
	cbz	x19, LBB0_6
; %bb.5:
Lloh5:
	adrp	x8, _EIO@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w8, w8
	str	w8, [x19]
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
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_SW_TWSI_V,4,2                  ; @SW_TWSI_V
	.comm	_SW_TWSI_R,4,2                  ; @SW_TWSI_R
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_octeon_i2c_reg_read
.subsections_via_symbols
