	.file	"extr_af9033.c_af9033_read_snr.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"\n"
.LC1:
	.string	"failed=%d\n"
	.text
	.p2align 4
	.type	af9033_read_snr, @function
af9033_read_snr:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	mov	rbx, rsi
	lea	rsi, .LC0[rip]
	sub	rsp, 24
	.cfi_def_cfa_offset 64
	mov	rbp, QWORD PTR [rdi]
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	r13, QWORD PTR 24[rbp]
	mov	rdi, r13
	call	dev_dbg@PLT
	mov	rax, QWORD PTR 16[rbp]
	mov	rcx, QWORD PTR FE_SCALE_DECIBEL[rip]
	cmp	QWORD PTR [rax], rcx
	je	.L11
	mov	DWORD PTR [rbx], 0
	xor	r12d, r12d
.L1:
	mov	rax, QWORD PTR 8[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L12
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	cmp	QWORD PTR 8[rbp], 0
	mov	edi, DWORD PTR 8[rax]
	jne	.L13
	mov	esi, 1000
	call	div_s64@PLT
	lea	rdx, 4[rsp]
	mov	esi, 8452355
	mov	DWORD PTR [rbx], eax
	mov	edi, DWORD PTR 0[rbp]
	call	regmap_read@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L5
	mov	eax, DWORD PTR 4[rsp]
	and	eax, 3
	cmp	eax, 1
	je	.L6
	cmp	eax, 2
	je	.L7
	test	eax, eax
	je	.L14
.L5:
	mov	edx, r12d
	lea	rsi, .LC1[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_dbg@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L13:
	mov	esi, 100
	xor	r12d, r12d
	call	div_s64@PLT
	mov	DWORD PTR [rbx], eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L6:
	mov	eax, DWORD PTR [rbx]
	mov	edx, eax
	sal	edx, 16
	sub	edx, eax
	movsx	rax, edx
	sar	edx, 31
	imul	rax, rax, 1321528399
	sar	rax, 35
	sub	eax, edx
	mov	DWORD PTR [rbx], eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L14:
	mov	eax, DWORD PTR [rbx]
	mov	edx, eax
	sal	edx, 16
	sub	edx, eax
	movsx	rax, edx
	imul	rax, rax, -1307163959
	shr	rax, 32
	add	eax, edx
	sar	edx, 31
	sar	eax, 4
	sub	eax, edx
	mov	DWORD PTR [rbx], eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L7:
	mov	edx, DWORD PTR [rbx]
	mov	eax, edx
	sal	eax, 16
	sub	eax, edx
	mov	edx, eax
	lea	eax, 31[rax]
	cmovns	eax, edx
	sar	eax, 5
	mov	DWORD PTR [rbx], eax
	jmp	.L1
.L12:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	af9033_read_snr, .-af9033_read_snr
	.comm	FE_SCALE_DECIBEL,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_af9033.c_af9033_read_snr.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"\012\000"
	.align	2
.LC1:
	.ascii	"failed=%d\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	af9033_read_snr, %function
af9033_read_snr:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r4, [r0]
	ldr	r3, .L15
	ldr	r6, [r4, #12]
	mov	r5, r1
	sub	sp, sp, #8
	mov	r0, r6
	ldr	r1, .L15+4
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	bl	dev_dbg
	ldr	r3, [r4, #8]
	ldr	r2, .L15+8
	ldr	r0, [r3]
	ldr	r2, [r2]
	cmp	r0, r2
	movne	r4, #0
	strne	r4, [r5]
	beq	.L11
.L1:
	ldr	r3, .L15
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L12
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, pc}
.L11:
	ldr	r2, [r4, #4]
	ldr	r0, [r3, #4]
	cmp	r2, #0
	bne	.L13
	mov	r1, #1000
	bl	div_s64
	str	r0, [r5]
	ldr	r0, [r4]
	mov	r2, sp
	ldr	r1, .L15+12
	bl	regmap_read
	subs	r4, r0, #0
	bne	.L5
	ldr	r3, [sp]
	and	r3, r3, #3
	cmp	r3, #1
	beq	.L6
	cmp	r3, #2
	beq	.L7
	cmp	r3, #0
	beq	.L14
.L5:
	mov	r0, r6
	mov	r2, r4
	ldr	r1, .L15+16
	bl	dev_dbg
	b	.L1
.L13:
	mov	r1, #100
	bl	div_s64
	mov	r4, #0
	str	r0, [r5]
	b	.L1
.L6:
	ldr	r3, [r5]
	ldr	r2, .L15+20
	rsb	r3, r3, r3, lsl #16
	smull	r1, r2, r3, r2
	asr	r3, r3, #31
	rsb	r3, r3, r2, asr #3
	str	r3, [r5]
	b	.L1
.L14:
	ldr	r3, [r5]
	ldr	r2, .L15+24
	rsb	r3, r3, r3, lsl #16
	smull	r1, r2, r3, r2
	asr	r1, r3, #31
	add	r3, r2, r3
	rsb	r3, r1, r3, asr #4
	str	r3, [r5]
	b	.L1
.L7:
	ldr	r3, [r5]
	rsb	r3, r3, r3, lsl #16
	add	r2, r3, #31
	cmp	r3, #0
	movlt	r3, r2
	asr	r3, r3, #5
	str	r3, [r5]
	b	.L1
.L12:
	bl	__stack_chk_fail
.L16:
	.align	2
.L15:
	.word	.LC2
	.word	.LC0
	.word	FE_SCALE_DECIBEL
	.word	8452355
	.word	.LC1
	.word	1321528399
	.word	-1307163959
	.size	af9033_read_snr, .-af9033_read_snr
	.comm	FE_SCALE_DECIBEL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
