	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function exynos5_i2c_xfer_msg
_exynos5_i2c_xfer_msg:                  ## @exynos5_i2c_xfer_msg
	.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
	movl	%edx, %r12d
	movq	%rsi, %r14
	movq	%rdi, %r13
	movq	%rsi, 32(%rdi)
	leaq	8(%rdi), %rbx
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%rdi)
	movq	%rbx, %rdi
	callq	_reinit_completion
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_exynos5_i2c_message_start
	movq	_EXYNOS5_I2C_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_wait_for_completion_timeout
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movl	(%r13), %r15d
	testl	%r12d, %r12d
	jne	LBB0_4
	jmp	LBB0_6
LBB0_1:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	testl	%r12d, %r12d
	je	LBB0_6
LBB0_4:
	testl	%r15d, %r15d
	jne	LBB0_6
## %bb.5:
	movq	%r13, %rdi
	callq	_exynos5_i2c_wait_bus_idle
	movl	%eax, %r15d
LBB0_6:
	testl	%r15d, %r15d
	jns	LBB0_9
## %bb.7:
	movq	%r13, %rdi
	callq	_exynos5_i2c_reset
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addl	%r15d, %eax
	jne	LBB0_9
## %bb.8:
	movl	4(%r13), %edi
	movq	_I2C_M_RD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%r14), %eax
	leaq	L_.str.2(%rip), %rax
	leaq	L_.str.1(%rip), %rdx
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rsi
	callq	_dev_warn
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	_EXYNOS5_I2C_TIMEOUT,4,2        ## @EXYNOS5_I2C_TIMEOUT
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s timeout\n"

	.comm	_I2C_M_RD,4,2                   ## @I2C_M_RD
L_.str.1:                               ## @.str.1
	.asciz	"rx"

L_.str.2:                               ## @.str.2
	.asciz	"tx"

	.no_dead_strip	_exynos5_i2c_xfer_msg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function exynos5_i2c_xfer_msg
_exynos5_i2c_xfer_msg:                  ; @exynos5_i2c_xfer_msg
	.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	x22, x2
	mov	x19, x1
	mov	x20, x0
	stp	xzr, x1, [x0, #24]
	add	x21, x0, #8
	str	xzr, [x0, #16]
	mov	x0, x21
	bl	_reinit_completion
	mov	x0, x20
	mov	x1, x22
	bl	_exynos5_i2c_message_start
Lloh0:
	adrp	x8, _EXYNOS5_I2C_TIMEOUT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EXYNOS5_I2C_TIMEOUT@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_wait_for_completion_timeout
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w21, [x20]
	cbnz	w22, LBB0_3
	b	LBB0_5
LBB0_2:
Lloh3:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w21, w8
	cbz	w22, LBB0_5
LBB0_3:
	cbnz	w21, LBB0_5
; %bb.4:
	mov	x0, x20
	bl	_exynos5_i2c_wait_bus_idle
	mov	x21, x0
LBB0_5:
	tbz	w21, #31, LBB0_8
; %bb.6:
	mov	x0, x20
	bl	_exynos5_i2c_reset
Lloh6:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmn	w21, w8
	b.ne	LBB0_8
; %bb.7:
	ldr	w0, [x20, #4]
	ldr	w8, [x19]
Lloh9:
	adrp	x9, _I2C_M_RD@GOTPAGE
Lloh10:
	ldr	x9, [x9, _I2C_M_RD@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
Lloh12:
	adrp	x10, l_.str.1@PAGE
Lloh13:
	add	x10, x10, l_.str.1@PAGEOFF
Lloh14:
	adrp	x11, l_.str.2@PAGE
Lloh15:
	add	x11, x11, l_.str.2@PAGEOFF
	tst	w9, w8
	csel	x2, x11, x10, eq
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_warn
LBB0_8:
	mov	x0, x21
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_EXYNOS5_I2C_TIMEOUT,4,2        ; @EXYNOS5_I2C_TIMEOUT
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s timeout\n"

	.comm	_I2C_M_RD,4,2                   ; @I2C_M_RD
l_.str.1:                               ; @.str.1
	.asciz	"rx"

l_.str.2:                               ; @.str.2
	.asciz	"tx"

	.no_dead_strip	_exynos5_i2c_xfer_msg
.subsections_via_symbols
