	.file	"extr_pci.c_nvme_remap_bar.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	nvme_remap_bar, @function
nvme_remap_bar:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rsi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	rbx, rdi
	mov	edi, DWORD PTR 24[rdi]
	call	to_pci_dev@PLT
	mov	r12, rax
	xor	eax, eax
	cmp	QWORD PTR [rbx], rbp
	jb	.L13
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L13:
	.cfi_restore_state
	xor	esi, esi
	mov	rdi, r12
	call	pci_resource_len@PLT
	cmp	rax, rbp
	jb	.L11
	mov	rdi, QWORD PTR 8[rbx]
	test	rdi, rdi
	jne	.L14
.L4:
	xor	esi, esi
	mov	rdi, r12
	call	pci_resource_start@PLT
	mov	rsi, rbp
	mov	edi, eax
	call	ioremap@PLT
	mov	QWORD PTR 8[rbx], rax
	test	rax, rax
	je	.L15
	add	rax, QWORD PTR NVME_REG_DBS[rip]
	mov	QWORD PTR [rbx], rbp
	mov	QWORD PTR 16[rbx], rax
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	mov	QWORD PTR [rbx], 0
.L11:
	mov	eax, DWORD PTR ENOMEM[rip]
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	neg	eax
	ret
	.p2align 4,,10
	.p2align 3
.L14:
	.cfi_restore_state
	call	iounmap@PLT
	jmp	.L4
	.cfi_endproc
.LFE0:
	.size	nvme_remap_bar, .-nvme_remap_bar
	.comm	NVME_REG_DBS,8,8
	.comm	ENOMEM,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_pci.c_nvme_remap_bar.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	nvme_remap_bar, %function
nvme_remap_bar:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	mov	r4, r0
	mov	r5, r1
	ldr	r0, [r0, #12]
	bl	to_pci_dev
	ldr	r3, [r4]
	cmp	r3, r5
	bcc	.L12
	mov	r0, #0
	pop	{r4, r5, r6, pc}
.L12:
	mov	r1, #0
	mov	r6, r0
	bl	pci_resource_len
	cmp	r0, r5
	bcc	.L13
	ldr	r0, [r4, #4]
	cmp	r0, #0
	bne	.L14
.L4:
	mov	r0, r6
	mov	r1, #0
	bl	pci_resource_start
	mov	r1, r5
	bl	ioremap
	mov	r3, r0
	cmp	r0, #0
	ldrne	r2, .L15
	ldreq	r2, .L15+4
	ldrne	r2, [r2]
	str	r0, [r4, #4]
	streq	r0, [r4]
	ldreq	r0, [r2]
	addne	r3, r2, r3
	rsbeq	r0, r0, #0
	strne	r5, [r4]
	strne	r3, [r4, #8]
	movne	r0, #0
	pop	{r4, r5, r6, pc}
.L13:
	ldr	r3, .L15+4
	ldr	r0, [r3]
	rsb	r0, r0, #0
	pop	{r4, r5, r6, pc}
.L14:
	bl	iounmap
	b	.L4
.L16:
	.align	2
.L15:
	.word	NVME_REG_DBS
	.word	ENOMEM
	.size	nvme_remap_bar, .-nvme_remap_bar
	.comm	NVME_REG_DBS,4,4
	.comm	ENOMEM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
