	.file	"extr_if_jme.c_jme_dma_alloc.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"could not create parent ring DMA tag.\n"
	.align 8
.LC1:
	.string	"could not allocate Tx ring DMA tag.\n"
	.align 8
.LC2:
	.string	"could not allocate Rx ring DMA tag.\n"
	.align 8
.LC3:
	.string	"could not allocate DMA'able memory for Tx ring.\n"
	.align 8
.LC4:
	.string	"could not load DMA'able memory for Tx ring.\n"
	.align 8
.LC5:
	.string	"could not allocate DMA'able memory for Rx ring.\n"
	.align 8
.LC6:
	.string	"could not load DMA'able memory for Rx ring.\n"
	.align 8
.LC7:
	.string	"4GB boundary crossed, switching to 32bit DMA address mode.\n"
	.align 8
.LC8:
	.string	"could not create parent buffer DMA tag.\n"
	.align 8
.LC9:
	.string	"could not create shared status block DMA tag.\n"
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC10:
	.string	"could not create Tx DMA tag.\n"
.LC11:
	.string	"could not create Rx DMA tag.\n"
	.section	.rodata.str1.8
	.align 8
.LC12:
	.string	"could not allocate DMA'able memory for shared status block.\n"
	.align 8
.LC13:
	.string	"could not load DMA'able memory for shared status block.\n"
	.section	.rodata.str1.1
.LC14:
	.string	"could not create Tx dmamap.\n"
	.section	.rodata.str1.8
	.align 8
.LC15:
	.string	"could not create spare Rx dmamap.\n"
	.section	.rodata.str1.1
.LC16:
	.string	"could not create Rx dmamap.\n"
	.text
	.p2align 4
	.type	jme_dma_alloc, @function
jme_dma_alloc:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	lea	r13, 76[rdi]
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rdi
	sub	rsp, 40
	.cfi_def_cfa_offset 96
	mov	r15, QWORD PTR BUS_SPACE_MAXADDR[rip]
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 24[rsp], rax
	xor	eax, eax
	mov	eax, DWORD PTR [rdi]
	test	DWORD PTR JME_FLAG_DMA32BIT[rip], eax
	lea	rax, 72[rdi]
	mov	rbp, r15
	mov	QWORD PTR 8[rsp], rax
	cmovne	rbp, QWORD PTR BUS_SPACE_MAXADDR_32BIT[rip]
	jmp	.L15
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rax, QWORD PTR JME_TX_RING_SIZE[rip]
	push	QWORD PTR 8[rsp]
	.cfi_def_cfa_offset 104
	xor	r9d, r9d
	xor	edx, edx
	mov	rcx, QWORD PTR BUS_SPACE_MAXADDR[rip]
	push	0
	.cfi_def_cfa_offset 112
	mov	edi, DWORD PTR 76[rbx]
	mov	esi, DWORD PTR JME_TX_RING_ALIGN[rip]
	push	0
	.cfi_def_cfa_offset 120
	push	0
	.cfi_def_cfa_offset 128
	mov	r8, rcx
	push	rax
	.cfi_def_cfa_offset 136
	push	1
	.cfi_def_cfa_offset 144
	push	rax
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L45
	mov	rax, QWORD PTR JME_RX_RING_SIZE[rip]
	mov	edi, DWORD PTR 76[rbx]
	xor	r9d, r9d
	mov	rcx, rbp
	lea	rdx, 64[rbx]
	mov	r8, QWORD PTR BUS_SPACE_MAXADDR[rip]
	mov	esi, DWORD PTR JME_RX_RING_ALIGN[rip]
	push	rdx
	.cfi_def_cfa_offset 104
	xor	edx, edx
	push	0
	.cfi_def_cfa_offset 112
	push	0
	.cfi_def_cfa_offset 120
	push	0
	.cfi_def_cfa_offset 128
	push	rax
	.cfi_def_cfa_offset 136
	push	1
	.cfi_def_cfa_offset 144
	push	rax
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L46
	mov	edi, DWORD PTR 72[rbx]
	mov	edx, DWORD PTR BUS_DMA_WAITOK[rip]
	lea	rcx, 68[rbx]
	lea	rsi, 112[rbx]
	or	edx, DWORD PTR BUS_DMA_ZERO[rip]
	or	edx, DWORD PTR BUS_DMA_COHERENT[rip]
	call	bus_dmamem_alloc@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L47
	mov	eax, DWORD PTR BUS_DMA_NOWAIT[rip]
	lea	r15, 16[rsp]
	sub	rsp, 8
	.cfi_def_cfa_offset 104
	mov	edx, DWORD PTR 112[rbx]
	mov	QWORD PTR 24[rsp], 0
	mov	esi, DWORD PTR 68[rbx]
	mov	r9, r15
	mov	edi, DWORD PTR 72[rbx]
	mov	r8d, DWORD PTR jme_dmamap_cb[rip]
	push	rax
	.cfi_def_cfa_offset 112
	mov	rcx, QWORD PTR JME_TX_RING_SIZE[rip]
	call	bus_dmamap_load@PLT
	pop	r9
	.cfi_def_cfa_offset 104
	pop	r10
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L8
	mov	rax, QWORD PTR 16[rsp]
	test	rax, rax
	je	.L8
	mov	QWORD PTR 80[rbx], rax
	mov	edi, DWORD PTR 64[rbx]
	lea	rcx, 60[rbx]
	lea	rsi, 108[rbx]
	mov	edx, DWORD PTR BUS_DMA_WAITOK[rip]
	or	edx, DWORD PTR BUS_DMA_ZERO[rip]
	or	edx, DWORD PTR BUS_DMA_COHERENT[rip]
	call	bus_dmamem_alloc@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L48
	mov	eax, DWORD PTR BUS_DMA_NOWAIT[rip]
	sub	rsp, 8
	.cfi_def_cfa_offset 104
	mov	edi, DWORD PTR 64[rbx]
	mov	r9, r15
	mov	QWORD PTR 24[rsp], 0
	mov	r8d, DWORD PTR jme_dmamap_cb[rip]
	mov	edx, DWORD PTR 108[rbx]
	mov	esi, DWORD PTR 60[rbx]
	push	rax
	.cfi_def_cfa_offset 112
	mov	rcx, QWORD PTR JME_RX_RING_SIZE[rip]
	call	bus_dmamap_load@PLT
	pop	rdi
	.cfi_def_cfa_offset 104
	pop	r8
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L11
	mov	r14, QWORD PTR 16[rsp]
	test	r14, r14
	je	.L11
	cmp	QWORD PTR BUS_SPACE_MAXADDR_32BIT[rip], rbp
	mov	QWORD PTR 88[rbx], r14
	je	.L13
	mov	rdi, QWORD PTR JME_TX_RING_SIZE[rip]
	add	rdi, QWORD PTR 80[rbx]
	mov	rbp, QWORD PTR JME_RX_RING_SIZE[rip]
	call	JME_ADDR_HI@PLT
	mov	rdi, QWORD PTR 80[rbx]
	mov	r12, rax
	call	JME_ADDR_HI@PLT
	cmp	r12, rax
	jne	.L16
	lea	rdi, [r14+rbp]
	call	JME_ADDR_HI@PLT
	mov	rdi, QWORD PTR 88[rbx]
	mov	rbp, rax
	call	JME_ADDR_HI@PLT
	cmp	rbp, rax
	je	.L13
.L16:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC7[rip]
	call	device_printf@PLT
	mov	rdi, rbx
	call	jme_dma_free@PLT
	mov	rbp, QWORD PTR BUS_SPACE_MAXADDR_32BIT[rip]
	mov	r15, QWORD PTR BUS_SPACE_MAXADDR[rip]
.L15:
	mov	r12, QWORD PTR BUS_SPACE_MAXSIZE_32BIT[rip]
	mov	edi, DWORD PTR 4[rbx]
	call	bus_get_dma_tag@PLT
	push	r13
	.cfi_def_cfa_offset 104
	xor	r9d, r9d
	mov	r8, r15
	push	0
	.cfi_def_cfa_offset 112
	mov	edi, eax
	mov	rcx, rbp
	xor	edx, edx
	push	0
	.cfi_def_cfa_offset 120
	mov	esi, 1
	push	0
	.cfi_def_cfa_offset 128
	push	r12
	.cfi_def_cfa_offset 136
	push	0
	.cfi_def_cfa_offset 144
	push	r12
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	je	.L3
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC0[rip]
	call	device_printf@PLT
.L4:
	.p2align 4,,10
	.p2align 3
.L1:
	mov	rax, QWORD PTR 24[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L49
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC4[rip]
	call	device_printf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L11:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC6[rip]
	call	device_printf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L13:
	mov	rbp, QWORD PTR BUS_SPACE_MAXADDR[rip]
	mov	edi, DWORD PTR 4[rbx]
	mov	r12, QWORD PTR BUS_SPACE_MAXSIZE_32BIT[rip]
	mov	eax, DWORD PTR [rbx]
	mov	r13, rbp
	test	DWORD PTR JME_FLAG_DMA32BIT[rip], eax
	cmovne	r13, QWORD PTR BUS_SPACE_MAXADDR_32BIT[rip]
	call	bus_get_dma_tag@PLT
	xor	r9d, r9d
	mov	r8, rbp
	xor	edx, edx
	mov	edi, eax
	lea	rax, 56[rbx]
	mov	rcx, r13
	mov	esi, 1
	push	rax
	.cfi_def_cfa_offset 104
	push	0
	.cfi_def_cfa_offset 112
	push	0
	.cfi_def_cfa_offset 120
	push	0
	.cfi_def_cfa_offset 128
	push	r12
	.cfi_def_cfa_offset 136
	push	0
	.cfi_def_cfa_offset 144
	push	r12
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L50
	lea	rdx, 52[rbx]
	mov	edi, DWORD PTR 56[rbx]
	mov	esi, DWORD PTR JME_SSB_ALIGN[rip]
	xor	r9d, r9d
	mov	rax, QWORD PTR JME_SSB_SIZE[rip]
	mov	rcx, QWORD PTR BUS_SPACE_MAXADDR[rip]
	push	rdx
	.cfi_def_cfa_offset 104
	xor	edx, edx
	push	0
	.cfi_def_cfa_offset 112
	push	0
	.cfi_def_cfa_offset 120
	mov	r8, rcx
	push	0
	.cfi_def_cfa_offset 128
	push	rax
	.cfi_def_cfa_offset 136
	push	1
	.cfi_def_cfa_offset 144
	push	rax
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L51
	lea	rax, 32[rbx]
	mov	rcx, QWORD PTR BUS_SPACE_MAXADDR[rip]
	mov	edi, DWORD PTR 56[rbx]
	xor	edx, edx
	push	rax
	.cfi_def_cfa_offset 104
	mov	eax, DWORD PTR JME_MAXTXSEGS[rip]
	xor	r9d, r9d
	mov	esi, 1
	push	0
	.cfi_def_cfa_offset 112
	mov	r8, rcx
	push	0
	.cfi_def_cfa_offset 120
	push	0
	.cfi_def_cfa_offset 128
	push	QWORD PTR JME_TSO_MAXSEGSIZE[rip]
	.cfi_def_cfa_offset 136
	push	rax
	.cfi_def_cfa_offset 144
	push	QWORD PTR JME_TSO_MAXSIZE[rip]
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L52
	lea	rdx, 8[rbx]
	mov	edi, DWORD PTR 56[rbx]
	mov	esi, DWORD PTR JME_RX_BUF_ALIGN[rip]
	xor	r9d, r9d
	mov	rax, QWORD PTR MCLBYTES[rip]
	mov	rcx, QWORD PTR BUS_SPACE_MAXADDR[rip]
	push	rdx
	.cfi_def_cfa_offset 104
	xor	edx, edx
	push	0
	.cfi_def_cfa_offset 112
	push	0
	.cfi_def_cfa_offset 120
	mov	r8, rcx
	push	0
	.cfi_def_cfa_offset 128
	push	rax
	.cfi_def_cfa_offset 136
	push	1
	.cfi_def_cfa_offset 144
	push	rax
	.cfi_def_cfa_offset 152
	push	0
	.cfi_def_cfa_offset 160
	call	bus_dma_tag_create@PLT
	add	rsp, 64
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L53
	mov	edi, DWORD PTR 52[rbx]
	mov	edx, DWORD PTR BUS_DMA_WAITOK[rip]
	lea	rcx, 48[rbx]
	lea	rsi, 104[rbx]
	or	edx, DWORD PTR BUS_DMA_ZERO[rip]
	or	edx, DWORD PTR BUS_DMA_COHERENT[rip]
	call	bus_dmamem_alloc@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L54
	mov	eax, DWORD PTR BUS_DMA_NOWAIT[rip]
	sub	rsp, 8
	.cfi_def_cfa_offset 104
	mov	esi, DWORD PTR 48[rbx]
	mov	r9, r15
	mov	QWORD PTR 24[rsp], 0
	mov	rcx, QWORD PTR JME_SSB_SIZE[rip]
	mov	edx, DWORD PTR 104[rbx]
	mov	edi, DWORD PTR 52[rbx]
	push	rax
	.cfi_def_cfa_offset 112
	mov	r8d, DWORD PTR jme_dmamap_cb[rip]
	call	bus_dmamap_load@PLT
	pop	rcx
	.cfi_def_cfa_offset 104
	pop	rsi
	.cfi_def_cfa_offset 96
	mov	r12d, eax
	test	eax, eax
	jne	.L23
	mov	rax, QWORD PTR 16[rsp]
	test	rax, rax
	je	.L23
	mov	edx, DWORD PTR JME_TX_RING_CNT[rip]
	mov	QWORD PTR 96[rbx], rax
	xor	ebp, ebp
	test	edx, edx
	jg	.L25
	jmp	.L29
	.p2align 4,,10
	.p2align 3
.L28:
	add	rbp, 1
	cmp	DWORD PTR JME_TX_RING_CNT[rip], ebp
	jle	.L29
.L25:
	mov	rdx, rbp
	mov	edi, DWORD PTR 32[rbx]
	xor	esi, esi
	sal	rdx, 4
	add	rdx, QWORD PTR 40[rbx]
	mov	QWORD PTR 8[rdx], 0
	mov	QWORD PTR [rdx], 0
	call	bus_dmamap_create@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L28
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC14[rip]
	call	device_printf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L45:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC1[rip]
	call	device_printf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L46:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC2[rip]
	call	device_printf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L47:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC3[rip]
	call	device_printf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L48:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC5[rip]
	call	device_printf@PLT
	jmp	.L1
.L52:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC10[rip]
	call	device_printf@PLT
	jmp	.L1
.L50:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC8[rip]
	call	device_printf@PLT
	jmp	.L1
.L51:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC9[rip]
	call	device_printf@PLT
	jmp	.L1
.L53:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC11[rip]
	call	device_printf@PLT
	jmp	.L1
.L54:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC12[rip]
	call	device_printf@PLT
	jmp	.L1
.L23:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC13[rip]
	call	device_printf@PLT
	jmp	.L1
.L29:
	mov	edi, DWORD PTR 8[rbx]
	lea	rdx, 24[rbx]
	xor	esi, esi
	call	bus_dmamap_create@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L55
	mov	eax, DWORD PTR JME_RX_RING_CNT[rip]
	xor	r13d, r13d
	test	eax, eax
	jg	.L30
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L31:
	add	r13, 1
	cmp	DWORD PTR JME_RX_RING_CNT[rip], r13d
	jle	.L1
.L30:
	mov	rdx, r13
	mov	edi, DWORD PTR 8[rbx]
	xor	esi, esi
	sal	rdx, 4
	add	rdx, QWORD PTR 16[rbx]
	mov	QWORD PTR 8[rdx], 0
	mov	QWORD PTR [rdx], 0
	call	bus_dmamap_create@PLT
	mov	ebp, eax
	test	eax, eax
	je	.L31
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC16[rip]
	mov	r12d, ebp
	call	device_printf@PLT
	jmp	.L1
.L55:
	mov	edi, DWORD PTR 4[rbx]
	lea	rsi, .LC15[rip]
	call	device_printf@PLT
	jmp	.L1
.L49:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	jme_dma_alloc, .-jme_dma_alloc
	.comm	jme_dmamap_cb,4,4
	.comm	MCLBYTES,8,8
	.comm	JME_TX_RING_SIZE,8,8
	.comm	JME_TX_RING_CNT,4,4
	.comm	JME_TX_RING_ALIGN,4,4
	.comm	JME_TSO_MAXSIZE,8,8
	.comm	JME_TSO_MAXSEGSIZE,8,8
	.comm	JME_SSB_SIZE,8,8
	.comm	JME_SSB_ALIGN,4,4
	.comm	JME_RX_RING_SIZE,8,8
	.comm	JME_RX_RING_CNT,4,4
	.comm	JME_RX_RING_ALIGN,4,4
	.comm	JME_RX_BUF_ALIGN,4,4
	.comm	JME_MAXTXSEGS,4,4
	.comm	JME_FLAG_DMA32BIT,4,4
	.comm	BUS_SPACE_MAXSIZE_32BIT,8,8
	.comm	BUS_SPACE_MAXADDR_32BIT,8,8
	.comm	BUS_SPACE_MAXADDR,8,8
	.comm	BUS_DMA_ZERO,4,4
	.comm	BUS_DMA_WAITOK,4,4
	.comm	BUS_DMA_NOWAIT,4,4
	.comm	BUS_DMA_COHERENT,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_if_jme.c_jme_dma_alloc.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"could not create parent ring DMA tag.\012\000"
	.align	2
.LC1:
	.ascii	"could not allocate Tx ring DMA tag.\012\000"
	.align	2
.LC2:
	.ascii	"could not allocate Rx ring DMA tag.\012\000"
	.align	2
.LC3:
	.ascii	"could not allocate DMA'able memory for Tx ring.\012"
	.ascii	"\000"
	.align	2
.LC4:
	.ascii	"could not load DMA'able memory for Tx ring.\012\000"
	.align	2
.LC5:
	.ascii	"could not allocate DMA'able memory for Rx ring.\012"
	.ascii	"\000"
	.align	2
.LC6:
	.ascii	"could not load DMA'able memory for Rx ring.\012\000"
	.align	2
.LC7:
	.ascii	"4GB boundary crossed, switching to 32bit DMA addres"
	.ascii	"s mode.\012\000"
	.align	2
.LC8:
	.ascii	"could not create parent buffer DMA tag.\012\000"
	.align	2
.LC9:
	.ascii	"could not create shared status block DMA tag.\012\000"
	.align	2
.LC10:
	.ascii	"could not create Tx DMA tag.\012\000"
	.align	2
.LC11:
	.ascii	"could not create Rx DMA tag.\012\000"
	.align	2
.LC12:
	.ascii	"could not allocate DMA'able memory for shared statu"
	.ascii	"s block.\012\000"
	.align	2
.LC13:
	.ascii	"could not load DMA'able memory for shared status bl"
	.ascii	"ock.\012\000"
	.align	2
.LC14:
	.ascii	"could not create Tx dmamap.\012\000"
	.align	2
.LC15:
	.ascii	"could not create spare Rx dmamap.\012\000"
	.align	2
.LC16:
	.ascii	"could not create Rx dmamap.\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC17:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	jme_dma_alloc, %function
jme_dma_alloc:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldr	r3, .L58
	ldr	r2, [r0]
	ldr	r3, [r3]
	sub	sp, sp, #60
	tst	r2, r3
	ldr	r3, .L58+4
	ldr	r7, .L58+8
	ldr	r3, [r3]
	str	r3, [sp, #52]
	mov	r3,#0
	ldrne	r3, .L58+12
	ldr	r6, [r7]
	ldrne	r6, [r3]
	add	r3, r0, #56
	mov	r5, r0
	ldr	fp, .L58+16
	str	r3, [sp, #44]
	b	.L15
.L3:
	mov	r8, #1
	ldr	r0, [fp]
	ldr	r3, [r7]
	add	r1, r5, #52
	str	r1, [sp, #36]
	ldr	r1, .L58+20
	str	r4, [sp, #32]
	str	r4, [sp, #28]
	str	r4, [sp, #24]
	str	r4, [sp, #8]
	str	r4, [sp, #4]
	str	r8, [sp, #16]
	str	r3, [sp]
	str	r0, [sp, #20]
	str	r0, [sp, #12]
	mov	r2, r4
	ldr	r1, [r1]
	ldr	r0, [r5, #56]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	bne	.L47
	ldr	r3, .L58+24
	ldr	r0, [r7]
	ldr	r1, [r3]
	add	r3, r5, #44
	str	r1, [sp, #20]
	str	r1, [sp, #12]
	ldr	r1, .L58+28
	str	r4, [sp, #32]
	str	r4, [sp, #28]
	str	r4, [sp, #24]
	str	r4, [sp, #8]
	str	r4, [sp, #4]
	str	r3, [sp, #36]
	str	r8, [sp, #16]
	str	r0, [sp]
	mov	r2, r4
	mov	r3, r6
	ldr	r1, [r1]
	ldr	r0, [r5, #56]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	bne	.L48
	ldr	r2, .L58+32
	ldr	r3, .L58+36
	ldr	r8, .L58+40
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, [r8]
	orr	r3, r3, r1
	orr	r2, r3, r2
	ldr	r0, [r5, #52]
	add	r3, r5, #48
	add	r1, r5, #80
	bl	bus_dmamem_alloc
	subs	r4, r0, #0
	bne	.L49
	ldr	r9, .L58+44
	ldr	r10, .L58+48
	ldr	r3, [r9]
	ldr	r2, [r10]
	str	r3, [sp]
	add	r3, sp, #48
	str	r2, [sp, #8]
	str	r3, [sp, #4]
	ldr	r3, [fp]
	ldr	r2, [r5, #80]
	ldr	r1, [r5, #48]
	ldr	r0, [r5, #52]
	str	r4, [sp, #48]
	bl	bus_dmamap_load
	subs	r4, r0, #0
	bne	.L8
	ldr	r4, [sp, #48]
	cmp	r4, #0
	beq	.L8
	ldr	r2, .L58+32
	ldr	r3, .L58+36
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, [r8]
	orr	r3, r3, r1
	str	r4, [r5, #60]
	orr	r2, r3, r2
	ldr	r0, [r5, #44]
	add	r3, r5, #40
	add	r1, r5, #76
	bl	bus_dmamem_alloc
	subs	r4, r0, #0
	bne	.L50
	ldr	r2, [r10]
	ldr	r3, [r9]
	add	r1, sp, #48
	stmib	sp, {r1, r2}
	str	r3, [sp]
	ldr	r3, .L58+24
	ldr	r2, [r5, #76]
	ldr	r3, [r3]
	ldr	r1, [r5, #40]
	ldr	r0, [r5, #44]
	str	r4, [sp, #48]
	bl	bus_dmamap_load
	subs	r4, r0, #0
	bne	.L11
	ldr	r4, [sp, #48]
	cmp	r4, #0
	beq	.L11
	ldr	r3, .L58+12
	str	r4, [r5, #64]
	ldr	r3, [r3]
	cmp	r3, r6
	beq	.L13
	ldr	r2, .L58+24
	ldr	r3, [fp]
	ldr	r0, [r5, #60]
	ldr	r2, [r2]
	add	r0, r0, r3
	str	r2, [sp, #40]
	bl	JME_ADDR_HI
	mov	r6, r0
	ldr	r0, [r5, #60]
	bl	JME_ADDR_HI
	cmp	r6, r0
	bne	.L16
	ldr	r3, [sp, #40]
	add	r0, r4, r3
	bl	JME_ADDR_HI
	mov	r4, r0
	ldr	r0, [r5, #64]
	bl	JME_ADDR_HI
	cmp	r4, r0
	beq	.L13
.L16:
	ldr	r1, .L58+52
	ldr	r0, [r5, #4]
	bl	device_printf
	mov	r0, r5
	bl	jme_dma_free
	ldr	r3, .L58+12
	ldr	r6, [r3]
.L15:
	ldr	r0, [r5, #4]
	bl	bus_get_dma_tag
	mov	r2, #0
	ldr	r3, .L58+56
	ldr	r1, [r7]
	ldr	r3, [r3]
	ldr	ip, [sp, #44]
	str	r3, [sp, #20]
	str	r3, [sp, #12]
	str	r1, [sp]
	mov	r3, r6
	mov	r1, #1
	str	ip, [sp, #36]
	str	r2, [sp, #32]
	str	r2, [sp, #28]
	str	r2, [sp, #24]
	str	r2, [sp, #16]
	str	r2, [sp, #8]
	str	r2, [sp, #4]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	beq	.L3
	ldr	r0, [r5, #4]
	ldr	r1, .L58+60
	bl	device_printf
.L4:
.L1:
	ldr	r3, .L58+4
	ldr	r2, [r3]
	ldr	r3, [sp, #52]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L51
	mov	r0, r4
	add	sp, sp, #60
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L8:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+64
	bl	device_printf
	b	.L1
.L11:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+68
	bl	device_printf
	b	.L1
.L13:
	ldr	r3, .L58
	ldr	r2, [r5]
	ldr	r3, [r3]
	ldr	r0, [r5, #4]
	tst	r2, r3
	ldrne	r3, .L58+12
	ldr	r4, [r7]
	ldrne	r4, [r3]
	bl	bus_get_dma_tag
	mov	r2, #0
	ldr	r3, .L58+56
	ldr	ip, [r7]
	ldr	r3, [r3]
	add	r1, r5, #36
	str	r3, [sp, #20]
	str	r3, [sp, #12]
	str	r1, [sp, #36]
	mov	r3, r4
	mov	r1, #1
	str	r2, [sp, #32]
	str	r2, [sp, #28]
	str	r2, [sp, #24]
	str	r2, [sp, #16]
	str	r2, [sp, #8]
	str	r2, [sp, #4]
	str	ip, [sp]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	bne	.L52
	mov	r6, #1
	ldr	fp, .L58+72
	ldr	r3, [r7]
	ldr	r1, [fp]
	ldr	ip, .L58+76
	str	r4, [sp, #32]
	str	r4, [sp, #28]
	str	r4, [sp, #24]
	str	r4, [sp, #8]
	str	r4, [sp, #4]
	str	r1, [sp, #20]
	str	r1, [sp, #12]
	str	r6, [sp, #16]
	str	r3, [sp]
	add	r0, r5, #32
	ldr	r1, [ip]
	str	r0, [sp, #36]
	mov	r2, r4
	ldr	r0, [r5, #36]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	bne	.L53
	ldr	r1, .L58+80
	ldr	r2, .L58+84
	ldr	r3, .L58+88
	ldr	r1, [r1]
	ldr	r0, [r3]
	ldr	ip, [r2]
	ldr	r3, [r7]
	str	r1, [sp, #20]
	add	r1, r5, #20
	str	r4, [sp, #32]
	str	r4, [sp, #28]
	str	r4, [sp, #24]
	str	r4, [sp, #8]
	str	r4, [sp, #4]
	str	r1, [sp, #36]
	str	ip, [sp, #16]
	str	r0, [sp, #12]
	str	r3, [sp]
	mov	r2, r4
	mov	r1, r6
	ldr	r0, [r5, #36]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	bne	.L54
	ldr	r2, .L58+92
	ldr	r3, [r7]
	ldr	r1, [r2]
	ldr	ip, .L58+96
	str	r4, [sp, #32]
	str	r4, [sp, #28]
	str	r4, [sp, #24]
	str	r4, [sp, #8]
	str	r4, [sp, #4]
	str	r3, [sp]
	str	r6, [sp, #16]
	str	r1, [sp, #20]
	str	r1, [sp, #12]
	add	r0, r5, #8
	ldr	r1, [ip]
	str	r0, [sp, #36]
	mov	r2, r4
	ldr	r0, [r5, #36]
	bl	bus_dma_tag_create
	subs	r4, r0, #0
	bne	.L55
	ldr	r2, .L58+32
	ldr	r3, .L58+36
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, [r8]
	orr	r3, r3, r1
	orr	r2, r3, r2
	ldr	r0, [r5, #32]
	add	r3, r5, #28
	add	r1, r5, #72
	bl	bus_dmamem_alloc
	subs	r4, r0, #0
	bne	.L56
	ldr	r3, [r9]
	ldr	r2, [r10]
	str	r3, [sp]
	add	r3, sp, #48
	str	r2, [sp, #8]
	str	r3, [sp, #4]
	ldr	r3, [fp]
	ldr	r2, [r5, #72]
	ldr	r1, [r5, #28]
	ldr	r0, [r5, #32]
	str	r4, [sp, #48]
	bl	bus_dmamap_load
	subs	r4, r0, #0
	bne	.L23
	ldr	r3, [sp, #48]
	cmp	r3, #0
	beq	.L23
	ldr	r7, .L58+100
	str	r3, [r5, #68]
	ldr	r3, [r7]
	cmp	r3, #0
	ble	.L29
	mov	r6, r4
	b	.L25
.L28:
	ldr	r3, [r7]
	add	r4, r4, #1
	cmp	r3, r4
	ble	.L29
.L25:
	ldr	r3, [r5, #24]
	mov	r1, #0
	add	r2, r3, r4, lsl #3
	str	r6, [r2, #4]
	ldr	r0, [r5, #20]
	str	r6, [r3, r4, lsl #3]
	bl	bus_dmamap_create
	subs	r3, r0, #0
	beq	.L28
	ldr	r0, [r5, #4]
	ldr	r1, .L58+104
	mov	r4, r3
	bl	device_printf
	b	.L1
.L47:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+108
	bl	device_printf
	b	.L1
.L48:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+112
	bl	device_printf
	b	.L1
.L49:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+116
	bl	device_printf
	b	.L1
.L50:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+120
	bl	device_printf
	b	.L1
.L54:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+124
	bl	device_printf
	b	.L1
.L52:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+128
	bl	device_printf
	b	.L1
.L53:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+132
	bl	device_printf
	b	.L1
.L55:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+136
	bl	device_printf
	b	.L1
.L56:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+140
	bl	device_printf
	b	.L1
.L23:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+144
	bl	device_printf
	b	.L1
.L29:
	mov	r1, #0
	ldr	r0, [r5, #8]
	add	r2, r5, #16
	bl	bus_dmamap_create
	subs	r4, r0, #0
	bne	.L57
	ldr	r8, .L58+148
	ldr	r3, [r8]
	cmp	r3, #0
	movgt	r6, r4
	movgt	r7, r4
	bgt	.L30
	b	.L1
.L31:
	ldr	r3, [r8]
	add	r6, r6, #1
	cmp	r3, r6
	ble	.L1
.L30:
	ldr	r3, [r5, #12]
	mov	r1, #0
	add	r2, r3, r6, lsl #3
	str	r7, [r2, #4]
	ldr	r0, [r5, #8]
	str	r7, [r3, r6, lsl #3]
	bl	bus_dmamap_create
	subs	r3, r0, #0
	beq	.L31
	ldr	r0, [r5, #4]
	ldr	r1, .L58+152
	mov	r4, r3
	bl	device_printf
	b	.L1
.L57:
	ldr	r0, [r5, #4]
	ldr	r1, .L58+156
	bl	device_printf
	b	.L1
.L51:
	bl	__stack_chk_fail
.L59:
	.align	2
.L58:
	.word	JME_FLAG_DMA32BIT
	.word	.LC17
	.word	BUS_SPACE_MAXADDR
	.word	BUS_SPACE_MAXADDR_32BIT
	.word	JME_TX_RING_SIZE
	.word	JME_TX_RING_ALIGN
	.word	JME_RX_RING_SIZE
	.word	JME_RX_RING_ALIGN
	.word	BUS_DMA_ZERO
	.word	BUS_DMA_WAITOK
	.word	BUS_DMA_COHERENT
	.word	jme_dmamap_cb
	.word	BUS_DMA_NOWAIT
	.word	.LC7
	.word	BUS_SPACE_MAXSIZE_32BIT
	.word	.LC0
	.word	.LC4
	.word	.LC6
	.word	JME_SSB_SIZE
	.word	JME_SSB_ALIGN
	.word	JME_TSO_MAXSEGSIZE
	.word	JME_MAXTXSEGS
	.word	JME_TSO_MAXSIZE
	.word	MCLBYTES
	.word	JME_RX_BUF_ALIGN
	.word	JME_TX_RING_CNT
	.word	.LC14
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC5
	.word	.LC10
	.word	.LC8
	.word	.LC9
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	JME_RX_RING_CNT
	.word	.LC16
	.word	.LC15
	.size	jme_dma_alloc, .-jme_dma_alloc
	.comm	jme_dmamap_cb,4,4
	.comm	MCLBYTES,4,4
	.comm	JME_TX_RING_SIZE,4,4
	.comm	JME_TX_RING_CNT,4,4
	.comm	JME_TX_RING_ALIGN,4,4
	.comm	JME_TSO_MAXSIZE,4,4
	.comm	JME_TSO_MAXSEGSIZE,4,4
	.comm	JME_SSB_SIZE,4,4
	.comm	JME_SSB_ALIGN,4,4
	.comm	JME_RX_RING_SIZE,4,4
	.comm	JME_RX_RING_CNT,4,4
	.comm	JME_RX_RING_ALIGN,4,4
	.comm	JME_RX_BUF_ALIGN,4,4
	.comm	JME_MAXTXSEGS,4,4
	.comm	JME_FLAG_DMA32BIT,4,4
	.comm	BUS_SPACE_MAXSIZE_32BIT,4,4
	.comm	BUS_SPACE_MAXADDR_32BIT,4,4
	.comm	BUS_SPACE_MAXADDR,4,4
	.comm	BUS_DMA_ZERO,4,4
	.comm	BUS_DMA_WAITOK,4,4
	.comm	BUS_DMA_NOWAIT,4,4
	.comm	BUS_DMA_COHERENT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
