	.file	"extr_atkbdc.c_atkbdc_kbd_queue_data.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"atkbd data buffer full\n"
	.text
	.p2align 4
	.type	atkbdc_kbd_queue_data, @function
atkbdc_kbd_queue_data:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbx
	.cfi_def_cfa_offset 16
	.cfi_offset 3, -16
	mov	eax, DWORD PTR FIFOSZ[rip]
	mov	rbx, rdi
	cmp	DWORD PTR [rdi], eax
	jge	.L2
	mov	rax, QWORD PTR 8[rdi]
	mov	rdx, QWORD PTR 16[rdi]
	mov	DWORD PTR [rdx+rax*4], esi
	movsx	rsi, DWORD PTR FIFOSZ[rip]
	add	rax, 1
	xor	edx, edx
	div	rsi
	mov	eax, DWORD PTR [rdi]
	mov	rcx, rsi
	add	eax, 1
	mov	DWORD PTR [rdi], eax
	mov	QWORD PTR 8[rdi], rdx
	mov	edx, DWORD PTR KBDS_KBD_BUFFER_FULL[rip]
	or	DWORD PTR 28[rdi], edx
	mov	edx, DWORD PTR KBDO_KBD_OUTFULL[rip]
	or	DWORD PTR 24[rdi], edx
	cmp	eax, ecx
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	setl	al
	movzx	eax, al
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	lea	rdi, .LC0[rip]
	call	printf@PLT
	mov	eax, DWORD PTR [rbx]
	mov	ecx, DWORD PTR FIFOSZ[rip]
	pop	rbx
	.cfi_def_cfa_offset 8
	cmp	eax, ecx
	setl	al
	movzx	eax, al
	ret
	.cfi_endproc
.LFE0:
	.size	atkbdc_kbd_queue_data, .-atkbdc_kbd_queue_data
	.comm	KBDS_KBD_BUFFER_FULL,4,4
	.comm	KBDO_KBD_OUTFULL,4,4
	.comm	FIFOSZ,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_atkbdc.c_atkbdc_kbd_queue_data.c"
	.text
	.global	__aeabi_uidivmod
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"atkbd data buffer full\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	atkbdc_kbd_queue_data, %function
atkbdc_kbd_queue_data:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r5, .L6
	ldr	r2, [r0]
	ldr	r3, [r5]
	mov	r4, r0
	cmp	r2, r3
	bge	.L2
	ldr	r3, [r0, #4]
	ldr	r2, [r0, #8]
	add	r0, r3, #1
	str	r1, [r2, r3, lsl #2]
	ldr	r5, [r5]
	mov	r1, r5
	bl	__aeabi_uidivmod
	ldr	r2, .L6+4
	ldr	r3, .L6+8
	ldr	ip, [r2]
	ldr	r3, [r3]
	ldr	r2, [r4, #16]
	ldr	r0, [r4]
	orr	r2, r2, r3
	ldr	r3, [r4, #12]
	add	r0, r0, #1
	orr	r3, r3, ip
	str	r1, [r4, #4]
	str	r2, [r4, #16]
	str	r3, [r4, #12]
	str	r0, [r4]
.L3:
	cmp	r0, r5
	movge	r0, #0
	movlt	r0, #1
	pop	{r4, r5, r6, pc}
.L2:
	ldr	r0, .L6+12
	bl	printf
	ldr	r0, [r4]
	ldr	r5, [r5]
	b	.L3
.L7:
	.align	2
.L6:
	.word	FIFOSZ
	.word	KBDO_KBD_OUTFULL
	.word	KBDS_KBD_BUFFER_FULL
	.word	.LC0
	.size	atkbdc_kbd_queue_data, .-atkbdc_kbd_queue_data
	.comm	KBDS_KBD_BUFFER_FULL,4,4
	.comm	KBDO_KBD_OUTFULL,4,4
	.comm	FIFOSZ,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
