	.file	"extr_hns3_enet.c_hns3_map_buffer.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	hns3_map_buffer, @function
hns3_map_buffer:
.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	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	rbx, rsi
	call	ring_to_dma_dir@PLT
	mov	r14d, DWORD PTR 4[rbx]
	mov	r13d, DWORD PTR 8[rbx]
	mov	rdi, rbp
	mov	r12d, eax
	call	ring_to_dev@PLT
	mov	r8d, r12d
	mov	ecx, r14d
	xor	edx, edx
	mov	esi, r13d
	mov	edi, eax
	call	dma_map_page@PLT
	mov	rdi, rbp
	mov	DWORD PTR [rbx], eax
	mov	r12d, eax
	call	ring_to_dev@PLT
	mov	esi, r12d
	mov	edi, eax
	call	dma_mapping_error@PLT
	mov	edi, eax
	call	unlikely@PLT
	mov	r8, rax
	mov	eax, DWORD PTR EIO[rip]
	neg	eax
	test	r8, r8
	jne	.L1
	xor	eax, eax
.L1:
	pop	rbx
	.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
	.cfi_endproc
.LFE0:
	.size	hns3_map_buffer, .-hns3_map_buffer
	.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_hns3_enet.c_hns3_map_buffer.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	hns3_map_buffer, %function
hns3_map_buffer:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	sub	sp, sp, #8
	mov	r4, r1
	mov	r5, r0
	bl	ring_to_dev
	mov	r6, r0
	mov	r0, r5
	ldr	r7, [r4, #8]
	ldr	r8, [r4, #4]
	bl	ring_to_dma_dir
	mov	r2, r0
	mov	r1, r7
	mov	r3, r8
	str	r2, [sp]
	mov	r0, r6
	mov	r2, #0
	bl	dma_map_page
	mov	r3, r0
	mov	r0, r5
	str	r3, [r4]
	bl	ring_to_dev
	ldr	r1, [r4]
	bl	dma_mapping_error
	bl	unlikely
	cmp	r0, #0
	ldrne	r3, .L8
	ldrne	r0, [r3]
	rsbne	r0, r0, #0
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L9:
	.align	2
.L8:
	.word	EIO
	.size	hns3_map_buffer, .-hns3_map_buffer
	.comm	EIO,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
