	.file	"extr_led_rpi.c_rpi_set.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"[LED]: invalid led %d\n"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC1:
	.string	"[LED]: rpi setup led %d gpio %d\n"
	.align 8
.LC2:
	.string	"[LED]: rpi LED driver set led %d gpio %d = %d\n"
	.align 8
.LC3:
	.string	"[LED]: failed to setup led %d gpio %d\n"
	.text
	.p2align 4
	.type	rpi_set, @function
rpi_set:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	ebp, edi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	test	edi, edi
	js	.L2
	cmp	DWORD PTR MAX_LEDS[rip], edi
	jle	.L2
	mov	rax, QWORD PTR cur[rip]
	movsx	rbx, edi
	mov	rdx, QWORD PTR [rax]
	mov	r13d, DWORD PTR [rdx+rbx*4]
	test	r13d, r13d
	jle	.L1
	mov	rax, QWORD PTR 8[rax]
	mov	r12d, esi
	lea	r14, 0[0+rbx*8]
	mov	rax, QWORD PTR [rax+rbx*8]
	test	rax, rax
	je	.L12
.L6:
	test	rax, rax
	jg	.L8
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	esi, ebp
	lea	rdi, .LC0[rip]
	pop	rbp
	.cfi_def_cfa_offset 32
	xor	eax, eax
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	RARCH_WARN@PLT
	.p2align 4,,10
	.p2align 3
.L12:
	.cfi_restore_state
	mov	ecx, esi
	mov	edx, r13d
	mov	esi, edi
	lea	rdi, .LC1[rip]
	call	RARCH_LOG@PLT
	mov	rax, QWORD PTR cur[rip]
	mov	edi, r13d
	add	r14, QWORD PTR 8[rax]
	call	setup_gpio@PLT
	mov	QWORD PTR [r14], rax
	mov	rax, QWORD PTR cur[rip]
	mov	rax, QWORD PTR 8[rax]
	cmp	QWORD PTR [rax+rbx*8], 0
	jle	.L7
.L8:
	mov	esi, ebp
	mov	ecx, r12d
	lea	rdi, .LC2[rip]
	mov	edx, r13d
	call	RARCH_LOG@PLT
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	esi, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	mov	edi, r13d
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	set_gpio@PLT
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	mov	edx, r13d
	mov	esi, ebp
	lea	rdi, .LC3[rip]
	xor	eax, eax
	call	RARCH_WARN@PLT
	mov	rax, QWORD PTR cur[rip]
	mov	rax, QWORD PTR 8[rax]
	mov	rax, QWORD PTR [rax+rbx*8]
	jmp	.L6
	.cfi_endproc
.LFE0:
	.size	rpi_set, .-rpi_set
	.comm	cur,8,8
	.comm	MAX_LEDS,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_led_rpi.c_rpi_set.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"[LED]: invalid led %d\012\000"
	.align	2
.LC1:
	.ascii	"[LED]: rpi setup led %d gpio %d\012\000"
	.align	2
.LC2:
	.ascii	"[LED]: rpi LED driver set led %d gpio %d = %d\012\000"
	.align	2
.LC3:
	.ascii	"[LED]: failed to setup led %d gpio %d\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	rpi_set, %function
rpi_set:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	subs	r4, r0, #0
	blt	.L2
	ldr	r3, .L13
	ldr	r3, [r3]
	cmp	r3, r4
	ble	.L2
	ldr	r7, .L13+4
	ldr	r3, [r7]
	ldr	r2, [r3]
	ldr	r6, [r2, r4, lsl #2]
	cmp	r6, #0
	pople	{r4, r5, r6, r7, r8, pc}
	ldr	r3, [r3, #4]
	mov	r5, r1
	ldr	r3, [r3, r4, lsl #2]
	cmp	r3, #0
	beq	.L12
.L6:
	cmp	r3, #0
	pople	{r4, r5, r6, r7, r8, pc}
.L8:
	mov	r1, r4
	mov	r3, r5
	mov	r2, r6
	ldr	r0, .L13+8
	bl	RARCH_LOG
	mov	r1, r5
	mov	r0, r6
	pop	{r4, r5, r6, r7, r8, lr}
	b	set_gpio
.L2:
	mov	r1, r4
	pop	{r4, r5, r6, r7, r8, lr}
	ldr	r0, .L13+12
	b	RARCH_WARN
.L12:
	mov	r3, r1
	mov	r2, r6
	mov	r1, r4
	ldr	r0, .L13+16
	bl	RARCH_LOG
	ldr	r3, [r7]
	mov	r0, r6
	ldr	r8, [r3, #4]
	bl	setup_gpio
	ldr	r3, [r7]
	str	r0, [r8, r4, lsl #2]
	ldr	r3, [r3, #4]
	ldr	r3, [r3, r4, lsl #2]
	cmp	r3, #0
	bgt	.L8
	mov	r2, r6
	mov	r1, r4
	ldr	r0, .L13+20
	bl	RARCH_WARN
	ldr	r3, [r7]
	ldr	r3, [r3, #4]
	ldr	r3, [r3, r4, lsl #2]
	b	.L6
.L14:
	.align	2
.L13:
	.word	MAX_LEDS
	.word	cur
	.word	.LC2
	.word	.LC0
	.word	.LC1
	.word	.LC3
	.size	rpi_set, .-rpi_set
	.comm	cur,4,4
	.comm	MAX_LEDS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
