	.file	"extr_4965-mac.c_il4965_set_wep_dynamic_key_info.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"no space for a new key"
	.text
	.p2align 4
	.type	il4965_set_wep_dynamic_key_info, @function
il4965_set_wep_dynamic_key_info:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12, rdi
	add	rdi, 24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdx
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	mov	rbx, rsi
	sub	rsp, 24
	.cfi_def_cfa_offset 64
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	call	lockdep_assert_held@PLT
	mov	eax, DWORD PTR IEEE80211_KEY_FLAG_GENERATE_IV[rip]
	mov	edi, DWORD PTR [rbx]
	mov	ecx, DWORD PTR STA_KEY_FLG_KEYID_POS[rip]
	mov	r13d, DWORD PTR STA_KEY_FLG_WEP[rip]
	not	eax
	and	DWORD PTR 28[rbx], eax
	or	r13d, DWORD PTR STA_KEY_FLG_MAP_KEY_MSK[rip]
	sal	edi, cl
	call	cpu_to_le16@PLT
	or	r13d, eax
	mov	eax, DWORD PTR STA_KEY_FLG_INVALID[rip]
	not	eax
	and	r13d, eax
	mov	rax, QWORD PTR WEP_KEY_LEN_128[rip]
	cmp	QWORD PTR 8[rbx], rax
	jne	.L2
	or	r13d, DWORD PTR STA_KEY_FLG_KEY_SIZE_MSK[rip]
.L2:
	cmp	QWORD PTR 16[r12], rbp
	jne	.L3
	or	r13d, DWORD PTR STA_KEY_MULTICAST_MSK[rip]
.L3:
	xor	esi, esi
	mov	rdi, r12
	sal	rbp, 6
	call	spin_lock_irqsave@PLT
	mov	rax, QWORD PTR 8[r12]
	mov	edx, DWORD PTR 24[rbx]
	mov	ecx, DWORD PTR [rbx]
	mov	rsi, QWORD PTR 16[rbx]
	add	rax, rbp
	mov	DWORD PTR 56[rax], edx
	mov	rdx, QWORD PTR 8[rbx]
	mov	DWORD PTR 40[rax], ecx
	mov	rdi, QWORD PTR 48[rax]
	mov	QWORD PTR 32[rax], rdx
	call	memcpy@PLT
	mov	rax, QWORD PTR 8[r12]
	mov	rdx, QWORD PTR 8[rbx]
	mov	rsi, QWORD PTR 16[rbx]
	mov	rdi, QWORD PTR 24[rax+rbp]
	add	rdi, 12
	call	memcpy@PLT
	mov	rbx, QWORD PTR 8[r12]
	add	rbx, rbp
	mov	eax, DWORD PTR 8[rbx]
	and	eax, DWORD PTR STA_KEY_FLG_ENCRYPT_MSK[rip]
	cmp	eax, DWORD PTR STA_KEY_FLG_NO_ENC[rip]
	je	.L8
.L4:
	mov	rax, QWORD PTR WEP_INVALID_OFFSET[rip]
	xor	edi, edi
	cmp	QWORD PTR 16[rbx], rax
	lea	rsi, .LC0[rip]
	sete	dil
	call	WARN@PLT
	mov	rsi, QWORD PTR 8[r12]
	mov	eax, DWORD PTR STA_MODIFY_KEY_MASK[rip]
	mov	edx, 4
	add	rsi, rbp
	lea	rbp, 4[rsp]
	mov	DWORD PTR 4[rsi], eax
	mov	eax, DWORD PTR STA_CONTROL_MODIFY_MSK[rip]
	mov	rdi, rbp
	mov	DWORD PTR 8[rsi], r13d
	mov	DWORD PTR [rsi], eax
	call	memcpy@PLT
	xor	esi, esi
	mov	rdi, r12
	call	spin_unlock_irqrestore@PLT
	mov	edx, DWORD PTR CMD_SYNC[rip]
	mov	rsi, rbp
	mov	rdi, r12
	call	il_send_add_sta@PLT
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L9
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	mov	rdi, r12
	call	il_get_free_ucode_key_idx@PLT
	mov	QWORD PTR 16[rbx], rax
	mov	rbx, QWORD PTR 8[r12]
	add	rbx, rbp
	jmp	.L4
.L9:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	il4965_set_wep_dynamic_key_info, .-il4965_set_wep_dynamic_key_info
	.comm	WEP_KEY_LEN_128,8,8
	.comm	WEP_INVALID_OFFSET,8,8
	.comm	STA_MODIFY_KEY_MASK,4,4
	.comm	STA_KEY_MULTICAST_MSK,4,4
	.comm	STA_KEY_FLG_WEP,4,4
	.comm	STA_KEY_FLG_NO_ENC,4,4
	.comm	STA_KEY_FLG_MAP_KEY_MSK,4,4
	.comm	STA_KEY_FLG_KEY_SIZE_MSK,4,4
	.comm	STA_KEY_FLG_KEYID_POS,4,4
	.comm	STA_KEY_FLG_INVALID,4,4
	.comm	STA_KEY_FLG_ENCRYPT_MSK,4,4
	.comm	STA_CONTROL_MODIFY_MSK,4,4
	.comm	IEEE80211_KEY_FLAG_GENERATE_IV,4,4
	.comm	CMD_SYNC,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_4965-mac.c_il4965_set_wep_dynamic_key_info.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"no space for a new key\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	il4965_set_wep_dynamic_key_info, %function
il4965_set_wep_dynamic_key_info:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r5, r1
	ldr	r3, .L10
	mov	r6, r0
	sub	sp, sp, #8
	add	r0, r0, #12
	mov	r4, r2
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	bl	lockdep_assert_held
	ldr	r1, .L10+4
	ldr	r0, .L10+8
	ldr	r2, .L10+12
	ldr	r3, [r5, #16]
	ldr	r1, [r1]
	ldr	r2, [r2]
	ldr	r8, [r0]
	ldr	r0, [r5]
	bic	r3, r3, r1
	ldr	r1, .L10+16
	str	r3, [r5, #16]
	lsl	r0, r0, r2
	ldr	r7, [r1]
	bl	cpu_to_le16
	ldr	r2, .L10+20
	ldr	r3, .L10+24
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, [r5, #4]
	orr	r7, r8, r7
	cmp	r2, r3
	ldreq	r3, .L10+28
	orr	r7, r7, r0
	ldreq	r3, [r3]
	bic	r7, r7, r1
	orreq	r7, r7, r3
	ldr	r3, [r6, #8]
	mov	r1, #0
	cmp	r3, r4
	ldreq	r3, .L10+32
	mov	r0, r6
	ldreq	r3, [r3]
	add	r4, r4, r4, lsl #3
	orreq	r7, r7, r3
	bl	spin_lock_irqsave
	ldm	r5, {r1, r2}
	ldr	r3, [r6, #4]
	ldr	r0, [r5, #12]
	add	r3, r3, r4, lsl #2
	str	r0, [r3, #32]
	str	r2, [r3, #20]
	str	r1, [r3, #24]
	ldr	r0, [r3, #28]
	ldr	r1, [r5, #8]
	bl	memcpy
	ldr	r3, [r6, #4]
	lsl	r4, r4, #2
	add	r3, r3, r4
	ldr	r0, [r3, #16]
	ldr	r2, [r5, #4]
	ldr	r1, [r5, #8]
	add	r0, r0, #12
	bl	memcpy
	ldr	r5, [r6, #4]
	ldr	r1, .L10+36
	ldr	r2, .L10+40
	add	r5, r5, r4
	ldr	r3, [r5, #8]
	ldr	r1, [r1]
	ldr	r2, [r2]
	and	r3, r3, r1
	cmp	r3, r2
	beq	.L8
.L4:
	ldr	r3, .L10+44
	ldr	r0, [r5, #12]
	ldr	r3, [r3]
	ldr	r1, .L10+48
	sub	r0, r0, r3
	clz	r0, r0
	lsr	r0, r0, #5
	bl	WARN
	ldr	r1, .L10+52
	ldr	r2, .L10+56
	ldr	r3, [r6, #4]
	ldr	r0, [r1]
	ldr	r2, [r2]
	add	r1, r3, r4
	stmib	r1, {r0, r7}
	str	r2, [r3, r4]
	mov	r0, sp
	mov	r2, #4
	bl	memcpy
	mov	r1, #0
	mov	r0, r6
	bl	spin_unlock_irqrestore
	ldr	r3, .L10+60
	mov	r1, sp
	ldr	r2, [r3]
	mov	r0, r6
	bl	il_send_add_sta
	ldr	r3, .L10
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L9
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L8:
	mov	r0, r6
	bl	il_get_free_ucode_key_idx
	ldr	r3, [r6, #4]
	str	r0, [r5, #12]
	add	r5, r3, r4
	b	.L4
.L9:
	bl	__stack_chk_fail
.L11:
	.align	2
.L10:
	.word	.LC1
	.word	IEEE80211_KEY_FLAG_GENERATE_IV
	.word	STA_KEY_FLG_WEP
	.word	STA_KEY_FLG_KEYID_POS
	.word	STA_KEY_FLG_MAP_KEY_MSK
	.word	STA_KEY_FLG_INVALID
	.word	WEP_KEY_LEN_128
	.word	STA_KEY_FLG_KEY_SIZE_MSK
	.word	STA_KEY_MULTICAST_MSK
	.word	STA_KEY_FLG_ENCRYPT_MSK
	.word	STA_KEY_FLG_NO_ENC
	.word	WEP_INVALID_OFFSET
	.word	.LC0
	.word	STA_MODIFY_KEY_MASK
	.word	STA_CONTROL_MODIFY_MSK
	.word	CMD_SYNC
	.size	il4965_set_wep_dynamic_key_info, .-il4965_set_wep_dynamic_key_info
	.comm	WEP_KEY_LEN_128,4,4
	.comm	WEP_INVALID_OFFSET,4,4
	.comm	STA_MODIFY_KEY_MASK,4,4
	.comm	STA_KEY_MULTICAST_MSK,4,4
	.comm	STA_KEY_FLG_WEP,4,4
	.comm	STA_KEY_FLG_NO_ENC,4,4
	.comm	STA_KEY_FLG_MAP_KEY_MSK,4,4
	.comm	STA_KEY_FLG_KEY_SIZE_MSK,4,4
	.comm	STA_KEY_FLG_KEYID_POS,4,4
	.comm	STA_KEY_FLG_INVALID,4,4
	.comm	STA_KEY_FLG_ENCRYPT_MSK,4,4
	.comm	STA_CONTROL_MODIFY_MSK,4,4
	.comm	IEEE80211_KEY_FLAG_GENERATE_IV,4,4
	.comm	CMD_SYNC,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
