	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function _iwl_dbgfs_inject_beacon_ie
__iwl_dbgfs_inject_beacon_ie:           ## @_iwl_dbgfs_inject_beacon_ie
	.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
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -96(%rbp)
	movl	%edx, %ebx
	shrl	$31, %ebx
	addl	%edx, %ebx
	sarl	%ebx
	movq	_U8_MAX@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jge	LBB0_17
## %bb.1:
	movl	%edx, %r15d
	movq	%rsi, %r14
	movq	%rdi, %r12
	callq	_iwl_mvm_firmware_running
	testl	%eax, %eax
	je	LBB0_18
## %bb.2:
	movq	%r12, %rdi
	callq	_iwl_mvm_has_new_tx_api
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movq	16(%r12), %rdi
	movq	_IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_fw_has_api
	testl	%eax, %eax
	je	LBB0_17
LBB0_4:
	movl	%r15d, -44(%rbp)                ## 4-byte Spill
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_rcu_read_lock
	movq	_NUM_MAC_INDEX_DRIVER@GOTPCREL(%rip), %r13
	cmpl	$0, (%r13)
	jle	LBB0_16
## %bb.5:
	xorl	%r14d, %r14d
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_7 Depth=1
	incl	%r14d
	movl	(%r13), %eax
	cmpl	%eax, %r14d
	jge	LBB0_10
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	movl	%r14d, %esi
	movl	$1, %edx
	callq	_iwl_mvm_rcu_dereference_vif_id
	movq	%rax, %r15
	testq	%rax, %rax
	je	LBB0_6
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	(%r15), %rax
	movq	_NL80211_IFTYPE_AP@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_6
## %bb.9:
	movl	(%r13), %eax
LBB0_10:
	cmpl	%eax, %r14d
	movl	$0, %r14d
	je	LBB0_16
## %bb.11:
	testq	%r15, %r15
	je	LBB0_16
## %bb.12:
	movq	8(%r12), %rdi
	movl	%ebx, (%rdi)
	movq	%r15, %rsi
	xorl	%edx, %edx
	callq	_ieee80211_beacon_get_template
	testq	%rax, %rax
	je	LBB0_16
## %bb.13:
	movq	%rax, %r13
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	incl	%eax
	cmpl	$3, %eax
	jb	LBB0_22
## %bb.14:
	movq	%r13, %rdi
	movl	%ebx, %esi
	callq	_skb_put_zero
	movl	%eax, %edi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movl	%ebx, %edx
	callq	_hex2bin
	testq	%rax, %rax
	je	LBB0_22
## %bb.15:
	movq	%r13, %rdi
	callq	_dev_kfree_skb
LBB0_16:
	xorl	%eax, %eax
	callq	_rcu_read_unlock
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_20
LBB0_17:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_19
LBB0_18:
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_19:
	xorl	%r14d, %r14d
LBB0_20:
	subl	(%rax), %r14d
LBB0_21:
	movl	%r14d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_22:
	movl	$1, (%r12)
	movq	%r15, %rdi
	callq	_iwl_mvm_vif_from_mac80211
	movq	%rax, %r14
	movq	%r13, %rdi
	callq	_IEEE80211_SKB_CB
	movq	%rax, %rdi
	movq	%r15, %rsi
	callq	_iwl_mvm_mac_ctxt_get_lowest_rate
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_iwl_mvm_mac80211_idx_to_hwrate
	movq	_IWL_FIRST_CCK_RATE@GOTPCREL(%rip), %rcx
	movl	$0, %edi
	cmpq	(%rcx), %rbx
	jne	LBB0_24
## %bb.23:
	movq	_IWL_MAC_BEACON_CCK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
LBB0_24:
	orl	%eax, %edi
	callq	_cpu_to_le16
	movq	%rax, -72(%rbp)
	movl	(%r13), %edi
	callq	_cpu_to_le16
	movq	%rax, -80(%rbp)
	movl	(%r14), %edi
	callq	_cpu_to_le32
	movl	%eax, -88(%rbp)
	leaq	-92(%rbp), %rsi
	movl	8(%r13), %ecx
	movq	(%r13), %r8
	leaq	-96(%rbp), %r14
	movq	%r12, %rdi
	movq	%r14, %rdx
	callq	_iwl_mvm_mac_ctxt_set_tim
	leaq	4(%r12), %rbx
	movq	%rbx, %rdi
	callq	_mutex_lock
	movq	%r12, %rdi
	movq	%r13, %rsi
	movq	%r14, %rdx
	movl	$32, %ecx
	callq	_iwl_mvm_mac_ctxt_send_beacon_cmd
	movq	%rbx, %rdi
	callq	_mutex_unlock
	movq	%r13, %rdi
	callq	_dev_kfree_skb
	xorl	%eax, %eax
	callq	_rcu_read_unlock
	xorl	%r14d, %r14d
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.comm	_U8_MAX,4,2                     ## @U8_MAX
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_EIO,4,2                        ## @EIO
	.comm	_IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE,4,2 ## @IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE
	.comm	_NUM_MAC_INDEX_DRIVER,4,2       ## @NUM_MAC_INDEX_DRIVER
	.comm	_NL80211_IFTYPE_AP,8,3          ## @NL80211_IFTYPE_AP
	.comm	_IWL_FIRST_CCK_RATE,8,3         ## @IWL_FIRST_CCK_RATE
	.comm	_IWL_MAC_BEACON_CCK,4,2         ## @IWL_MAC_BEACON_CCK
	.no_dead_strip	__iwl_dbgfs_inject_beacon_ie
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function _iwl_dbgfs_inject_beacon_ie
__iwl_dbgfs_inject_beacon_ie:           ; @_iwl_dbgfs_inject_beacon_ie
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	stp	xzr, xzr, [sp]
	cmp	w2, #0
	cinc	w8, w2, lt
	asr	w21, w8, #1
Lloh0:
	adrp	x8, _U8_MAX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _U8_MAX@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w21, w8
	b.ge	LBB0_16
; %bb.1:
	mov	x22, x2
	mov	x20, x1
	mov	x19, x0
	bl	_iwl_mvm_firmware_running
	cbz	w0, LBB0_19
; %bb.2:
	mov	x0, x19
	bl	_iwl_mvm_has_new_tx_api
	cbnz	w0, LBB0_4
; %bb.3:
	ldr	x0, [x19, #16]
Lloh3:
	adrp	x8, _IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_fw_has_api
	cbz	w0, LBB0_16
LBB0_4:
	bl	_rcu_read_lock
Lloh6:
	adrp	x25, _NUM_MAC_INDEX_DRIVER@GOTPAGE
Lloh7:
	ldr	x25, [x25, _NUM_MAC_INDEX_DRIVER@GOTPAGEOFF]
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.5:
	mov	w23, #0
Lloh8:
	adrp	x26, _NL80211_IFTYPE_AP@GOTPAGE
Lloh9:
	ldr	x26, [x26, _NL80211_IFTYPE_AP@GOTPAGEOFF]
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	w23, w23, #1
	ldr	w8, [x25]
	cmp	w23, w8
	b.ge	LBB0_10
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x23
	mov	w2, #1
	bl	_iwl_mvm_rcu_dereference_vif_id
	mov	x24, x0
	cbz	x0, LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x24]
	ldr	x9, [x26]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.9:
	ldr	w8, [x25]
LBB0_10:
	cmp	w23, w8
	ccmp	x24, #0, #4, ne
	b.eq	LBB0_15
; %bb.11:
	ldr	x0, [x19, #8]
	str	w21, [x0]
	mov	x1, x24
	mov	x2, #0
	bl	_ieee80211_beacon_get_template
	cbz	x0, LBB0_15
; %bb.12:
	mov	x23, x0
	add	w8, w22, #1
	cmp	w8, #3
	b.lo	LBB0_20
; %bb.13:
	mov	x0, x23
	mov	x1, x21
	bl	_skb_put_zero
	mov	x1, x20
	mov	x2, x21
	bl	_hex2bin
	cbz	x0, LBB0_20
; %bb.14:
	mov	x0, x23
	bl	_dev_kfree_skb
LBB0_15:
	bl	_rcu_read_unlock
LBB0_16:
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_17:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_18:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_19:
Lloh12:
	adrp	x8, _EIO@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_17
LBB0_20:
	mov	w8, #1
	mov	x20, x19
	str	w8, [x20], #4
	mov	x0, x24
	bl	_iwl_mvm_vif_from_mac80211
	mov	x21, x0
	mov	x0, x23
	bl	_IEEE80211_SKB_CB
	mov	x1, x24
	bl	_iwl_mvm_mac_ctxt_get_lowest_rate
	mov	x22, x0
	bl	_iwl_mvm_mac80211_idx_to_hwrate
Lloh14:
	adrp	x8, _IWL_FIRST_CCK_RATE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _IWL_FIRST_CCK_RATE@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
Lloh17:
	adrp	x9, _IWL_MAC_BEACON_CCK@GOTPAGE
Lloh18:
	ldr	x9, [x9, _IWL_MAC_BEACON_CCK@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
	cmp	x22, x8
	csel	w8, w9, wzr, eq
	orr	w0, w8, w0
	bl	_cpu_to_le16
	str	x0, [sp, #24]
	ldr	w0, [x23]
	bl	_cpu_to_le16
	str	x0, [sp, #16]
	ldr	w0, [x21]
	bl	_cpu_to_le32
	str	w0, [sp, #8]
	mov	x8, sp
	orr	x1, x8, #0x4
	ldr	w3, [x23, #8]
	ldr	x4, [x23]
	mov	x2, sp
	mov	x0, x19
	bl	_iwl_mvm_mac_ctxt_set_tim
	mov	x0, x20
	bl	_mutex_lock
	mov	x2, sp
	mov	x0, x19
	mov	x1, x23
	mov	w3, #32
	bl	_iwl_mvm_mac_ctxt_send_beacon_cmd
	mov	x0, x20
	bl	_mutex_unlock
	mov	x0, x23
	bl	_dev_kfree_skb
	bl	_rcu_read_unlock
	mov	w0, #0
	b	LBB0_18
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_U8_MAX,4,2                     ; @U8_MAX
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_EIO,4,2                        ; @EIO
	.comm	_IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE,4,2 ; @IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE
	.comm	_NUM_MAC_INDEX_DRIVER,4,2       ; @NUM_MAC_INDEX_DRIVER
	.comm	_NL80211_IFTYPE_AP,8,3          ; @NL80211_IFTYPE_AP
	.comm	_IWL_FIRST_CCK_RATE,8,3         ; @IWL_FIRST_CCK_RATE
	.comm	_IWL_MAC_BEACON_CCK,4,2         ; @IWL_MAC_BEACON_CCK
	.no_dead_strip	__iwl_dbgfs_inject_beacon_ie
.subsections_via_symbols
