	.file	"extr_inode.c_bfs_write_inode.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"ino=%08x\n"
.LC1:
	.string	"Bad inode number %s:%08x\n"
.LC2:
	.string	"Unable to read inode %s:%08x\n"
	.text
	.p2align 4
	.type	bfs_write_inode, @function
bfs_write_inode:
.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
	mov	r13, rsi
	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, 8
	.cfi_def_cfa_offset 64
	mov	rdi, QWORD PTR 64[rdi]
	call	BFS_SB@PLT
	mov	r12d, DWORD PTR 72[rbx]
	lea	rdi, .LC0[rip]
	mov	r14, rax
	mov	esi, r12d
	call	dprintf@PLT
	cmp	DWORD PTR BFS_ROOT_INO[rip], r12d
	ja	.L4
	mov	rdi, QWORD PTR 64[rbx]
	call	BFS_SB@PLT
	cmp	DWORD PTR [rax], r12d
	jnb	.L16
.L4:
	mov	rax, QWORD PTR 64[rbx]
	mov	edx, r12d
	lea	rdi, .LC1[rip]
	mov	rsi, QWORD PTR [rax]
	call	printf@PLT
	mov	r12d, DWORD PTR EIO[rip]
	neg	r12d
.L1:
	add	rsp, 8
	.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
.L16:
	.cfi_restore_state
	add	r14, 4
	mov	rdi, r14
	call	mutex_lock@PLT
	mov	eax, r12d
	xor	edx, edx
	sub	eax, DWORD PTR BFS_ROOT_INO[rip]
	div	DWORD PTR BFS_INODES_PER_BLOCK[rip]
	mov	rdi, QWORD PTR 64[rbx]
	lea	esi, 1[rax]
	call	sb_bread@PLT
	mov	r15, rax
	test	rax, rax
	je	.L17
	mov	ecx, DWORD PTR BFS_ROOT_INO[rip]
	mov	eax, r12d
	xor	edx, edx
	sub	eax, ecx
	div	DWORD PTR BFS_INODES_PER_BLOCK[rip]
	movsx	rdx, edx
	lea	rbp, [rdx+rdx*2]
	sal	rbp, 5
	add	rbp, QWORD PTR [r15]
	cmp	ecx, r12d
	je	.L18
	mov	rdi, QWORD PTR BFS_VREG[rip]
	call	cpu_to_le32@PLT
	mov	QWORD PTR 88[rbp], rax
.L7:
	mov	edi, r12d
	call	cpu_to_le16@PLT
	mov	rdi, QWORD PTR [rbx]
	mov	DWORD PTR 80[rbp], eax
	call	cpu_to_le32@PLT
	mov	rdi, QWORD PTR 8[rbx]
	mov	QWORD PTR 72[rbp], rax
	call	cpu_to_le32@PLT
	mov	rdi, QWORD PTR 16[rbx]
	mov	QWORD PTR 64[rbp], rax
	call	cpu_to_le32@PLT
	mov	rdi, QWORD PTR 24[rbx]
	mov	QWORD PTR 56[rbp], rax
	call	cpu_to_le32@PLT
	mov	rdi, QWORD PTR 56[rbx]
	mov	QWORD PTR 48[rbp], rax
	call	cpu_to_le32@PLT
	mov	rdi, QWORD PTR 48[rbx]
	mov	QWORD PTR 40[rbp], rax
	call	cpu_to_le32@PLT
	mov	rdi, QWORD PTR 40[rbx]
	mov	QWORD PTR 32[rbp], rax
	call	cpu_to_le32@PLT
	mov	rdi, rbx
	mov	QWORD PTR 24[rbp], rax
	call	BFS_I@PLT
	mov	r12, QWORD PTR [rax]
	mov	rdi, r12
	call	cpu_to_le32@PLT
	mov	rdi, rbx
	mov	QWORD PTR 16[rbp], rax
	call	BFS_I@PLT
	mov	rdi, QWORD PTR 8[rax]
	call	cpu_to_le32@PLT
	imul	r12, QWORD PTR BFS_BSIZE[rip]
	mov	QWORD PTR 8[rbp], rax
	mov	rax, QWORD PTR 32[rbx]
	lea	rdi, -1[r12+rax]
	call	cpu_to_le32@PLT
	mov	rdi, r15
	mov	QWORD PTR 0[rbp], rax
	call	mark_buffer_dirty@PLT
	mov	rax, QWORD PTR WB_SYNC_ALL[rip]
	cmp	QWORD PTR 0[r13], rax
	je	.L8
.L10:
	xor	r12d, r12d
.L9:
	mov	rdi, r15
	call	brelse@PLT
	mov	rdi, r14
	call	mutex_unlock@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L18:
	mov	rdi, QWORD PTR BFS_VDIR[rip]
	call	cpu_to_le32@PLT
	mov	QWORD PTR 88[rbp], rax
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L8:
	mov	rdi, r15
	call	sync_dirty_buffer@PLT
	mov	rdi, r15
	call	buffer_req@PLT
	test	rax, rax
	je	.L10
	mov	rdi, r15
	call	buffer_uptodate@PLT
	test	eax, eax
	jne	.L10
	mov	r12d, DWORD PTR EIO[rip]
	neg	r12d
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L17:
	mov	rax, QWORD PTR 64[rbx]
	mov	edx, r12d
	lea	rdi, .LC2[rip]
	mov	rsi, QWORD PTR [rax]
	call	printf@PLT
	mov	rdi, r14
	call	mutex_unlock@PLT
	mov	r12d, DWORD PTR EIO[rip]
	neg	r12d
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	bfs_write_inode, .-bfs_write_inode
	.comm	WB_SYNC_ALL,8,8
	.comm	EIO,4,4
	.comm	BFS_VREG,8,8
	.comm	BFS_VDIR,8,8
	.comm	BFS_ROOT_INO,4,4
	.comm	BFS_INODES_PER_BLOCK,4,4
	.comm	BFS_BSIZE,8,8
	.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_inode.c_bfs_write_inode.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"ino=%08x\012\000"
	.align	2
.LC1:
	.ascii	"Bad inode number %s:%08x\012\000"
	.global	__aeabi_uidiv
	.align	2
.LC2:
	.ascii	"Unable to read inode %s:%08x\012\000"
	.global	__aeabi_uidivmod
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	bfs_write_inode, %function
bfs_write_inode:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r4, r0
	ldr	r0, [r0, #32]
	mov	r8, r1
	bl	BFS_SB
	ldr	r5, [r4, #36]
	ldr	r10, .L18
	mov	r7, r0
	mov	r1, r5
	ldr	r0, .L18+4
	bl	dprintf
	ldr	r3, [r10]
	cmp	r3, r5
	bhi	.L4
	ldr	r0, [r4, #32]
	bl	BFS_SB
	ldr	r3, [r0]
	cmp	r3, r5
	bcs	.L16
.L4:
	ldr	r3, [r4, #32]
	mov	r2, r5
	ldr	r1, [r3]
	ldr	r0, .L18+8
	bl	printf
	ldr	r3, .L18+12
	ldr	r4, [r3]
	rsb	r4, r4, #0
.L1:
	mov	r0, r4
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L16:
	add	r7, r7, #4
	mov	r0, r7
	bl	mutex_lock
	ldr	r6, .L18+16
	ldr	r0, [r10]
	ldr	r1, [r6]
	sub	r0, r5, r0
	bl	__aeabi_uidiv
	mov	r1, r0
	ldr	r0, [r4, #32]
	add	r1, r1, #1
	bl	sb_bread
	subs	r9, r0, #0
	beq	.L17
	ldr	fp, [r10]
	ldr	r1, [r6]
	sub	r0, r5, fp
	bl	__aeabi_uidivmod
	cmp	fp, r5
	ldreq	r3, .L18+20
	ldrne	r3, .L18+24
	add	r6, r1, r1, lsl #1
	ldr	r0, [r3]
	ldr	r10, [r9]
	bl	cpu_to_le32
	lsl	fp, r6, #4
	add	r6, r10, r6, lsl #4
	str	r0, [r6, #44]
	mov	r0, r5
	bl	cpu_to_le16
	mov	r3, r0
	ldr	r0, [r4]
	str	r3, [r6, #40]
	bl	cpu_to_le32
	mov	r3, r0
	ldr	r0, [r4, #4]
	str	r3, [r6, #36]
	bl	cpu_to_le32
	mov	r3, r0
	ldr	r0, [r4, #8]
	str	r3, [r6, #32]
	bl	cpu_to_le32
	mov	r3, r0
	ldr	r0, [r4, #12]
	str	r3, [r6, #28]
	bl	cpu_to_le32
	mov	r3, r0
	ldr	r0, [r4, #28]
	str	r3, [r6, #24]
	bl	cpu_to_le32
	mov	r3, r0
	ldr	r0, [r4, #24]
	str	r3, [r6, #20]
	bl	cpu_to_le32
	mov	r3, r0
	ldr	r0, [r4, #20]
	str	r3, [r6, #16]
	bl	cpu_to_le32
	mov	r3, r0
	mov	r0, r4
	str	r3, [r6, #12]
	bl	BFS_I
	ldr	r5, [r0]
	mov	r0, r5
	bl	cpu_to_le32
	str	r0, [r6, #8]
	mov	r0, r4
	bl	BFS_I
	ldr	r0, [r0, #4]
	bl	cpu_to_le32
	ldr	r2, .L18+28
	ldr	r3, [r4, #16]
	ldr	r2, [r2]
	sub	r3, r3, #1
	str	r0, [r6, #4]
	mla	r0, r2, r5, r3
	bl	cpu_to_le32
	mov	r3, r0
	mov	r0, r9
	str	r3, [fp, r10]
	bl	mark_buffer_dirty
	ldr	r3, .L18+32
	ldr	r2, [r8]
	ldr	r3, [r3]
	cmp	r2, r3
	beq	.L8
.L10:
	mov	r4, #0
.L9:
	mov	r0, r9
	bl	brelse
	mov	r0, r7
	bl	mutex_unlock
	mov	r0, r4
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L8:
	mov	r0, r9
	bl	sync_dirty_buffer
	mov	r0, r9
	bl	buffer_req
	cmp	r0, #0
	beq	.L10
	mov	r0, r9
	bl	buffer_uptodate
	cmp	r0, #0
	bne	.L10
	ldr	r3, .L18+12
	ldr	r4, [r3]
	rsb	r4, r4, #0
	b	.L9
.L17:
	ldr	r3, [r4, #32]
	mov	r2, r5
	ldr	r1, [r3]
	ldr	r0, .L18+36
	bl	printf
	mov	r0, r7
	bl	mutex_unlock
	ldr	r3, .L18+12
	ldr	r4, [r3]
	rsb	r4, r4, #0
	b	.L1
.L19:
	.align	2
.L18:
	.word	BFS_ROOT_INO
	.word	.LC0
	.word	.LC1
	.word	EIO
	.word	BFS_INODES_PER_BLOCK
	.word	BFS_VDIR
	.word	BFS_VREG
	.word	BFS_BSIZE
	.word	WB_SYNC_ALL
	.word	.LC2
	.size	bfs_write_inode, .-bfs_write_inode
	.comm	WB_SYNC_ALL,4,4
	.comm	EIO,4,4
	.comm	BFS_VREG,4,4
	.comm	BFS_VDIR,4,4
	.comm	BFS_ROOT_INO,4,4
	.comm	BFS_INODES_PER_BLOCK,4,4
	.comm	BFS_BSIZE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
