	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function il4965_set_wep_dynamic_key_info
_il4965_set_wep_dynamic_key_info:       ## @il4965_set_wep_dynamic_key_info
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %rbx
	movq	%rdi, %r12
	addq	$24, %rdi
	callq	_lockdep_assert_held
	movq	_IEEE80211_KEY_FLAG_GENERATE_IV@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 28(%rbx)
	movq	_STA_KEY_FLG_WEP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	_STA_KEY_FLG_MAP_KEY_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)                 ## 4-byte Spill
	movl	(%rbx), %edi
	movq	_STA_KEY_FLG_KEYID_POS@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %edi
	callq	_cpu_to_le16
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_STA_KEY_FLG_INVALID@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	8(%rbx), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movq	_WEP_KEY_LEN_128@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	_STA_KEY_FLG_KEY_SIZE_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	16(%r12), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	_STA_KEY_MULTICAST_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	%r12, %rdi
	callq	_spin_lock_irqsave
	movl	24(%rbx), %eax
	movq	8(%r12), %rcx
	movq	%r14, -88(%rbp)                 ## 8-byte Spill
	shlq	$6, %r14
	movl	%eax, 56(%rcx,%r14)
	movq	8(%rbx), %rdx
	movq	%rdx, 32(%rcx,%r14)
	movl	(%rbx), %eax
	movl	%eax, 40(%rcx,%r14)
	movq	48(%rcx,%r14), %rdi
	movq	16(%rbx), %rsi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_memcpy
	movq	8(%r12), %rax
	movq	24(%rax,%r14), %rdi
	addq	$12, %rdi
	movq	16(%rbx), %rsi
	movl	8(%rbx), %edx
	callq	_memcpy
	movq	8(%r12), %rax
	movq	_STA_KEY_FLG_ENCRYPT_MSK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	8(%rax,%r14), %ecx
	movq	_STA_KEY_FLG_NO_ENC@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %ecx
	jne	LBB0_1
## %bb.2:
	movq	%r12, %rdi
	callq	_il_get_free_ucode_key_idx
	movq	8(%r12), %rcx
	movq	%rax, 16(%rcx,%r14)
	jmp	LBB0_3
LBB0_1:
	movq	16(%rax,%r14), %rax
LBB0_3:
	movl	-56(%rbp), %ecx                 ## 4-byte Reload
	orl	-52(%rbp), %ecx                 ## 4-byte Folded Reload
	orl	-44(%rbp), %ecx                 ## 4-byte Folded Reload
	notl	%r15d
	andl	%ecx, %r15d
	xorl	%ecx, %ecx
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	cmpq	%rdx, -80(%rbp)                 ## 8-byte Folded Reload
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	cmovnel	%ecx, %edx
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	cmpq	-88(%rbp), %rsi                 ## 8-byte Folded Reload
	cmovnel	%ecx, %r13d
	orl	%edx, %r13d
	orl	%r15d, %r13d
	movq	_WEP_INVALID_OFFSET@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	leaq	L_.str(%rip), %rsi
	callq	_WARN
	movq	8(%r12), %rax
	leaq	(%rax,%r14), %rsi
	movl	%r13d, 8(%rax,%r14)
	movq	_STA_MODIFY_KEY_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 4(%rax,%r14)
	movq	_STA_CONTROL_MODIFY_MSK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, (%rax,%r14)
	leaq	-96(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_memcpy
	movq	%r12, %rdi
	callq	_spin_unlock_irqrestore
	movq	_CMD_SYNC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_il_send_add_sta
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IEEE80211_KEY_FLAG_GENERATE_IV,4,2 ## @IEEE80211_KEY_FLAG_GENERATE_IV
	.comm	_STA_KEY_FLG_WEP,4,2            ## @STA_KEY_FLG_WEP
	.comm	_STA_KEY_FLG_MAP_KEY_MSK,4,2    ## @STA_KEY_FLG_MAP_KEY_MSK
	.comm	_STA_KEY_FLG_KEYID_POS,4,2      ## @STA_KEY_FLG_KEYID_POS
	.comm	_STA_KEY_FLG_INVALID,4,2        ## @STA_KEY_FLG_INVALID
	.comm	_WEP_KEY_LEN_128,8,3            ## @WEP_KEY_LEN_128
	.comm	_STA_KEY_FLG_KEY_SIZE_MSK,4,2   ## @STA_KEY_FLG_KEY_SIZE_MSK
	.comm	_STA_KEY_MULTICAST_MSK,4,2      ## @STA_KEY_MULTICAST_MSK
	.comm	_STA_KEY_FLG_ENCRYPT_MSK,4,2    ## @STA_KEY_FLG_ENCRYPT_MSK
	.comm	_STA_KEY_FLG_NO_ENC,4,2         ## @STA_KEY_FLG_NO_ENC
	.comm	_WEP_INVALID_OFFSET,8,3         ## @WEP_INVALID_OFFSET
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no space for a new key"

	.comm	_STA_MODIFY_KEY_MASK,4,2        ## @STA_MODIFY_KEY_MASK
	.comm	_STA_CONTROL_MODIFY_MSK,4,2     ## @STA_CONTROL_MODIFY_MSK
	.comm	_CMD_SYNC,4,2                   ## @CMD_SYNC
	.no_dead_strip	_il4965_set_wep_dynamic_key_info
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function il4965_set_wep_dynamic_key_info
_il4965_set_wep_dynamic_key_info:       ; @il4965_set_wep_dynamic_key_info
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x2
	mov	x22, x1
	mov	x19, x0
	add	x0, x0, #24
	bl	_lockdep_assert_held
Lloh0:
	adrp	x8, _IEEE80211_KEY_FLAG_GENERATE_IV@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IEEE80211_KEY_FLAG_GENERATE_IV@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x22, #28]
	bic	w8, w9, w8
	str	w8, [x22, #28]
Lloh3:
	adrp	x8, _STA_KEY_FLG_WEP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _STA_KEY_FLG_WEP@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [sp, #20]                   ; 4-byte Folded Spill
Lloh6:
	adrp	x8, _STA_KEY_FLG_MAP_KEY_MSK@GOTPAGE
Lloh7:
	ldr	x8, [x8, _STA_KEY_FLG_MAP_KEY_MSK@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	str	w8, [sp, #16]                   ; 4-byte Folded Spill
	ldr	w8, [x22]
Lloh9:
	adrp	x9, _STA_KEY_FLG_KEYID_POS@GOTPAGE
Lloh10:
	ldr	x9, [x9, _STA_KEY_FLG_KEYID_POS@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	lsl	w0, w8, w9
	bl	_cpu_to_le16
	str	w0, [sp, #12]                   ; 4-byte Folded Spill
Lloh12:
	adrp	x8, _STA_KEY_FLG_INVALID@GOTPAGE
Lloh13:
	ldr	x8, [x8, _STA_KEY_FLG_INVALID@GOTPAGEOFF]
Lloh14:
	ldr	w25, [x8]
	ldr	x26, [x22, #8]
Lloh15:
	adrp	x8, _WEP_KEY_LEN_128@GOTPAGE
Lloh16:
	ldr	x8, [x8, _WEP_KEY_LEN_128@GOTPAGEOFF]
Lloh17:
	adrp	x9, _STA_KEY_FLG_KEY_SIZE_MSK@GOTPAGE
Lloh18:
	ldr	x9, [x9, _STA_KEY_FLG_KEY_SIZE_MSK@GOTPAGEOFF]
Lloh19:
	ldr	x24, [x8]
Lloh20:
	ldr	w28, [x9]
	ldr	x27, [x19, #16]
Lloh21:
	adrp	x8, _STA_KEY_MULTICAST_MSK@GOTPAGE
Lloh22:
	ldr	x8, [x8, _STA_KEY_MULTICAST_MSK@GOTPAGEOFF]
Lloh23:
	ldr	w23, [x8]
	mov	x0, x19
	bl	_spin_lock_irqsave
	ldr	w8, [x22, #24]
	ldr	x9, [x19, #8]
	lsl	x21, x20, #6
	add	x9, x9, x21
	str	w8, [x9, #56]
	ldp	x2, x1, [x22, #8]
	str	x2, [x9, #32]
	ldr	w8, [x22]
	str	w8, [x9, #40]
	ldr	x0, [x9, #48]
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_memcpy
	ldr	x8, [x19, #8]
	add	x8, x8, x21
	ldr	x8, [x8, #24]
	add	x0, x8, #12
	ldr	x1, [x22, #16]
	ldr	w2, [x22, #8]
	bl	_memcpy
	ldr	x8, [x19, #8]
	add	x9, x8, x21
	ldr	w9, [x9, #8]
Lloh24:
	adrp	x10, _STA_KEY_FLG_ENCRYPT_MSK@GOTPAGE
Lloh25:
	ldr	x10, [x10, _STA_KEY_FLG_ENCRYPT_MSK@GOTPAGEOFF]
Lloh26:
	ldr	w10, [x10]
	and	w9, w10, w9
Lloh27:
	adrp	x10, _STA_KEY_FLG_NO_ENC@GOTPAGE
Lloh28:
	ldr	x10, [x10, _STA_KEY_FLG_NO_ENC@GOTPAGEOFF]
Lloh29:
	ldr	w10, [x10]
	cmp	w9, w10
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_il_get_free_ucode_key_idx
	ldr	x8, [x19, #8]
	add	x8, x8, x20, lsl #6
	str	x0, [x8, #16]
	b	LBB0_3
LBB0_2:
	add	x8, x8, x20, lsl #6
	ldr	x0, [x8, #16]
LBB0_3:
	ldp	w9, w8, [sp, #16]               ; 8-byte Folded Reload
	orr	w8, w9, w8
	ldr	w9, [sp, #12]                   ; 4-byte Folded Reload
	orr	w8, w8, w9
	bic	w8, w8, w25
	cmp	x26, x24
	csel	w9, w28, wzr, eq
	orr	w8, w9, w8
	cmp	x27, x20
	csel	w9, w23, wzr, eq
	orr	w21, w8, w9
Lloh30:
	adrp	x8, _WEP_INVALID_OFFSET@GOTPAGE
Lloh31:
	ldr	x8, [x8, _WEP_INVALID_OFFSET@GOTPAGEOFF]
Lloh32:
	ldr	x8, [x8]
	cmp	x0, x8
	cset	w0, eq
Lloh33:
	adrp	x1, l_.str@PAGE
Lloh34:
	add	x1, x1, l_.str@PAGEOFF
	bl	_WARN
	ldr	x8, [x19, #8]
	add	x1, x8, x20, lsl #6
	str	w21, [x1, #8]
Lloh35:
	adrp	x8, _STA_MODIFY_KEY_MASK@GOTPAGE
Lloh36:
	ldr	x8, [x8, _STA_MODIFY_KEY_MASK@GOTPAGEOFF]
Lloh37:
	ldr	w8, [x8]
	str	w8, [x1, #4]
Lloh38:
	adrp	x8, _STA_CONTROL_MODIFY_MSK@GOTPAGE
Lloh39:
	ldr	x8, [x8, _STA_CONTROL_MODIFY_MSK@GOTPAGEOFF]
Lloh40:
	ldr	w8, [x8]
	str	w8, [x1]
	add	x0, sp, #24
	mov	w2, #4
	bl	_memcpy
	mov	x0, x19
	bl	_spin_unlock_irqrestore
Lloh41:
	adrp	x8, _CMD_SYNC@GOTPAGE
Lloh42:
	ldr	x8, [x8, _CMD_SYNC@GOTPAGEOFF]
Lloh43:
	ldr	w2, [x8]
	add	x1, sp, #24
	mov	x0, x19
	bl	_il_send_add_sta
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh19
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_IEEE80211_KEY_FLAG_GENERATE_IV,4,2 ; @IEEE80211_KEY_FLAG_GENERATE_IV
	.comm	_STA_KEY_FLG_WEP,4,2            ; @STA_KEY_FLG_WEP
	.comm	_STA_KEY_FLG_MAP_KEY_MSK,4,2    ; @STA_KEY_FLG_MAP_KEY_MSK
	.comm	_STA_KEY_FLG_KEYID_POS,4,2      ; @STA_KEY_FLG_KEYID_POS
	.comm	_STA_KEY_FLG_INVALID,4,2        ; @STA_KEY_FLG_INVALID
	.comm	_WEP_KEY_LEN_128,8,3            ; @WEP_KEY_LEN_128
	.comm	_STA_KEY_FLG_KEY_SIZE_MSK,4,2   ; @STA_KEY_FLG_KEY_SIZE_MSK
	.comm	_STA_KEY_MULTICAST_MSK,4,2      ; @STA_KEY_MULTICAST_MSK
	.comm	_STA_KEY_FLG_ENCRYPT_MSK,4,2    ; @STA_KEY_FLG_ENCRYPT_MSK
	.comm	_STA_KEY_FLG_NO_ENC,4,2         ; @STA_KEY_FLG_NO_ENC
	.comm	_WEP_INVALID_OFFSET,8,3         ; @WEP_INVALID_OFFSET
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no space for a new key"

	.comm	_STA_MODIFY_KEY_MASK,4,2        ; @STA_MODIFY_KEY_MASK
	.comm	_STA_CONTROL_MODIFY_MSK,4,2     ; @STA_CONTROL_MODIFY_MSK
	.comm	_CMD_SYNC,4,2                   ; @CMD_SYNC
	.no_dead_strip	_il4965_set_wep_dynamic_key_info
.subsections_via_symbols
