	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function asb100_read_value
_asb100_read_value:                     ## @asb100_read_value
	.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, %r15d
	movq	%rdi, %rbx
	callq	_i2c_get_clientdata
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_mutex_lock
	movl	%r15d, %edx
	shrl	$8, %edx
	andl	$15, %edx
	cmpl	$2, %edx
	jbe	LBB0_2
## %bb.1:
	movq	_ASB100_REG_BANK@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_i2c_smbus_write_byte_data
	movzbl	%r15b, %esi
	movq	%rbx, %rdi
	callq	_i2c_smbus_read_byte_data
	movl	%eax, %r15d
	movl	(%r12), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_i2c_smbus_write_byte_data
	jmp	LBB0_14
LBB0_2:
	testl	%edx, %edx
	je	LBB0_7
## %bb.3:
	movq	8(%r14), %rax
	decl	%edx
	movq	(%rax,%rdx,8), %rdi
	cmpb	$83, %r15b
	je	LBB0_8
## %bb.4:
	cmpb	$82, %r15b
	je	LBB0_9
## %bb.5:
	cmpb	$80, %r15b
	jne	LBB0_11
## %bb.6:
	xorl	%esi, %esi
	jmp	LBB0_12
LBB0_7:
	movzbl	%r15b, %esi
	movq	%rbx, %rdi
	jmp	LBB0_10
LBB0_8:
	movl	$2, %esi
	jmp	LBB0_12
LBB0_9:
	movl	$1, %esi
LBB0_10:
	callq	_i2c_smbus_read_byte_data
	jmp	LBB0_13
LBB0_11:
	movl	$3, %esi
LBB0_12:
	callq	_i2c_smbus_read_word_data
	movl	%eax, %edi
	callq	_swab16
LBB0_13:
	movl	%eax, %r15d
LBB0_14:
	movq	%r14, %rdi
	callq	_mutex_unlock
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ASB100_REG_BANK,4,2            ## @ASB100_REG_BANK
	.no_dead_strip	_asb100_read_value
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function asb100_read_value
_asb100_read_value:                     ; @asb100_read_value
	.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	x21, x1
	mov	x20, x0
	bl	_i2c_get_clientdata
	mov	x19, x0
	bl	_mutex_lock
	ubfx	w2, w21, #8, #4
	cmp	w2, #2
	b.ls	LBB0_2
; %bb.1:
Lloh0:
	adrp	x22, _ASB100_REG_BANK@GOTPAGE
Lloh1:
	ldr	x22, [x22, _ASB100_REG_BANK@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	bl	_i2c_smbus_write_byte_data
	and	w1, w21, #0xff
	mov	x0, x20
	bl	_i2c_smbus_read_byte_data
	mov	x21, x0
	ldr	w1, [x22]
	mov	x0, x20
	mov	w2, #0
	bl	_i2c_smbus_write_byte_data
	b	LBB0_14
LBB0_2:
	cbz	w2, LBB0_7
; %bb.3:
	ldr	x8, [x19, #8]
	sub	w9, w2, #1
	ldr	x0, [x8, w9, uxtw #3]
	and	w8, w21, #0xff
	cmp	w8, #83
	b.eq	LBB0_8
; %bb.4:
	cmp	w8, #82
	b.eq	LBB0_9
; %bb.5:
	cmp	w8, #80
	b.ne	LBB0_11
; %bb.6:
	mov	w1, #0
	b	LBB0_12
LBB0_7:
	and	w1, w21, #0xff
	mov	x0, x20
	b	LBB0_10
LBB0_8:
	mov	w1, #2
	b	LBB0_12
LBB0_9:
	mov	w1, #1
LBB0_10:
	bl	_i2c_smbus_read_byte_data
	b	LBB0_13
LBB0_11:
	mov	w1, #3
LBB0_12:
	bl	_i2c_smbus_read_word_data
	bl	_swab16
LBB0_13:
	mov	x21, x0
LBB0_14:
	mov	x0, x19
	bl	_mutex_unlock
	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 AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_ASB100_REG_BANK,4,2            ; @ASB100_REG_BANK
	.no_dead_strip	_asb100_read_value
.subsections_via_symbols
