	.file	"extr_wext.c_orinoco_set_key.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	orinoco_set_key, @function
orinoco_set_key:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	r15, rdi
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14, r9
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13, rcx
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12d, edx
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	ebp, r8d
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movsx	rbx, esi
	sal	rbx, 5
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	rax, QWORD PTR [rdi]
	mov	rdi, QWORD PTR 16[rax+rbx]
	call	kzfree@PLT
	mov	rax, QWORD PTR [r15]
	mov	rdi, QWORD PTR 24[rax+rbx]
	call	kzfree@PLT
	mov	rdx, QWORD PTR [r15]
	add	rdx, rbx
	test	ebp, ebp
	jne	.L23
	mov	ecx, DWORD PTR 80[rsp]
	mov	QWORD PTR 16[rdx], 0
	test	ecx, ecx
	jne	.L5
	mov	QWORD PTR 24[rdx], 0
	mov	QWORD PTR [rdx], 0
.L9:
	cmp	r12d, 128
	je	.L10
.L26:
	cmp	r12d, 129
	jne	.L11
	mov	rax, QWORD PTR WLAN_CIPHER_SUITE_TKIP[rip]
	mov	QWORD PTR 8[rdx], rax
	xor	eax, eax
.L1:
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	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
.L5:
	.cfi_restore_state
	mov	edi, DWORD PTR 80[rsp]
	mov	esi, DWORD PTR GFP_ATOMIC[rip]
	mov	QWORD PTR 8[rsp], rdx
	call	kzalloc@PLT
	mov	rdx, QWORD PTR 8[rsp]
	mov	QWORD PTR 24[rdx], rax
	mov	rax, QWORD PTR [r15]
	add	rax, rbx
	mov	rdi, QWORD PTR 24[rax]
	test	rdi, rdi
	je	.L24
	mov	ecx, DWORD PTR 80[rsp]
	mov	DWORD PTR [rax], ebp
	mov	DWORD PTR 4[rax], ecx
	test	ebp, ebp
	jne	.L25
.L15:
	mov	edx, DWORD PTR 80[rsp]
	mov	rsi, r14
	call	memcpy@PLT
	add	rbx, QWORD PTR [r15]
	mov	rdx, rbx
	cmp	r12d, 128
	jne	.L26
.L10:
	cmp	DWORD PTR SMALL_KEY_SIZE[rip], ebp
	mov	rax, QWORD PTR WLAN_CIPHER_SUITE_WEP40[rip]
	jge	.L14
	mov	rax, QWORD PTR WLAN_CIPHER_SUITE_WEP104[rip]
.L14:
	mov	QWORD PTR 8[rdx], rax
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xor	eax, eax
	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
.L23:
	.cfi_restore_state
	mov	esi, DWORD PTR GFP_ATOMIC[rip]
	mov	edi, ebp
	mov	QWORD PTR 8[rsp], rdx
	call	kzalloc@PLT
	mov	rdx, QWORD PTR 8[rsp]
	mov	QWORD PTR 16[rdx], rax
	mov	rdx, QWORD PTR [r15]
	add	rdx, rbx
	cmp	QWORD PTR 16[rdx], 0
	je	.L3
	mov	eax, DWORD PTR 80[rsp]
	test	eax, eax
	jne	.L5
	mov	QWORD PTR 24[rdx], 0
	mov	rdi, QWORD PTR 16[rdx]
	mov	rsi, r13
	mov	DWORD PTR [rdx], ebp
	mov	DWORD PTR 4[rdx], 0
	mov	edx, ebp
	call	memcpy@PLT
	add	rbx, QWORD PTR [r15]
	mov	rdx, rbx
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L11:
	mov	QWORD PTR 8[rdx], 0
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xor	eax, eax
	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
.L25:
	.cfi_restore_state
	mov	rdi, QWORD PTR 16[rax]
	mov	edx, ebp
	mov	rsi, r13
	call	memcpy@PLT
	mov	rax, QWORD PTR [r15]
	mov	rdi, QWORD PTR 24[rax+rbx]
	jmp	.L15
	.p2align 4,,10
	.p2align 3
.L24:
	mov	rdi, QWORD PTR 16[rax]
	call	kfree@PLT
	add	rbx, QWORD PTR [r15]
	mov	QWORD PTR 16[rbx], 0
	mov	rdx, rbx
.L3:
	mov	QWORD PTR [rdx], 0
	mov	eax, DWORD PTR ENOMEM[rip]
	mov	QWORD PTR 8[rdx], 0
	neg	eax
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	orinoco_set_key, .-orinoco_set_key
	.comm	WLAN_CIPHER_SUITE_WEP40,8,8
	.comm	WLAN_CIPHER_SUITE_WEP104,8,8
	.comm	WLAN_CIPHER_SUITE_TKIP,8,8
	.comm	SMALL_KEY_SIZE,4,4
	.comm	GFP_ATOMIC,4,4
	.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_wext.c_orinoco_set_key.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	orinoco_set_key, %function
orinoco_set_key:
	@ args = 12, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r6, r0
	ldr	r0, [r0]
	add	r1, r1, r1, lsl #2
	add	r0, r0, r1, lsl #2
	ldr	r0, [r0, #12]
	lsl	r4, r1, #2
	mov	r8, r2
	mov	r9, r3
	ldr	r7, [sp, #40]
	ldr	r10, [sp, #48]
	bl	kzfree
	ldr	r2, [r6]
	add	r2, r2, r4
	ldr	r0, [r2, #16]
	bl	kzfree
	cmp	r7, #0
	bne	.L27
	ldr	r3, [r6]
	cmp	r10, #0
	add	r5, r3, r4
	ldrne	fp, .L31
	str	r7, [r5, #12]
	bne	.L5
	str	r7, [r5, #16]
	str	r7, [r3, r4]
	str	r7, [r5, #4]
.L9:
	cmp	r8, #128
	beq	.L10
.L30:
	cmp	r8, #129
	bne	.L11
	ldr	r3, .L31+4
	mov	r0, #0
	ldr	r3, [r3]
	str	r3, [r5, #8]
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L5:
	ldr	r1, [fp]
	mov	r0, r10
	bl	kzalloc
	ldr	r2, [r6]
	str	r0, [r5, #16]
	add	r3, r2, r4
	ldr	fp, [r3, #16]
	cmp	fp, #0
	beq	.L28
	cmp	r7, #0
	str	r7, [r2, r4]
	str	r10, [r3, #4]
	bne	.L29
.L15:
	mov	r2, r10
	mov	r0, fp
	ldr	r1, [sp, #44]
	bl	memcpy
	ldr	r5, [r6]
	cmp	r8, #128
	add	r5, r5, r4
	bne	.L30
.L10:
	ldr	r3, .L31+8
	mov	r0, #0
	ldr	r3, [r3]
	cmp	r3, r7
	ldrlt	r3, .L31+12
	ldrge	r3, .L31+16
	ldr	r3, [r3]
	str	r3, [r5, #8]
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L27:
	ldr	fp, .L31
	mov	r0, r7
	ldr	r1, [fp]
	ldr	r5, [r6]
	bl	kzalloc
	ldr	r3, [r6]
	add	r5, r5, r4
	str	r0, [r5, #12]
	add	r5, r3, r4
	ldr	r0, [r5, #12]
	cmp	r0, #0
	beq	.L3
	cmp	r10, #0
	bne	.L5
	str	r10, [r5, #16]
	mov	r1, r9
	str	r7, [r3, r4]
	mov	r2, r7
	str	r10, [r5, #4]
	bl	memcpy
	ldr	r5, [r6]
	add	r5, r5, r4
	b	.L9
.L11:
	mov	r0, #0
	str	r0, [r5, #8]
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L29:
	ldr	r0, [r3, #12]
	mov	r1, r9
	mov	r2, r7
	bl	memcpy
	ldr	r3, [r6]
	add	r3, r3, r4
	ldr	fp, [r3, #16]
	b	.L15
.L28:
	ldr	r0, [r3, #12]
	bl	kfree
	ldr	r5, [r6]
	add	r5, r5, r4
	str	fp, [r5, #12]
.L3:
	mov	r3, #0
	ldr	r2, .L31+20
	str	r3, [r5]
	ldr	r0, [r2]
	str	r3, [r5, #4]
	rsb	r0, r0, #0
	str	r3, [r5, #8]
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L32:
	.align	2
.L31:
	.word	GFP_ATOMIC
	.word	WLAN_CIPHER_SUITE_TKIP
	.word	SMALL_KEY_SIZE
	.word	WLAN_CIPHER_SUITE_WEP104
	.word	WLAN_CIPHER_SUITE_WEP40
	.word	ENOMEM
	.size	orinoco_set_key, .-orinoco_set_key
	.comm	WLAN_CIPHER_SUITE_WEP40,4,4
	.comm	WLAN_CIPHER_SUITE_WEP104,4,4
	.comm	WLAN_CIPHER_SUITE_TKIP,4,4
	.comm	SMALL_KEY_SIZE,4,4
	.comm	GFP_ATOMIC,4,4
	.comm	ENOMEM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
