	.file	"extr_sp8870.c_sp8870_read_status.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	sp8870_read_status, @function
sp8870_read_status:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rsi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	r12, QWORD PTR [rdi]
	mov	DWORD PTR [rsi], 0
	mov	esi, 512
	mov	rdi, r12
	call	sp8870_readreg@PLT
	test	eax, eax
	js	.L14
	mov	esi, 771
	mov	rdi, r12
	mov	ebx, eax
	call	sp8870_readreg@PLT
	test	eax, eax
	js	.L14
	cmp	eax, 15
	jle	.L5
	mov	eax, DWORD PTR FE_HAS_SIGNAL[rip]
	or	DWORD PTR 0[rbp], eax
.L5:
	test	bl, 8
	je	.L6
	mov	eax, DWORD PTR FE_HAS_SYNC[rip]
	or	DWORD PTR 0[rbp], eax
.L6:
	mov	eax, ebx
	and	eax, 4
	je	.L1
	mov	eax, DWORD PTR FE_HAS_LOCK[rip]
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	or	eax, DWORD PTR FE_HAS_CARRIER[rip]
	or	eax, DWORD PTR FE_HAS_VITERBI[rip]
	or	DWORD PTR 0[rbp], eax
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L14:
	.cfi_restore_state
	mov	eax, DWORD PTR EIO[rip]
	neg	eax
.L1:
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	sp8870_read_status, .-sp8870_read_status
	.comm	FE_HAS_VITERBI,4,4
	.comm	FE_HAS_SYNC,4,4
	.comm	FE_HAS_SIGNAL,4,4
	.comm	FE_HAS_LOCK,4,4
	.comm	FE_HAS_CARRIER,4,4
	.comm	EIO,4,4
	.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_sp8870.c_sp8870_read_status.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	sp8870_read_status, %function
sp8870_read_status:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	mov	r3, #0
	mov	r5, r1
	ldr	r6, [r0]
	mov	r1, #512
	mov	r0, r6
	str	r3, [r5]
	bl	sp8870_readreg
	subs	r4, r0, #0
	blt	.L14
	mov	r0, r6
	ldr	r1, .L16
	bl	sp8870_readreg
	cmp	r0, #0
	blt	.L14
	cmp	r0, #15
	ldrgt	r2, .L16+4
	ldrgt	r3, [r5]
	ldrgt	r2, [r2]
	orrgt	r3, r3, r2
	strgt	r3, [r5]
	tst	r4, #8
	ldrne	r2, .L16+8
	ldrne	r3, [r5]
	ldrne	r2, [r2]
	orrne	r3, r3, r2
	strne	r3, [r5]
	ands	r0, r4, #4
	popeq	{r4, r5, r6, pc}
	ldr	r3, .L16+12
	ldr	r2, .L16+16
	ldr	r1, .L16+20
	ldr	r2, [r2]
	ldr	r3, [r3]
	ldr	r1, [r1]
	orr	r3, r3, r2
	ldr	r2, [r5]
	orr	r3, r3, r1
	orr	r3, r2, r3
	mov	r0, #0
	str	r3, [r5]
	pop	{r4, r5, r6, pc}
.L14:
	ldr	r3, .L16+24
	ldr	r0, [r3]
	rsb	r0, r0, #0
	pop	{r4, r5, r6, pc}
.L17:
	.align	2
.L16:
	.word	771
	.word	FE_HAS_SIGNAL
	.word	FE_HAS_SYNC
	.word	FE_HAS_LOCK
	.word	FE_HAS_CARRIER
	.word	FE_HAS_VITERBI
	.word	EIO
	.size	sp8870_read_status, .-sp8870_read_status
	.comm	FE_HAS_VITERBI,4,4
	.comm	FE_HAS_SYNC,4,4
	.comm	FE_HAS_SIGNAL,4,4
	.comm	FE_HAS_LOCK,4,4
	.comm	FE_HAS_CARRIER,4,4
	.comm	EIO,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
