	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipath_tempsense_internal_read
_ipath_tempsense_internal_read:         ## @ipath_tempsense_internal_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	_ENOENT@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	callq	_ipath_i2c_type
	testq	%rax, %rax
	je	LBB0_11
## %bb.1:
	movq	%rax, %r12
	movl	(%rax), %esi
	movq	_IPATH_NO_DEV@GOTPCREL(%rip), %rax
	cmpl	(%rax), %esi
	je	LBB0_2
## %bb.3:
	movq	_WRITE_CMD@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movq	%r15, %rdi
	callq	_i2c_startcmd
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	leaq	L_.str(%rip), %rdi
LBB0_5:
	callq	_ipath_dbg
	movq	%r15, %rdi
	callq	_stop_cmd
	jmp	LBB0_2
LBB0_6:
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_wr_byte
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_stop_cmd
	testl	%ebx, %ebx
	je	LBB0_8
## %bb.7:
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_ipath_dev_err
LBB0_2:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_11:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movq	_READ_CMD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	orl	(%r12), %esi
	movq	%r15, %rdi
	callq	_i2c_startcmd
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_5
LBB0_10:
	movq	%r15, %rdi
	callq	_rd_byte
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_stop_cmd
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_IPATH_NO_DEV,4,2               ## @IPATH_NO_DEV
	.comm	_ENXIO,4,2                      ## @ENXIO
	.comm	_WRITE_CMD,4,2                  ## @WRITE_CMD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed tempsense startcmd\n"

L_.str.1:                               ## @.str.1
	.asciz	"Failed tempsense WR command %02X\n"

	.comm	_READ_CMD,4,2                   ## @READ_CMD
L_.str.2:                               ## @.str.2
	.asciz	"Failed tempsense RD startcmd\n"

	.no_dead_strip	_ipath_tempsense_internal_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipath_tempsense_internal_read
_ipath_tempsense_internal_read:         ; @ipath_tempsense_internal_read
	.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	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _ENOENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	bl	_ipath_i2c_type
	cbz	x0, LBB0_5
; %bb.1:
	mov	x21, x0
	ldr	w8, [x0]
Lloh3:
	adrp	x9, _IPATH_NO_DEV@GOTPAGE
Lloh4:
	ldr	x9, [x9, _IPATH_NO_DEV@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	cmp	w8, w9
	b.eq	LBB0_8
; %bb.2:
Lloh6:
	adrp	x9, _WRITE_CMD@GOTPAGE
Lloh7:
	ldr	x9, [x9, _WRITE_CMD@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w1, w9, w8
	mov	x0, x19
	bl	_i2c_startcmd
	cbz	x0, LBB0_6
; %bb.3:
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
LBB0_4:
	bl	_ipath_dbg
	mov	x0, x19
	bl	_stop_cmd
	b	LBB0_8
LBB0_5:
	neg	w0, w22
	b	LBB0_9
LBB0_6:
	mov	x0, x19
	mov	x1, x20
	bl	_wr_byte
	mov	x22, x0
	mov	x0, x19
	bl	_stop_cmd
	cbz	w22, LBB0_10
; %bb.7:
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	bl	_ipath_dev_err
LBB0_8:
Lloh13:
	adrp	x8, _ENXIO@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_9:
	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
LBB0_10:
	ldr	w8, [x21]
Lloh16:
	adrp	x9, _READ_CMD@GOTPAGE
Lloh17:
	ldr	x9, [x9, _READ_CMD@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	orr	w1, w9, w8
	mov	x0, x19
	bl	_i2c_startcmd
	cbz	x0, LBB0_12
; %bb.11:
Lloh19:
	adrp	x0, l_.str.2@PAGE
Lloh20:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_4
LBB0_12:
	mov	x0, x19
	bl	_rd_byte
	mov	x20, x0
	mov	x0, x19
	bl	_stop_cmd
	mov	x0, x20
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_IPATH_NO_DEV,4,2               ; @IPATH_NO_DEV
	.comm	_ENXIO,4,2                      ; @ENXIO
	.comm	_WRITE_CMD,4,2                  ; @WRITE_CMD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed tempsense startcmd\n"

l_.str.1:                               ; @.str.1
	.asciz	"Failed tempsense WR command %02X\n"

	.comm	_READ_CMD,4,2                   ; @READ_CMD
l_.str.2:                               ; @.str.2
	.asciz	"Failed tempsense RD startcmd\n"

	.no_dead_strip	_ipath_tempsense_internal_read
.subsections_via_symbols
