	.file	"extr_ar5315_spi.c_ar5315_spi_attach.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Could not map memory\n"
.LC1:
	.string	"spibus"
	.text
	.p2align 4
	.type	ar5315_spi_attach, @function
ar5315_spi_attach:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	ebp, edi
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	sub	rsp, 24
	.cfi_def_cfa_offset 48
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	call	device_get_softc@PLT
	mov	ecx, DWORD PTR RF_ACTIVE[rip]
	mov	esi, DWORD PTR SYS_RES_MEMORY[rip]
	mov	edi, ebp
	mov	DWORD PTR 4[rax], ebp
	lea	rdx, 4[rsp]
	mov	rbx, rax
	mov	DWORD PTR 4[rsp], 0
	call	bus_alloc_resource_any@PLT
	mov	DWORD PTR [rbx], eax
	test	eax, eax
	je	.L7
	mov	edx, -1
	lea	rsi, .LC1[rip]
	mov	edi, ebp
	call	device_add_child@PLT
	mov	edi, ebp
	call	ar5315_spi_attach_sysctl@PLT
	mov	edi, ebp
	call	bus_generic_attach@PLT
.L1:
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L8
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	lea	rsi, .LC0[rip]
	mov	edi, ebp
	call	device_printf@PLT
	mov	eax, DWORD PTR ENXIO[rip]
	jmp	.L1
.L8:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	ar5315_spi_attach, .-ar5315_spi_attach
	.comm	SYS_RES_MEMORY,4,4
	.comm	RF_ACTIVE,4,4
	.comm	ENXIO,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_ar5315_spi.c_ar5315_spi_attach.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Could not map memory\012\000"
	.align	2
.LC1:
	.ascii	"spibus\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	ar5315_spi_attach, %function
ar5315_spi_attach:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, lr}
	ldr	r3, .L9
	sub	sp, sp, #12
	mov	r4, r0
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	bl	device_get_softc
	mov	ip, #0
	ldr	r2, .L9+4
	ldr	r3, .L9+8
	mov	r5, r0
	ldr	r1, [r2]
	str	r4, [r0, #4]
	mov	r2, sp
	mov	r0, r4
	ldr	r3, [r3]
	str	ip, [sp]
	bl	bus_alloc_resource_any
	cmp	r0, #0
	str	r0, [r5]
	beq	.L7
	mvn	r2, #0
	ldr	r1, .L9+12
	mov	r0, r4
	bl	device_add_child
	mov	r0, r4
	bl	ar5315_spi_attach_sysctl
	mov	r0, r4
	bl	bus_generic_attach
.L1:
	ldr	r3, .L9
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L8
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, pc}
.L7:
	mov	r0, r4
	ldr	r1, .L9+16
	bl	device_printf
	ldr	r3, .L9+20
	ldr	r0, [r3]
	b	.L1
.L8:
	bl	__stack_chk_fail
.L10:
	.align	2
.L9:
	.word	.LC2
	.word	SYS_RES_MEMORY
	.word	RF_ACTIVE
	.word	.LC1
	.word	.LC0
	.word	ENXIO
	.size	ar5315_spi_attach, .-ar5315_spi_attach
	.comm	SYS_RES_MEMORY,4,4
	.comm	RF_ACTIVE,4,4
	.comm	ENXIO,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
