	.file	"777405.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"Error: %s\n"
	.align 8
.LC1:
	.string	"Total sectors written %ld/%ld at %ld.\n"
	.text
	.globl	write_sectors
	.type	write_sectors, @function
write_sectors:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 608
	mov	DWORD PTR -580[rbp], edi
	mov	QWORD PTR -592[rbp], rsi
	mov	QWORD PTR -600[rbp], rdx
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -560[rbp], 0
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	mov	rax, QWORD PTR -600[rbp]
	mov	edx, 420
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -564[rbp], eax
	cmp	DWORD PTR -564[rbp], 0
	jns	.L2
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L12
.L2:
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	mov	eax, DWORD PTR -564[rbp]
	mov	edx, 2
	mov	esi, 0
	mov	edi, eax
	call	lseek@PLT
	mov	QWORD PTR -552[rbp], rax
	cmp	QWORD PTR -552[rbp], 0
	jns	.L4
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, DWORD PTR -564[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 1
	jmp	.L12
.L4:
	mov	eax, DWORD PTR -564[rbp]
	mov	edx, 0
	mov	esi, 0
	mov	edi, eax
	call	lseek@PLT
	test	rax, rax
	jns	.L5
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, DWORD PTR -564[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 1
	jmp	.L12
.L5:
	mov	rax, QWORD PTR -552[rbp]
	lea	rdx, 511[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 9
	mov	QWORD PTR -544[rbp], rax
	cmp	QWORD PTR -544[rbp], 0
	je	.L6
	mov	rax, QWORD PTR -544[rbp]
	jmp	.L7
.L6:
	mov	eax, 1
.L7:
	mov	QWORD PTR -544[rbp], rax
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	mov	rax, QWORD PTR -592[rbp]
	sal	rax, 9
	mov	rcx, rax
	mov	eax, DWORD PTR -580[rbp]
	mov	edx, 0
	mov	rsi, rcx
	mov	edi, eax
	call	lseek@PLT
	mov	QWORD PTR -552[rbp], rax
	cmp	QWORD PTR -552[rbp], 0
	jns	.L9
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, DWORD PTR -564[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 1
	jmp	.L12
.L11:
	mov	rdx, QWORD PTR -536[rbp]
	lea	rcx, -528[rbp]
	mov	eax, DWORD PTR -580[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	test	rax, rax
	js	.L9
	add	QWORD PTR -560[rbp], 1
.L9:
	mov	rax, QWORD PTR -560[rbp]
	cmp	rax, QWORD PTR -544[rbp]
	jge	.L10
	lea	rcx, -528[rbp]
	mov	eax, DWORD PTR -564[rbp]
	mov	edx, 512
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	QWORD PTR -536[rbp], rax
	cmp	QWORD PTR -536[rbp], 0
	jns	.L11
.L10:
	mov	eax, DWORD PTR -564[rbp]
	mov	edi, eax
	call	close@PLT
	mov	rcx, QWORD PTR -592[rbp]
	mov	rdx, QWORD PTR -544[rbp]
	mov	rax, QWORD PTR -560[rbp]
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
.L12:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	write_sectors, .-write_sectors
	.section	.rodata
	.align 8
.LC2:
	.string	"Error: Total sectors written %lu/%lu\n"
	.align 8
.LC3:
	.string	"Total sectors written %lu/%lu\n"
	.text
	.globl	create_floppy
	.type	create_floppy, @function
create_floppy:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 560
	mov	QWORD PTR -552[rbp], rdi
	mov	QWORD PTR -560[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -536[rbp], 0
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	mov	rax, QWORD PTR -552[rbp]
	mov	edx, 420
	mov	esi, 577
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -540[rbp], eax
	cmp	DWORD PTR -540[rbp], 0
	jns	.L15
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L21
.L15:
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	lea	rax, -528[rbp]
	mov	edx, 512
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	jmp	.L17
.L19:
	add	QWORD PTR -536[rbp], 1
.L17:
	mov	rax, QWORD PTR -536[rbp]
	cmp	rax, QWORD PTR -560[rbp]
	jnb	.L18
	lea	rcx, -528[rbp]
	mov	eax, DWORD PTR -540[rbp]
	mov	edx, 512
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	test	rax, rax
	jg	.L19
.L18:
	mov	eax, DWORD PTR -540[rbp]
	mov	edi, eax
	call	close@PLT
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	je	.L20
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, QWORD PTR -560[rbp]
	mov	rdx, QWORD PTR -536[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L21
.L20:
	mov	rdx, QWORD PTR -560[rbp]
	mov	rax, QWORD PTR -536[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
.L21:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L22
	call	__stack_chk_fail@PLT
.L22:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	create_floppy, .-create_floppy
	.section	.rodata
	.align 8
.LC4:
	.string	"Usage: %s <mode> <image> <file> [skip-count]\n"
.LC5:
	.string	"Unknown write mode."
.LC6:
	.string	"Unknown option '%c'.\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 40
	.cfi_offset 3, -24
	mov	DWORD PTR -36[rbp], edi
	mov	QWORD PTR -48[rbp], rsi
	mov	BYTE PTR -25[rbp], 0
	cmp	DWORD PTR -36[rbp], 3
	jle	.L24
	cmp	DWORD PTR -36[rbp], 5
	jle	.L25
.L24:
	mov	rax, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L26
.L25:
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	cmp	eax, 99
	je	.L27
	cmp	eax, 119
	je	.L28
	jmp	.L40
.L27:
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	movsx	rdx, eax
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	rsi, rdx
	mov	rdi, rax
	call	create_floppy
	jmp	.L30
.L28:
	cmp	DWORD PTR -36[rbp], 4
	jne	.L31
	mov	BYTE PTR -25[rbp], 1
	jmp	.L30
.L31:
	cmp	DWORD PTR -36[rbp], 5
	jne	.L33
	mov	BYTE PTR -25[rbp], 2
	jmp	.L30
.L33:
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	eax, 1
	jmp	.L26
.L40:
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 1
	jmp	.L26
.L30:
	cmp	BYTE PTR -25[rbp], 1
	jne	.L34
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	edx, 420
	mov	esi, 2
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -20[rbp], eax
	cmp	DWORD PTR -20[rbp], 0
	jns	.L35
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L26
.L35:
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 24
	mov	rdx, QWORD PTR [rax]
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, 0
	mov	edi, eax
	call	write_sectors
	test	eax, eax
	je	.L36
	mov	eax, DWORD PTR -20[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 1
	jmp	.L26
.L36:
	mov	eax, DWORD PTR -20[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L37
.L34:
	cmp	BYTE PTR -25[rbp], 2
	jne	.L37
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	edx, 420
	mov	esi, 2
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -24[rbp], eax
	cmp	DWORD PTR -24[rbp], 0
	jns	.L38
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L26
.L38:
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 24
	mov	rbx, QWORD PTR [rax]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, 32
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	movsx	rcx, eax
	mov	eax, DWORD PTR -24[rbp]
	mov	rdx, rbx
	mov	rsi, rcx
	mov	edi, eax
	call	write_sectors
	test	eax, eax
	je	.L39
	mov	eax, DWORD PTR -24[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 1
	jmp	.L26
.L39:
	mov	eax, DWORD PTR -24[rbp]
	mov	edi, eax
	call	close@PLT
.L37:
	mov	eax, 0
.L26:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.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, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"777405.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Error: %s\012\000"
	.align	2
.LC1:
	.ascii	"Total sectors written %ld/%ld at %ld.\012\000"
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	write_sectors
	.syntax unified
	.arm
	.fpu softvfp
	.type	write_sectors, %function
write_sectors:
	@ args = 0, pretend = 0, frame = 552
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #556
	str	r0, [fp, #-552]
	str	r1, [fp, #-556]
	str	r2, [fp, #-560]
	ldr	r3, .L14
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-548]
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	mov	r2, #420
	mov	r1, #0
	ldr	r0, [fp, #-560]
	bl	open
	str	r0, [fp, #-544]
	ldr	r3, [fp, #-544]
	cmp	r3, #0
	bge	.L2
	ldr	r3, .L14+4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L14+8
	mov	r0, r4
	bl	fprintf
	mov	r3, #1
	b	.L12
.L2:
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	mov	r2, #2
	mov	r1, #0
	ldr	r0, [fp, #-544]
	bl	lseek
	str	r0, [fp, #-540]
	ldr	r3, [fp, #-540]
	cmp	r3, #0
	bge	.L4
	ldr	r3, .L14+4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L14+8
	mov	r0, r4
	bl	fprintf
	ldr	r0, [fp, #-544]
	bl	close
	mov	r3, #1
	b	.L12
.L4:
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-544]
	bl	lseek
	mov	r3, r0
	cmp	r3, #0
	bge	.L5
	ldr	r3, .L14+4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L14+8
	mov	r0, r4
	bl	fprintf
	ldr	r0, [fp, #-544]
	bl	close
	mov	r3, #1
	b	.L12
.L5:
	ldr	r3, [fp, #-540]
	add	r2, r3, #508
	add	r2, r2, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #9
	str	r3, [fp, #-536]
	ldr	r3, [fp, #-536]
	cmp	r3, #0
	beq	.L6
	ldr	r3, [fp, #-536]
	b	.L7
.L6:
	mov	r3, #1
.L7:
	str	r3, [fp, #-536]
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	ldr	r3, [fp, #-556]
	lsl	r3, r3, #9
	mov	r2, #0
	mov	r1, r3
	ldr	r0, [fp, #-552]
	bl	lseek
	str	r0, [fp, #-540]
	ldr	r3, [fp, #-540]
	cmp	r3, #0
	bge	.L9
	ldr	r3, .L14+4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L14+8
	mov	r0, r4
	bl	fprintf
	ldr	r0, [fp, #-544]
	bl	close
	mov	r3, #1
	b	.L12
.L11:
	ldr	r2, [fp, #-532]
	sub	r3, fp, #528
	mov	r1, r3
	ldr	r0, [fp, #-552]
	bl	write
	mov	r3, r0
	cmp	r3, #0
	blt	.L9
	ldr	r3, [fp, #-548]
	add	r3, r3, #1
	str	r3, [fp, #-548]
.L9:
	ldr	r2, [fp, #-548]
	ldr	r3, [fp, #-536]
	cmp	r2, r3
	bge	.L10
	sub	r3, fp, #528
	mov	r2, #512
	mov	r1, r3
	ldr	r0, [fp, #-544]
	bl	read
	str	r0, [fp, #-532]
	ldr	r3, [fp, #-532]
	cmp	r3, #0
	bge	.L11
.L10:
	ldr	r0, [fp, #-544]
	bl	close
	ldr	r3, [fp, #-556]
	ldr	r2, [fp, #-536]
	ldr	r1, [fp, #-548]
	ldr	r0, .L14+12
	bl	printf
	mov	r3, #0
.L12:
	ldr	r2, .L14
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L13
	bl	__stack_chk_fail
.L13:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L15:
	.align	2
.L14:
	.word	.LC2
	.word	stderr
	.word	.LC0
	.word	.LC1
	.size	write_sectors, .-write_sectors
	.section	.rodata
	.align	2
.LC3:
	.ascii	"Error: Total sectors written %lu/%lu\012\000"
	.align	2
.LC4:
	.ascii	"Total sectors written %lu/%lu\012\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	create_floppy
	.syntax unified
	.arm
	.fpu softvfp
	.type	create_floppy, %function
create_floppy:
	@ args = 0, pretend = 0, frame = 536
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #540
	str	r0, [fp, #-544]
	str	r1, [fp, #-548]
	ldr	r3, .L25
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-536]
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	mov	r2, #420
	ldr	r1, .L25+4
	ldr	r0, [fp, #-544]
	bl	open
	str	r0, [fp, #-532]
	ldr	r3, [fp, #-532]
	cmp	r3, #0
	bge	.L17
	ldr	r3, .L25+8
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L25+12
	mov	r0, r4
	bl	fprintf
	mov	r3, #1
	b	.L23
.L17:
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	sub	r3, fp, #528
	mov	r2, #512
	mov	r1, #0
	mov	r0, r3
	bl	memset
	b	.L19
.L21:
	ldr	r3, [fp, #-536]
	add	r3, r3, #1
	str	r3, [fp, #-536]
.L19:
	ldr	r2, [fp, #-536]
	ldr	r3, [fp, #-548]
	cmp	r2, r3
	bcs	.L20
	sub	r3, fp, #528
	mov	r2, #512
	mov	r1, r3
	ldr	r0, [fp, #-532]
	bl	write
	mov	r3, r0
	cmp	r3, #0
	bgt	.L21
.L20:
	ldr	r0, [fp, #-532]
	bl	close
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L22
	ldr	r3, .L25+8
	ldr	r0, [r3]
	ldr	r3, [fp, #-548]
	ldr	r2, [fp, #-536]
	ldr	r1, .L25+16
	bl	fprintf
	mov	r3, #1
	b	.L23
.L22:
	ldr	r2, [fp, #-548]
	ldr	r1, [fp, #-536]
	ldr	r0, .L25+20
	bl	printf
	mov	r3, #0
.L23:
	ldr	r2, .L25
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L24
	bl	__stack_chk_fail
.L24:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L26:
	.align	2
.L25:
	.word	.LC5
	.word	577
	.word	stderr
	.word	.LC0
	.word	.LC3
	.word	.LC4
	.size	create_floppy, .-create_floppy
	.section	.rodata
	.align	2
.LC6:
	.ascii	"Usage: %s <mode> <image> <file> [skip-count]\012\000"
	.align	2
.LC7:
	.ascii	"Unknown write mode.\000"
	.align	2
.LC8:
	.ascii	"Unknown option '%c'.\012\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	mov	r3, #0
	strb	r3, [fp, #-21]
	ldr	r3, [fp, #-32]
	cmp	r3, #3
	ble	.L28
	ldr	r3, [fp, #-32]
	cmp	r3, #5
	ble	.L29
.L28:
	ldr	r3, .L45
	ldr	r0, [r3]
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L45+4
	bl	fprintf
	mov	r3, #1
	b	.L30
.L29:
	ldr	r3, [fp, #-36]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #99
	beq	.L31
	cmp	r3, #119
	beq	.L32
	b	.L44
.L31:
	ldr	r3, [fp, #-36]
	add	r3, r3, #8
	ldr	r4, [r3]
	ldr	r3, [fp, #-36]
	add	r3, r3, #12
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r3, r0
	mov	r1, r3
	mov	r0, r4
	bl	create_floppy
	b	.L34
.L32:
	ldr	r3, [fp, #-32]
	cmp	r3, #4
	bne	.L35
	mov	r3, #1
	strb	r3, [fp, #-21]
	b	.L34
.L35:
	ldr	r3, [fp, #-32]
	cmp	r3, #5
	bne	.L37
	mov	r3, #2
	strb	r3, [fp, #-21]
	b	.L34
.L37:
	ldr	r0, .L45+8
	bl	puts
	mov	r3, #1
	b	.L30
.L44:
	ldr	r3, [fp, #-36]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r0, .L45+12
	bl	printf
	mov	r3, #1
	b	.L30
.L34:
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #1
	bne	.L38
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	ldr	r3, [fp, #-36]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r2, #420
	mov	r1, #2
	mov	r0, r3
	bl	open
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bge	.L39
	ldr	r3, .L45
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L45+16
	mov	r0, r4
	bl	fprintf
	mov	r3, #1
	b	.L30
.L39:
	ldr	r3, [fp, #-36]
	add	r3, r3, #12
	ldr	r3, [r3]
	mov	r2, r3
	mov	r1, #0
	ldr	r0, [fp, #-16]
	bl	write_sectors
	mov	r3, r0
	cmp	r3, #0
	beq	.L40
	ldr	r0, [fp, #-16]
	bl	close
	mov	r3, #1
	b	.L30
.L40:
	ldr	r0, [fp, #-16]
	bl	close
	b	.L41
.L38:
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #2
	bne	.L41
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	ldr	r3, [fp, #-36]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r2, #420
	mov	r1, #2
	mov	r0, r3
	bl	open
	str	r0, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bge	.L42
	ldr	r3, .L45
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L45+16
	mov	r0, r4
	bl	fprintf
	mov	r3, #1
	b	.L30
.L42:
	ldr	r3, [fp, #-36]
	add	r3, r3, #16
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r1, r0
	ldr	r3, [fp, #-36]
	add	r3, r3, #12
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r0, [fp, #-20]
	bl	write_sectors
	mov	r3, r0
	cmp	r3, #0
	beq	.L43
	ldr	r0, [fp, #-20]
	bl	close
	mov	r3, #1
	b	.L30
.L43:
	ldr	r0, [fp, #-20]
	bl	close
.L41:
	mov	r3, #0
.L30:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L46:
	.align	2
.L45:
	.word	stderr
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC0
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
