	.file	"482636.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"\nUsage: %s [options] tty\n\n"
	.align 8
.LC1:
	.string	"Options: -o         (send open command 'O\\r')\n"
	.align 8
.LC2:
	.string	"         -c         (send close command 'C\\r')\n"
	.align 8
.LC3:
	.string	"         -f         (read status flags with 'F\\r' to reset error states)\n"
	.align 8
.LC4:
	.string	"         -s <speed> (set CAN speed 0..8)\n"
	.align 8
.LC5:
	.string	"         -b <btr>   (set bit time register value)\n"
	.align 8
.LC6:
	.string	"         -d         (only detach line discipline)\n"
	.align 8
.LC7:
	.string	"         -w         (attach - wait for keypess - detach)\n"
	.align 8
.LC8:
	.string	"         -n <name>  (assign created netdevice name)\n"
.LC9:
	.string	"\nExamples:\n"
	.align 8
.LC10:
	.string	"slcan_attach -w -o -f -s6 -c /dev/ttyS1\n"
.LC11:
	.string	"slcan_attach /dev/ttyS1\n"
.LC12:
	.string	"slcan_attach -d /dev/ttyS1\n"
	.align 8
.LC13:
	.string	"slcan_attach -w -n can15 /dev/ttyS1\n"
	.text
	.globl	print_usage
	.type	print_usage, @function
print_usage:
.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, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR stderr[rip]
	mov	rdx, QWORD PTR -8[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 46
	mov	esi, 1
	lea	rdi, .LC1[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 47
	mov	esi, 1
	lea	rdi, .LC2[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 73
	mov	esi, 1
	lea	rdi, .LC3[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 41
	mov	esi, 1
	lea	rdi, .LC4[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 50
	mov	esi, 1
	lea	rdi, .LC5[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 50
	mov	esi, 1
	lea	rdi, .LC6[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 57
	mov	esi, 1
	lea	rdi, .LC7[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 52
	mov	esi, 1
	lea	rdi, .LC8[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 11
	mov	esi, 1
	lea	rdi, .LC9[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 40
	mov	esi, 1
	lea	rdi, .LC10[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 24
	mov	esi, 1
	lea	rdi, .LC11[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 27
	mov	esi, 1
	lea	rdi, .LC12[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 36
	mov	esi, 1
	lea	rdi, .LC13[rip]
	call	fwrite@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rsi, rax
	mov	edi, 10
	call	fputc@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE6:
	.size	print_usage, .-print_usage
	.section	.rodata
.LC14:
	.string	"Ignored option '-l'\n"
.LC15:
	.string	"l:dwocfs:b:n:?"
.LC16:
	.string	"C\rS%s\r"
.LC17:
	.string	"C\rs%s\r"
.LC18:
	.string	"F\r"
.LC19:
	.string	"O\r"
.LC20:
	.string	"ioctl TIOCSETD"
.LC21:
	.string	"ioctl SIOCGIFNAME"
	.align 8
.LC22:
	.string	"attached tty %s to netdevice %s\n"
	.align 8
.LC23:
	.string	"rename netdevice %s to %s ... "
.LC24:
	.string	"socket for interface rename"
.LC25:
	.string	"failed!"
.LC26:
	.string	"ok."
	.align 8
.LC27:
	.string	"Press any key to detach %s ...\n"
.LC28:
	.string	"ioctl"
.LC29:
	.string	"C\r"
	.text
	.globl	main
	.type	main, @function
main:
.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, 176
	mov	DWORD PTR -164[rbp], edi
	mov	QWORD PTR -176[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -148[rbp], 17
	mov	DWORD PTR -144[rbp], 0
	mov	DWORD PTR -140[rbp], 0
	mov	DWORD PTR -136[rbp], 0
	mov	DWORD PTR -132[rbp], 0
	mov	DWORD PTR -128[rbp], 0
	mov	QWORD PTR -112[rbp], 0
	mov	QWORD PTR -104[rbp], 0
	mov	QWORD PTR -96[rbp], 0
	jmp	.L3
.L18:
	mov	eax, DWORD PTR -124[rbp]
	sub	eax, 98
	cmp	eax, 21
	ja	.L4
	mov	eax, eax
	lea	rdx, 0[0+rax*4]
	lea	rax, .L6[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cdqe
	lea	rdx, .L6[rip]
	add	rax, rdx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L6:
	.long	.L14-.L6
	.long	.L13-.L6
	.long	.L12-.L6
	.long	.L4-.L6
	.long	.L11-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L10-.L6
	.long	.L4-.L6
	.long	.L9-.L6
	.long	.L8-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L7-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L4-.L6
	.long	.L5-.L6
	.text
.L10:
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 20
	mov	esi, 1
	lea	rdi, .LC14[rip]
	call	fwrite@PLT
	jmp	.L3
.L12:
	mov	DWORD PTR -144[rbp], 1
	jmp	.L3
.L5:
	mov	DWORD PTR -140[rbp], 1
	jmp	.L3
.L8:
	mov	DWORD PTR -136[rbp], 1
	jmp	.L3
.L13:
	mov	DWORD PTR -132[rbp], 1
	jmp	.L3
.L11:
	mov	DWORD PTR -128[rbp], 1
	jmp	.L3
.L7:
	mov	rax, QWORD PTR optarg[rip]
	mov	QWORD PTR -112[rbp], rax
	mov	rax, QWORD PTR -112[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rax, 1
	jbe	.L3
	mov	rax, QWORD PTR -176[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	print_usage
	jmp	.L3
.L14:
	mov	rax, QWORD PTR optarg[rip]
	mov	QWORD PTR -104[rbp], rax
	mov	rax, QWORD PTR -104[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rax, 6
	jbe	.L3
	mov	rax, QWORD PTR -176[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	print_usage
	jmp	.L3
.L9:
	mov	rax, QWORD PTR optarg[rip]
	mov	QWORD PTR -96[rbp], rax
	mov	rax, QWORD PTR -96[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rax, 15
	jbe	.L3
	mov	rax, QWORD PTR -176[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	print_usage
	jmp	.L3
.L4:
	mov	rax, QWORD PTR -176[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	print_usage
	nop
.L3:
	mov	rcx, QWORD PTR -176[rbp]
	mov	eax, DWORD PTR -164[rbp]
	lea	rdx, .LC15[rip]
	mov	rsi, rcx
	mov	edi, eax
	call	getopt@PLT
	mov	DWORD PTR -124[rbp], eax
	cmp	DWORD PTR -124[rbp], -1
	jne	.L18
	mov	edx, DWORD PTR optind[rip]
	mov	eax, DWORD PTR -164[rbp]
	sub	eax, edx
	cmp	eax, 1
	je	.L19
	mov	rax, QWORD PTR -176[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	print_usage
.L19:
	mov	eax, DWORD PTR optind[rip]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -176[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR -88[rbp], rax
	mov	rax, QWORD PTR -88[rbp]
	mov	esi, 257
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -120[rbp], eax
	cmp	DWORD PTR -120[rbp], 0
	jns	.L20
	mov	rax, QWORD PTR -88[rbp]
	mov	rdi, rax
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L20:
	cmp	DWORD PTR -140[rbp], 0
	jne	.L21
	cmp	DWORD PTR -144[rbp], 0
	jne	.L22
.L21:
	cmp	QWORD PTR -112[rbp], 0
	je	.L23
	mov	rdx, QWORD PTR -112[rbp]
	lea	rax, -32[rbp]
	lea	rsi, .LC16[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -32[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -32[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L23:
	cmp	QWORD PTR -104[rbp], 0
	je	.L24
	mov	rdx, QWORD PTR -104[rbp]
	lea	rax, -32[rbp]
	lea	rsi, .LC17[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -32[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -32[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L24:
	cmp	DWORD PTR -128[rbp], 0
	je	.L25
	lea	rax, -32[rbp]
	lea	rsi, .LC18[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -32[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -32[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L25:
	cmp	DWORD PTR -136[rbp], 0
	je	.L26
	lea	rax, -32[rbp]
	lea	rsi, .LC19[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -32[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -32[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L26:
	lea	rdx, -148[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	esi, 21539
	mov	edi, eax
	mov	eax, 0
	call	ioctl@PLT
	test	eax, eax
	jns	.L27
	lea	rdi, .LC20[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L27:
	lea	rdx, -32[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	esi, 35088
	mov	edi, eax
	mov	eax, 0
	call	ioctl@PLT
	test	eax, eax
	jns	.L28
	lea	rdi, .LC21[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L28:
	lea	rdx, -32[rbp]
	mov	rax, QWORD PTR -88[rbp]
	mov	rsi, rax
	lea	rdi, .LC22[rip]
	mov	eax, 0
	call	printf@PLT
	cmp	QWORD PTR -96[rbp], 0
	je	.L22
	mov	edx, 0
	mov	esi, 2
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -116[rbp], eax
	mov	rdx, QWORD PTR -96[rbp]
	lea	rax, -32[rbp]
	mov	rsi, rax
	lea	rdi, .LC23[rip]
	mov	eax, 0
	call	printf@PLT
	cmp	DWORD PTR -116[rbp], 0
	jns	.L29
	lea	rdi, .LC24[rip]
	call	perror@PLT
	jmp	.L22
.L29:
	lea	rcx, -32[rbp]
	lea	rax, -80[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	rdi, rax
	call	strncpy@PLT
	mov	rax, QWORD PTR -96[rbp]
	lea	rdx, -80[rbp]
	lea	rcx, 16[rdx]
	mov	edx, 16
	mov	rsi, rax
	mov	rdi, rcx
	call	strncpy@PLT
	lea	rdx, -80[rbp]
	mov	eax, DWORD PTR -116[rbp]
	mov	esi, 35107
	mov	edi, eax
	mov	eax, 0
	call	ioctl@PLT
	test	eax, eax
	jns	.L31
	lea	rdi, .LC25[rip]
	call	puts@PLT
	jmp	.L32
.L31:
	lea	rdi, .LC26[rip]
	call	puts@PLT
.L32:
	mov	eax, DWORD PTR -116[rbp]
	mov	edi, eax
	call	close@PLT
.L22:
	cmp	DWORD PTR -140[rbp], 0
	je	.L33
	mov	rax, QWORD PTR -88[rbp]
	mov	rsi, rax
	lea	rdi, .LC27[rip]
	mov	eax, 0
	call	printf@PLT
	call	getchar@PLT
.L33:
	cmp	DWORD PTR -140[rbp], 0
	jne	.L34
	cmp	DWORD PTR -144[rbp], 0
	je	.L35
.L34:
	mov	DWORD PTR -148[rbp], 0
	lea	rdx, -148[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	esi, 21539
	mov	edi, eax
	mov	eax, 0
	call	ioctl@PLT
	test	eax, eax
	jns	.L36
	lea	rdi, .LC28[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L36:
	cmp	DWORD PTR -132[rbp], 0
	je	.L35
	lea	rax, -32[rbp]
	lea	rsi, .LC29[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -32[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -32[rbp]
	mov	eax, DWORD PTR -120[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L35:
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L38
	call	__stack_chk_fail@PLT
.L38:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.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	"482636.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"\012Usage: %s [options] tty\012\012\000"
	.align	2
.LC1:
	.ascii	"Options: -o         (send open command 'O\\r')\012\000"
	.align	2
.LC2:
	.ascii	"         -c         (send close command 'C\\r')\012"
	.ascii	"\000"
	.align	2
.LC3:
	.ascii	"         -f         (read status flags with 'F\\r' "
	.ascii	"to reset error states)\012\000"
	.align	2
.LC4:
	.ascii	"         -s <speed> (set CAN speed 0..8)\012\000"
	.align	2
.LC5:
	.ascii	"         -b <btr>   (set bit time register value)\012"
	.ascii	"\000"
	.align	2
.LC6:
	.ascii	"         -d         (only detach line discipline)\012"
	.ascii	"\000"
	.align	2
.LC7:
	.ascii	"         -w         (attach - wait for keypess - de"
	.ascii	"tach)\012\000"
	.align	2
.LC8:
	.ascii	"         -n <name>  (assign created netdevice name)"
	.ascii	"\012\000"
	.align	2
.LC9:
	.ascii	"\012Examples:\012\000"
	.align	2
.LC10:
	.ascii	"slcan_attach -w -o -f -s6 -c /dev/ttyS1\012\000"
	.align	2
.LC11:
	.ascii	"slcan_attach /dev/ttyS1\012\000"
	.align	2
.LC12:
	.ascii	"slcan_attach -d /dev/ttyS1\012\000"
	.align	2
.LC13:
	.ascii	"slcan_attach -w -n can15 /dev/ttyS1\012\000"
	.text
	.align	2
	.global	print_usage
	.syntax unified
	.arm
	.fpu softvfp
	.type	print_usage, %function
print_usage:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r3, .L2
	ldr	r3, [r3]
	ldr	r2, [fp, #-8]
	ldr	r1, .L2+4
	mov	r0, r3
	bl	fprintf
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #46
	mov	r1, #1
	ldr	r0, .L2+8
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #47
	mov	r1, #1
	ldr	r0, .L2+12
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #73
	mov	r1, #1
	ldr	r0, .L2+16
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #41
	mov	r1, #1
	ldr	r0, .L2+20
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #50
	mov	r1, #1
	ldr	r0, .L2+24
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #50
	mov	r1, #1
	ldr	r0, .L2+28
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #57
	mov	r1, #1
	ldr	r0, .L2+32
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #52
	mov	r1, #1
	ldr	r0, .L2+36
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #11
	mov	r1, #1
	ldr	r0, .L2+40
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #40
	mov	r1, #1
	ldr	r0, .L2+44
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #24
	mov	r1, #1
	ldr	r0, .L2+48
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #27
	mov	r1, #1
	ldr	r0, .L2+52
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r2, #36
	mov	r1, #1
	ldr	r0, .L2+56
	bl	fwrite
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r1, r3
	mov	r0, #10
	bl	fputc
	mov	r0, #1
	bl	exit
.L3:
	.align	2
.L2:
	.word	stderr
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.size	print_usage, .-print_usage
	.section	.rodata
	.align	2
.LC14:
	.ascii	"Ignored option '-l'\012\000"
	.align	2
.LC15:
	.ascii	"l:dwocfs:b:n:?\000"
	.align	2
.LC16:
	.ascii	"C\015S%s\015\000"
	.align	2
.LC17:
	.ascii	"C\015s%s\015\000"
	.align	2
.LC18:
	.ascii	"F\015\000"
	.align	2
.LC19:
	.ascii	"O\015\000"
	.align	2
.LC20:
	.ascii	"ioctl TIOCSETD\000"
	.align	2
.LC21:
	.ascii	"ioctl SIOCGIFNAME\000"
	.align	2
.LC22:
	.ascii	"attached tty %s to netdevice %s\012\000"
	.align	2
.LC23:
	.ascii	"rename netdevice %s to %s ... \000"
	.align	2
.LC24:
	.ascii	"socket for interface rename\000"
	.align	2
.LC25:
	.ascii	"failed!\000"
	.align	2
.LC26:
	.ascii	"ok.\000"
	.align	2
.LC27:
	.ascii	"Press any key to detach %s ...\012\000"
	.align	2
.LC28:
	.ascii	"ioctl\000"
	.align	2
.LC29:
	.ascii	"C\015\000"
	.align	2
.LC30:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 120
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #120
	str	r0, [fp, #-120]
	str	r1, [fp, #-124]
	ldr	r3, .L41
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #17
	str	r3, [fp, #-112]
	mov	r3, #0
	str	r3, [fp, #-108]
	mov	r3, #0
	str	r3, [fp, #-104]
	mov	r3, #0
	str	r3, [fp, #-100]
	mov	r3, #0
	str	r3, [fp, #-96]
	mov	r3, #0
	str	r3, [fp, #-92]
	mov	r3, #0
	str	r3, [fp, #-88]
	mov	r3, #0
	str	r3, [fp, #-84]
	mov	r3, #0
	str	r3, [fp, #-80]
	b	.L5
.L20:
	ldr	r3, [fp, #-76]
	sub	r3, r3, #98
	cmp	r3, #21
	ldrls	pc, [pc, r3, asl #2]
	b	.L6
.L8:
	.word	.L16
	.word	.L15
	.word	.L14
	.word	.L6
	.word	.L13
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L12
	.word	.L6
	.word	.L11
	.word	.L10
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L9
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L7
.L12:
	ldr	r3, .L41+4
	ldr	r3, [r3]
	mov	r2, #20
	mov	r1, #1
	ldr	r0, .L41+8
	bl	fwrite
	b	.L5
.L14:
	mov	r3, #1
	str	r3, [fp, #-108]
	b	.L5
.L7:
	mov	r3, #1
	str	r3, [fp, #-104]
	b	.L5
.L10:
	mov	r3, #1
	str	r3, [fp, #-100]
	b	.L5
.L15:
	mov	r3, #1
	str	r3, [fp, #-96]
	b	.L5
.L13:
	mov	r3, #1
	str	r3, [fp, #-92]
	b	.L5
.L9:
	ldr	r3, .L41+12
	ldr	r3, [r3]
	str	r3, [fp, #-88]
	ldr	r0, [fp, #-88]
	bl	strlen
	mov	r3, r0
	cmp	r3, #1
	bls	.L5
	ldr	r3, [fp, #-124]
	ldr	r3, [r3]
	mov	r0, r3
	bl	print_usage
	b	.L5
.L16:
	ldr	r3, .L41+12
	ldr	r3, [r3]
	str	r3, [fp, #-84]
	ldr	r0, [fp, #-84]
	bl	strlen
	mov	r3, r0
	cmp	r3, #6
	bls	.L5
	ldr	r3, [fp, #-124]
	ldr	r3, [r3]
	mov	r0, r3
	bl	print_usage
	b	.L5
.L11:
	ldr	r3, .L41+12
	ldr	r3, [r3]
	str	r3, [fp, #-80]
	ldr	r0, [fp, #-80]
	bl	strlen
	mov	r3, r0
	cmp	r3, #15
	bls	.L5
	ldr	r3, [fp, #-124]
	ldr	r3, [r3]
	mov	r0, r3
	bl	print_usage
	b	.L5
.L6:
	ldr	r3, [fp, #-124]
	ldr	r3, [r3]
	mov	r0, r3
	bl	print_usage
	nop
.L5:
	ldr	r2, .L41+16
	ldr	r1, [fp, #-124]
	ldr	r0, [fp, #-120]
	bl	getopt
	str	r0, [fp, #-76]
	ldr	r3, [fp, #-76]
	cmn	r3, #1
	bne	.L20
	ldr	r3, .L41+20
	ldr	r3, [r3]
	ldr	r2, [fp, #-120]
	sub	r3, r2, r3
	cmp	r3, #1
	beq	.L21
	ldr	r3, [fp, #-124]
	ldr	r3, [r3]
	mov	r0, r3
	bl	print_usage
.L21:
	ldr	r3, .L41+20
	ldr	r3, [r3]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-124]
	add	r3, r2, r3
	ldr	r3, [r3]
	str	r3, [fp, #-72]
	ldr	r1, .L41+24
	ldr	r0, [fp, #-72]
	bl	open
	str	r0, [fp, #-68]
	ldr	r3, [fp, #-68]
	cmp	r3, #0
	bge	.L22
	ldr	r0, [fp, #-72]
	bl	perror
	mov	r0, #1
	bl	exit
.L22:
	ldr	r3, [fp, #-104]
	cmp	r3, #0
	bne	.L23
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	bne	.L24
.L23:
	ldr	r3, [fp, #-88]
	cmp	r3, #0
	beq	.L25
	sub	r3, fp, #28
	ldr	r2, [fp, #-88]
	ldr	r1, .L41+28
	mov	r0, r3
	bl	sprintf
	sub	r3, fp, #28
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #28
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	write
.L25:
	ldr	r3, [fp, #-84]
	cmp	r3, #0
	beq	.L26
	sub	r3, fp, #28
	ldr	r2, [fp, #-84]
	ldr	r1, .L41+32
	mov	r0, r3
	bl	sprintf
	sub	r3, fp, #28
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #28
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	write
.L26:
	ldr	r3, [fp, #-92]
	cmp	r3, #0
	beq	.L27
	sub	r3, fp, #28
	ldr	r1, .L41+36
	mov	r0, r3
	bl	sprintf
	sub	r3, fp, #28
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #28
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	write
.L27:
	ldr	r3, [fp, #-100]
	cmp	r3, #0
	beq	.L28
	sub	r3, fp, #28
	ldr	r1, .L41+40
	mov	r0, r3
	bl	sprintf
	sub	r3, fp, #28
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #28
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	write
.L28:
	sub	r3, fp, #112
	mov	r2, r3
	ldr	r1, .L41+44
	ldr	r0, [fp, #-68]
	bl	ioctl
	mov	r3, r0
	cmp	r3, #0
	bge	.L29
	ldr	r0, .L41+48
	bl	perror
	mov	r0, #1
	bl	exit
.L29:
	sub	r3, fp, #28
	mov	r2, r3
	ldr	r1, .L41+52
	ldr	r0, [fp, #-68]
	bl	ioctl
	mov	r3, r0
	cmp	r3, #0
	bge	.L30
	ldr	r0, .L41+56
	bl	perror
	mov	r0, #1
	bl	exit
.L30:
	sub	r3, fp, #28
	mov	r2, r3
	ldr	r1, [fp, #-72]
	ldr	r0, .L41+60
	bl	printf
	ldr	r3, [fp, #-80]
	cmp	r3, #0
	beq	.L24
	mov	r2, #0
	mov	r1, #2
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-64]
	sub	r3, fp, #28
	ldr	r2, [fp, #-80]
	mov	r1, r3
	ldr	r0, .L41+64
	bl	printf
	ldr	r3, [fp, #-64]
	cmp	r3, #0
	bge	.L31
	ldr	r0, .L41+68
	bl	perror
	b	.L24
.L31:
	sub	r1, fp, #28
	sub	r3, fp, #60
	mov	r2, #16
	mov	r0, r3
	bl	strncpy
	sub	r3, fp, #60
	add	r3, r3, #16
	mov	r2, #16
	ldr	r1, [fp, #-80]
	mov	r0, r3
	bl	strncpy
	sub	r3, fp, #60
	mov	r2, r3
	ldr	r1, .L41+72
	ldr	r0, [fp, #-64]
	bl	ioctl
	mov	r3, r0
	cmp	r3, #0
	bge	.L33
	ldr	r0, .L41+76
	bl	puts
	b	.L34
.L33:
	ldr	r0, .L41+80
	bl	puts
.L34:
	ldr	r0, [fp, #-64]
	bl	close
.L24:
	ldr	r3, [fp, #-104]
	cmp	r3, #0
	beq	.L35
	ldr	r1, [fp, #-72]
	ldr	r0, .L41+84
	bl	printf
	bl	getchar
.L35:
	ldr	r3, [fp, #-104]
	cmp	r3, #0
	bne	.L36
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	beq	.L37
.L36:
	mov	r3, #0
	str	r3, [fp, #-112]
	sub	r3, fp, #112
	mov	r2, r3
	ldr	r1, .L41+44
	ldr	r0, [fp, #-68]
	bl	ioctl
	mov	r3, r0
	cmp	r3, #0
	bge	.L38
	ldr	r0, .L41+88
	bl	perror
	mov	r0, #1
	bl	exit
.L38:
	ldr	r3, [fp, #-96]
	cmp	r3, #0
	beq	.L37
	sub	r3, fp, #28
	ldr	r1, .L41+92
	mov	r0, r3
	bl	sprintf
	sub	r3, fp, #28
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #28
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	write
.L37:
	ldr	r0, [fp, #-68]
	bl	close
	mov	r3, #0
	ldr	r2, .L41
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L40
	bl	__stack_chk_fail
.L40:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L42:
	.align	2
.L41:
	.word	.LC30
	.word	stderr
	.word	.LC14
	.word	optarg
	.word	.LC15
	.word	optind
	.word	257
	.word	.LC16
	.word	.LC17
	.word	.LC18
	.word	.LC19
	.word	21539
	.word	.LC20
	.word	35088
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.word	.LC24
	.word	35107
	.word	.LC25
	.word	.LC26
	.word	.LC27
	.word	.LC28
	.word	.LC29
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
