	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wl12xx_op_channel_switch
_wl12xx_op_channel_switch:              ## @wl12xx_op_channel_switch
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, -56(%rbp)                 ## 8-byte Spill
	movq	%rsi, %r13
	movq	%rdi, %r14
	movq	(%rdi), %rbx
	movq	%rsi, %rdi
	callq	_wl12xx_vif_to_data
	movq	%rax, %r12
	movq	_DEBUG_MAC80211@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_wl1271_debug
	movq	%rbx, %rdi
	callq	_wl1271_tx_flush
	leaq	8(%rbx), %rdi
	movq	%rdi, %r15
	callq	_mutex_lock
	movq	(%rbx), %rax
	movq	_WLCORE_STATE_OFF@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	_WLVIF_FLAG_STA_ASSOCIATED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$8, %r12
	movq	%r12, %rsi
	callq	_test_bit
	testq	%rax, %rax
	movq	%r15, %r14
	je	LBB0_10
## %bb.2:
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_ieee80211_chswitch_done
	jmp	LBB0_10
LBB0_3:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	movq	(%rbx), %rax
	movq	_WLCORE_STATE_ON@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	setne	%dil
	callq	_unlikely
	testq	%rax, %rax
	movq	%r15, %r14
	jne	LBB0_10
## %bb.4:
	movl	12(%rbx), %edi
	callq	_pm_runtime_get_sync
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:
	movq	_WLVIF_FLAG_STA_ASSOCIATED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r12, %r15
	addq	$8, %r12
	movq	%r12, %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movq	16(%rbx), %rax
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r13, %rdx
	callq	*(%rax)
	testl	%eax, %eax
	jne	LBB0_9
## %bb.8:
	movq	_WLVIF_FLAG_CS_PROGRESS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r12, %rsi
	callq	_set_bit
	movl	4(%r15), %edi
	callq	_ieee80211_tu_to_usec
	imulq	(%r13), %rax
	movq	%rax, %rdi
	callq	_usecs_to_jiffies
	movq	%rax, %r13
	movl	$5000, %edi                     ## imm = 0x1388
	callq	_msecs_to_jiffies
	addq	%rax, %r13
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%r15, %rsi
	movq	%r13, %rdx
	callq	_ieee80211_queue_delayed_work
LBB0_9:
	movl	12(%rbx), %edi
	callq	_pm_runtime_mark_last_busy
	movl	12(%rbx), %edi
	callq	_pm_runtime_put_autosuspend
	jmp	LBB0_10
LBB0_5:
	movl	12(%rbx), %edi
	callq	_pm_runtime_put_noidle
LBB0_10:
	movq	%r14, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_DEBUG_MAC80211,4,2             ## @DEBUG_MAC80211
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"mac80211 channel switch"

	.comm	_WLCORE_STATE_OFF,8,3           ## @WLCORE_STATE_OFF
	.comm	_WLVIF_FLAG_STA_ASSOCIATED,4,2  ## @WLVIF_FLAG_STA_ASSOCIATED
	.comm	_WLCORE_STATE_ON,8,3            ## @WLCORE_STATE_ON
	.comm	_WLVIF_FLAG_CS_PROGRESS,4,2     ## @WLVIF_FLAG_CS_PROGRESS
	.no_dead_strip	_wl12xx_op_channel_switch
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wl12xx_op_channel_switch
_wl12xx_op_channel_switch:              ; @wl12xx_op_channel_switch
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x23, x2
	mov	x24, x1
	mov	x21, x0
	ldr	x20, [x0]
	mov	x0, x1
	bl	_wl12xx_vif_to_data
	mov	x22, x0
Lloh0:
	adrp	x8, _DEBUG_MAC80211@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DEBUG_MAC80211@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_wl1271_debug
	mov	x0, x20
	bl	_wl1271_tx_flush
	add	x19, x20, #8
	mov	x0, x19
	bl	_mutex_lock
	ldr	x8, [x20]
Lloh5:
	adrp	x9, _WLCORE_STATE_OFF@GOTPAGE
Lloh6:
	ldr	x9, [x9, _WLCORE_STATE_OFF@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_3
; %bb.1:
Lloh8:
	adrp	x8, _WLVIF_FLAG_STA_ASSOCIATED@GOTPAGE
Lloh9:
	ldr	x8, [x8, _WLVIF_FLAG_STA_ASSOCIATED@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	add	x1, x22, #8
	bl	_test_bit
	cbz	x0, LBB0_10
; %bb.2:
	mov	x0, x24
	mov	w1, #0
	bl	_ieee80211_chswitch_done
	b	LBB0_10
LBB0_3:
	ldr	x8, [x20]
Lloh11:
	adrp	x9, _WLCORE_STATE_ON@GOTPAGE
Lloh12:
	ldr	x9, [x9, _WLCORE_STATE_ON@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, ne
	bl	_unlikely
	cbnz	x0, LBB0_10
; %bb.4:
	ldr	w0, [x20, #12]
	bl	_pm_runtime_get_sync
	tbnz	w0, #31, LBB0_9
; %bb.5:
Lloh14:
	adrp	x8, _WLVIF_FLAG_STA_ASSOCIATED@GOTPAGE
Lloh15:
	ldr	x8, [x8, _WLVIF_FLAG_STA_ASSOCIATED@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	add	x24, x22, #8
	mov	x1, x24
	bl	_test_bit
	cbz	x0, LBB0_8
; %bb.6:
	ldr	x8, [x20, #16]
	ldr	x8, [x8]
	mov	x0, x20
	mov	x1, x22
	mov	x2, x23
	blr	x8
	cbnz	w0, LBB0_8
; %bb.7:
Lloh17:
	adrp	x8, _WLVIF_FLAG_CS_PROGRESS@GOTPAGE
Lloh18:
	ldr	x8, [x8, _WLVIF_FLAG_CS_PROGRESS@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	mov	x1, x24
	bl	_set_bit
	ldr	w0, [x22, #4]
	bl	_ieee80211_tu_to_usec
	ldr	x8, [x23]
	mul	x0, x8, x0
	bl	_usecs_to_jiffies
	mov	x23, x0
	mov	w0, #5000
	bl	_msecs_to_jiffies
	add	x2, x0, x23
	mov	x0, x21
	mov	x1, x22
	bl	_ieee80211_queue_delayed_work
LBB0_8:
	ldr	w0, [x20, #12]
	bl	_pm_runtime_mark_last_busy
	ldr	w0, [x20, #12]
	bl	_pm_runtime_put_autosuspend
	b	LBB0_10
LBB0_9:
	ldr	w0, [x20, #12]
	bl	_pm_runtime_put_noidle
LBB0_10:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_mutex_unlock
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_DEBUG_MAC80211,4,2             ; @DEBUG_MAC80211
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"mac80211 channel switch"

	.comm	_WLCORE_STATE_OFF,8,3           ; @WLCORE_STATE_OFF
	.comm	_WLVIF_FLAG_STA_ASSOCIATED,4,2  ; @WLVIF_FLAG_STA_ASSOCIATED
	.comm	_WLCORE_STATE_ON,8,3            ; @WLCORE_STATE_ON
	.comm	_WLVIF_FLAG_CS_PROGRESS,4,2     ; @WLVIF_FLAG_CS_PROGRESS
	.no_dead_strip	_wl12xx_op_channel_switch
.subsections_via_symbols
