	.file	"extr_w83793.c_store_temp_mode.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	store_temp_mode, @function
store_temp_mode:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	r15, rsi
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14, rdx
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 40
	.cfi_def_cfa_offset 96
	mov	QWORD PTR 8[rsp], rcx
	call	to_i2c_client@PLT
	mov	rdi, rax
	mov	r12, rax
	call	i2c_get_clientdata@PLT
	mov	rdi, r15
	mov	r13, rax
	call	to_sensor_dev_attr_2@PLT
	mov	r15d, DWORD PTR [rax]
	cmp	r15d, 3
	jg	.L19
	mov	edx, 10
	xor	esi, esi
	lea	ebp, [r15+r15]
	mov	rdi, r14
	call	simple_strtoul@PLT
	mov	ebx, eax
	cmp	eax, 6
	jne	.L20
	mov	ebx, 3
	mov	r14d, 3
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L19:
	mov	edx, 10
	xor	esi, esi
	mov	rdi, r14
	mov	ebx, 1
	call	simple_strtoul@PLT
	lea	ebp, -4[r15]
	cmp	eax, 4
	jne	.L8
.L9:
	mov	r14d, 1
.L4:
	lea	r8, 8[r13]
	mov	rdi, r8
	mov	QWORD PTR 24[rsp], r8
	call	mutex_lock@PLT
	cmp	r15d, 3
	mov	rdx, QWORD PTR 0[r13]
	mov	rdi, r12
	setg	r15b
	mov	rax, QWORD PTR W83793_REG_TEMP_MODE[rip]
	movzx	r15d, r15b
	sal	r15, 2
	mov	esi, DWORD PTR [rax+r15]
	add	rdx, r15
	mov	QWORD PTR 16[rsp], rdx
	call	w83793_read_value@PLT
	mov	rdx, QWORD PTR 16[rsp]
	mov	ecx, ebp
	mov	rdi, r12
	sal	ebx, cl
	sal	r14d, cl
	mov	DWORD PTR [rdx], eax
	mov	rax, QWORD PTR 0[r13]
	mov	edx, ebx
	not	edx
	add	rax, r15
	and	edx, DWORD PTR [rax]
	or	edx, r14d
	mov	DWORD PTR [rax], edx
	mov	rax, QWORD PTR W83793_REG_TEMP_MODE[rip]
	mov	esi, DWORD PTR [rax+r15]
	call	w83793_write_value@PLT
	mov	r8, QWORD PTR 24[rsp]
	mov	rdi, r8
	call	mutex_unlock@PLT
	mov	rax, QWORD PTR 8[rsp]
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L20:
	.cfi_restore_state
	cmp	eax, 3
	je	.L9
.L8:
	mov	rax, QWORD PTR EINVAL[rip]
	add	rsp, 40
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	neg	rax
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	store_temp_mode, .-store_temp_mode
	.comm	W83793_REG_TEMP_MODE,8,8
	.comm	EINVAL,8,8
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_w83793.c_store_temp_mode.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	store_temp_mode, %function
store_temp_mode:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	sub	sp, sp, #12
	mov	r5, r1
	mov	r8, r2
	mov	r7, r3
	bl	to_i2c_client
	mov	r6, r0
	bl	i2c_get_clientdata
	mov	r4, r0
	mov	r0, r5
	bl	to_sensor_dev_attr_2
	ldr	r5, [r0]
	cmp	r5, #3
	bgt	.L18
	mov	r0, r8
	mov	r2, #10
	mov	r1, #0
	bl	simple_strtoul
	cmp	r0, #6
	mov	r8, r0
	moveq	r8, #3
	lsl	r10, r5, #1
	moveq	fp, r8
	bne	.L19
.L4:
	add	r9, r4, #4
	mov	r0, r9
	bl	mutex_lock
	cmp	r5, #3
	movgt	r5, #4
	movle	r5, #0
	ldr	r3, .L20
	ldr	r2, [r4]
	ldr	r1, [r3]
	mov	r0, r6
	ldr	r1, [r1, r5]
	str	r2, [sp, #4]
	bl	w83793_read_value
	ldr	r2, [sp, #4]
	ldr	r1, [r4]
	str	r0, [r2, r5]
	ldr	r2, [r1, r5]
	ldr	r3, .L20
	bic	r2, r2, r8, lsl r10
	ldr	r3, [r3]
	orr	r2, r2, fp, lsl r10
	str	r2, [r1, r5]
	ldr	r1, [r3, r5]
	mov	r0, r6
	bl	w83793_write_value
	mov	r0, r9
	bl	mutex_unlock
	mov	r0, r7
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L18:
	mov	r0, r8
	mov	r2, #10
	mov	r1, #0
	bl	simple_strtoul
	cmp	r0, #4
	moveq	r8, #1
	subeq	r10, r5, #4
	bne	.L8
.L9:
	mov	fp, #1
	b	.L4
.L19:
	cmp	r8, #3
	beq	.L9
.L8:
	ldr	r3, .L20+4
	ldr	r0, [r3]
	rsb	r0, r0, #0
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L21:
	.align	2
.L20:
	.word	W83793_REG_TEMP_MODE
	.word	EINVAL
	.size	store_temp_mode, .-store_temp_mode
	.comm	W83793_REG_TEMP_MODE,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
