	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tsc200x_selftest_show
_tsc200x_selftest_show:                 ## @tsc200x_selftest_show
	.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, %r14
	movq	%rdi, %r15
	callq	_dev_get_drvdata
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_mutex_lock
	movq	%r13, %rdi
	callq	___tsc200x_disable
	movl	4(%r13), %edi
	movq	_TSC200X_REG_TEMP_HIGH@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	leaq	-48(%rbp), %rdx
	callq	_regmap_read
	testl	%eax, %eax
	je	LBB0_3
## %bb.1:
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_2
LBB0_3:
	movl	-48(%rbp), %ebx
	decl	%ebx
	movq	_MAX_12BIT@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	movl	4(%r13), %edi
	movl	(%r12), %esi
	movl	%ebx, %edx
	callq	_regmap_write
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_2
LBB0_5:
	movl	4(%r13), %edi
	movl	(%r12), %esi
	leaq	-44(%rbp), %rdx
	callq	_regmap_read
	testl	%eax, %eax
	je	LBB0_7
## %bb.6:
	leaq	L_.str.2(%rip), %rsi
LBB0_2:
	xorl	%r12d, %r12d
	movq	%r15, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_warn
LBB0_13:
	movq	%r13, %rdi
	callq	___tsc200x_enable
	movq	%r13, %rdi
	callq	_mutex_unlock
	leaq	L_.str.6(%rip), %rsi
	movq	%r14, %rdi
	movl	%r12d, %edx
	callq	_sprintf
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movl	-44(%rbp), %edx
	cmpl	%ebx, %edx
	jne	LBB0_8
## %bb.9:
	movq	%r13, %rdi
	callq	_tsc200x_reset
	movl	4(%r13), %edi
	movl	(%r12), %esi
	leaq	-44(%rbp), %rdx
	callq	_regmap_read
	testl	%eax, %eax
	je	LBB0_11
## %bb.10:
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_2
LBB0_8:
	leaq	L_.str.3(%rip), %rsi
	xorl	%r12d, %r12d
	movq	%r15, %rdi
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_dev_warn
	movq	%r13, %rdi
	callq	_tsc200x_reset
	jmp	LBB0_13
LBB0_11:
	movl	-44(%rbp), %edx
	movl	-48(%rbp), %ecx
	movl	$1, %r12d
	cmpl	%ecx, %edx
	je	LBB0_13
## %bb.12:
	leaq	L_.str.5(%rip), %rsi
	xorl	%r12d, %r12d
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_dev_warn
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.comm	_TSC200X_REG_TEMP_HIGH,4,2      ## @TSC200X_REG_TEMP_HIGH
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"selftest failed: read error %d\n"

	.comm	_MAX_12BIT,4,2                  ## @MAX_12BIT
L_.str.1:                               ## @.str.1
	.asciz	"selftest failed: write error %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"selftest failed: read error %d after write\n"

L_.str.3:                               ## @.str.3
	.asciz	"selftest failed: %d != %d\n"

L_.str.4:                               ## @.str.4
	.asciz	"selftest failed: read error %d after reset\n"

L_.str.5:                               ## @.str.5
	.asciz	"selftest failed after reset: %d != %d\n"

L_.str.6:                               ## @.str.6
	.asciz	"%d\n"

	.no_dead_strip	_tsc200x_selftest_show
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tsc200x_selftest_show
_tsc200x_selftest_show:                 ; @tsc200x_selftest_show
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x21, x0
	bl	_dev_get_drvdata
	mov	x20, x0
	bl	_mutex_lock
	mov	x0, x20
	bl	___tsc200x_disable
	ldr	w0, [x20, #4]
Lloh0:
	adrp	x23, _TSC200X_REG_TEMP_HIGH@GOTPAGE
Lloh1:
	ldr	x23, [x23, _TSC200X_REG_TEMP_HIGH@GOTPAGEOFF]
	ldr	w1, [x23]
	add	x2, sp, #8
	bl	_regmap_read
	cbz	w0, LBB0_2
; %bb.1:
	mov	x2, x0
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_6
LBB0_2:
	ldr	w8, [sp, #8]
	sub	w8, w8, #1
Lloh4:
	adrp	x9, _MAX_12BIT@GOTPAGE
Lloh5:
	ldr	x9, [x9, _MAX_12BIT@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	and	w22, w8, w9
	ldr	w0, [x20, #4]
	ldr	w1, [x23]
	mov	x2, x22
	bl	_regmap_write
	cbz	w0, LBB0_4
; %bb.3:
	mov	x2, x0
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_6
LBB0_4:
	ldr	w0, [x20, #4]
	ldr	w1, [x23]
	add	x2, sp, #12
	bl	_regmap_read
	cbz	w0, LBB0_9
; %bb.5:
	mov	x2, x0
Lloh9:
	adrp	x1, l_.str.2@PAGE
Lloh10:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_6:
	mov	x0, x21
	bl	_dev_warn
LBB0_7:
	mov	w21, #0
LBB0_8:
	mov	x0, x20
	bl	___tsc200x_enable
	mov	x0, x20
	bl	_mutex_unlock
Lloh11:
	adrp	x1, l_.str.6@PAGE
Lloh12:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x19
	mov	x2, x21
	bl	_sprintf
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_9:
	ldr	w2, [sp, #12]
	cmp	w2, w22
	b.ne	LBB0_12
; %bb.10:
	mov	x0, x20
	bl	_tsc200x_reset
	ldr	w0, [x20, #4]
	ldr	w1, [x23]
	add	x2, sp, #12
	bl	_regmap_read
	cbz	w0, LBB0_13
; %bb.11:
	mov	x2, x0
Lloh13:
	adrp	x1, l_.str.4@PAGE
Lloh14:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_6
LBB0_12:
	str	x22, [sp]
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x21
	bl	_dev_warn
	mov	x0, x20
	bl	_tsc200x_reset
	b	LBB0_7
LBB0_13:
	ldp	w8, w2, [sp, #8]
	cmp	w2, w8
	b.ne	LBB0_15
; %bb.14:
	mov	w21, #1
	b	LBB0_8
LBB0_15:
	str	x8, [sp]
Lloh17:
	adrp	x1, l_.str.5@PAGE
Lloh18:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_6
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_TSC200X_REG_TEMP_HIGH,4,2      ; @TSC200X_REG_TEMP_HIGH
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"selftest failed: read error %d\n"

	.comm	_MAX_12BIT,4,2                  ; @MAX_12BIT
l_.str.1:                               ; @.str.1
	.asciz	"selftest failed: write error %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"selftest failed: read error %d after write\n"

l_.str.3:                               ; @.str.3
	.asciz	"selftest failed: %d != %d\n"

l_.str.4:                               ; @.str.4
	.asciz	"selftest failed: read error %d after reset\n"

l_.str.5:                               ; @.str.5
	.asciz	"selftest failed after reset: %d != %d\n"

l_.str.6:                               ; @.str.6
	.asciz	"%d\n"

	.no_dead_strip	_tsc200x_selftest_show
.subsections_via_symbols
