	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ex_btc8723b1ant_scan_notify    ## -- Begin function ex_btc8723b1ant_scan_notify
	.p2align	4, 0x90
_ex_btc8723b1ant_scan_notify:           ## @ex_btc8723b1ant_scan_notify
	.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	40(%rdi), %r14
	movl	$0, -44(%rbp)
	movl	$0, -52(%rbp)
	movl	$0, -48(%rbp)
	cmpq	$0, 32(%rdi)
	jne	LBB0_20
## %bb.1:
	movq	%rdi, %rbx
	cmpq	$0, 24(%rdi)
	jne	LBB0_20
## %bb.2:
	movq	%rsi, %r15
	movq	_BTC_SCAN_START@GOTPCREL(%rip), %r12
	movq	_coex_sta@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	cmpq	%rsi, (%r12)
	jne	LBB0_4
## %bb.3:
	movl	$1, (%rax)
	movq	_COMP_BT_COEXIST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DBG_LOUD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str(%rip), %rcx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_RT_TRACE
	movq	_FORCE_EXEC@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	movl	$8, %ecx
	callq	_halbtc8723b1ant_ps_tdma
	movq	_BTC_ANT_PATH_PTA@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r12), %edx
	movq	%rbx, %rdi
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_halbtc8723b1ant_set_ant_path
	movq	%rbx, %rdi
	movl	$2376, %esi                     ## imm = 0x948
	callq	*(%rbx)
	movl	%eax, %r12d
	movq	%rbx, %rdi
	movl	$1893, %esi                     ## imm = 0x765
	callq	*8(%rbx)
	movq	%rax, %r13
	movq	%rbx, %rdi
	movl	$103, %esi
	callq	*8(%rbx)
	movq	_COMP_BT_COEXIST@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	_DBG_LOUD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%rax, (%rsp)
	leaq	L_.str.1(%rip), %rcx
	movq	%r14, %rdi
	movl	%r12d, %r8d
	movq	_BTC_SCAN_START@GOTPCREL(%rip), %r12
	movq	%r13, %r9
	movq	_coex_sta@GOTPCREL(%rip), %r13
	xorl	%eax, %eax
	callq	_RT_TRACE
	jmp	LBB0_5
LBB0_4:
	movl	$0, (%rax)
	movq	_COMP_BT_COEXIST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DBG_LOUD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rcx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_RT_TRACE
	movq	_BTC_GET_U1_AP_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%r13), %rdx
	addq	$4, %rdx
	movq	%rbx, %rdi
	callq	*16(%rbx)
LBB0_5:
	movq	(%r13), %rax
	cmpq	$0, 16(%rax)
	jne	LBB0_20
## %bb.6:
	movq	_BTC_GET_BL_HS_OPERATION@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-52(%rbp), %rdx
	movq	%rbx, %rdi
	callq	*16(%rbx)
	movq	_BTC_GET_BL_WIFI_CONNECTED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdx
	movq	%rbx, %rdi
	callq	*16(%rbx)
	movq	%rbx, %rdi
	callq	_halbtc8723b1ant_query_bt_info
	movq	_BTC_GET_U4_WIFI_LINK_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rdx
	movq	%rbx, %rdi
	callq	*16(%rbx)
	cmpl	$131072, -48(%rbp)              ## imm = 0x20000
	jl	LBB0_8
## %bb.7:
	movq	_NORMAL_EXEC@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_halbtc8723b1ant_limited_tx
	movl	(%r14), %esi
	movl	$5, %r8d
	movq	%rbx, %rdi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_halbtc8723b1ant_limited_rx
	movq	%rbx, %rdi
	callq	_halbtc8723b1ant_action_wifi_multiport
	jmp	LBB0_20
LBB0_8:
	movq	(%r13), %rax
	cmpq	$0, 8(%rax)
	je	LBB0_10
## %bb.9:
	movq	%rbx, %rdi
	callq	_halbtc8723b1ant_action_bt_inquiry
	jmp	LBB0_20
LBB0_10:
	cmpl	$0, -52(%rbp)
	je	LBB0_12
## %bb.11:
	movq	%rbx, %rdi
	callq	_halbtc8723b1ant_action_hs
LBB0_20:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	cmpq	%r15, (%r12)
	jne	LBB0_16
## %bb.13:
	movq	_COMP_BT_COEXIST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DBG_LOUD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str(%rip), %rcx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_RT_TRACE
	cmpl	$0, -44(%rbp)
	je	LBB0_14
## %bb.15:
	movq	%rbx, %rdi
	callq	_btc8723b1ant_action_wifi_conn_scan
	jmp	LBB0_20
LBB0_16:
	movq	_BTC_SCAN_FINISH@GOTPCREL(%rip), %rax
	cmpq	%r15, (%rax)
	jne	LBB0_20
## %bb.17:
	movq	_COMP_BT_COEXIST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DBG_LOUD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rcx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_RT_TRACE
	cmpl	$0, -44(%rbp)
	je	LBB0_18
## %bb.19:
	movq	%rbx, %rdi
	callq	_halbtc8723b1ant_action_wifi_connected
	jmp	LBB0_20
LBB0_14:
	movq	%rbx, %rdi
	callq	_btc8723b1ant_action_wifi_not_conn_scan
	jmp	LBB0_20
LBB0_18:
	movq	%rbx, %rdi
	callq	_btc8723b1ant_action_wifi_not_conn
	jmp	LBB0_20
	.cfi_endproc
                                        ## -- End function
	.comm	_BTC_SCAN_START,8,3             ## @BTC_SCAN_START
	.comm	_coex_sta,8,3                   ## @coex_sta
	.comm	_COMP_BT_COEXIST,4,2            ## @COMP_BT_COEXIST
	.comm	_DBG_LOUD,4,2                   ## @DBG_LOUD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"[BTCoex], SCAN START notify\n"

	.comm	_FORCE_EXEC,4,2                 ## @FORCE_EXEC
	.comm	_BTC_ANT_PATH_PTA,4,2           ## @BTC_ANT_PATH_PTA
L_.str.1:                               ## @.str.1
	.asciz	"[BTCoex], 0x948=0x%x, 0x765=0x%x, 0x67=0x%x\n"

L_.str.2:                               ## @.str.2
	.asciz	"[BTCoex], SCAN FINISH notify\n"

	.comm	_BTC_GET_U1_AP_NUM,4,2          ## @BTC_GET_U1_AP_NUM
	.comm	_BTC_GET_BL_HS_OPERATION,4,2    ## @BTC_GET_BL_HS_OPERATION
	.comm	_BTC_GET_BL_WIFI_CONNECTED,4,2  ## @BTC_GET_BL_WIFI_CONNECTED
	.comm	_BTC_GET_U4_WIFI_LINK_STATUS,4,2 ## @BTC_GET_U4_WIFI_LINK_STATUS
	.comm	_NORMAL_EXEC,4,2                ## @NORMAL_EXEC
	.comm	_BTC_SCAN_FINISH,8,3            ## @BTC_SCAN_FINISH
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ex_btc8723b1ant_scan_notify    ; -- Begin function ex_btc8723b1ant_scan_notify
	.p2align	2
_ex_btc8723b1ant_scan_notify:           ; @ex_btc8723b1ant_scan_notify
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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
	str	xzr, [sp, #40]
	str	wzr, [sp, #36]
	ldp	x8, x20, [x0, #32]
	cbnz	x8, LBB0_12
; %bb.1:
	mov	x19, x0
	ldr	x8, [x0, #24]
	cbnz	x8, LBB0_12
; %bb.2:
	mov	x21, x1
Lloh0:
	adrp	x24, _BTC_SCAN_START@GOTPAGE
Lloh1:
	ldr	x24, [x24, _BTC_SCAN_START@GOTPAGEOFF]
	ldr	x9, [x24]
Lloh2:
	adrp	x25, _coex_sta@GOTPAGE
Lloh3:
	ldr	x25, [x25, _coex_sta@GOTPAGEOFF]
	ldr	x8, [x25]
	cmp	x9, x1
	b.ne	LBB0_4
; %bb.3:
	mov	w9, #1
	str	w9, [x8]
Lloh4:
	adrp	x26, _COMP_BT_COEXIST@GOTPAGE
Lloh5:
	ldr	x26, [x26, _COMP_BT_COEXIST@GOTPAGEOFF]
	ldr	w1, [x26]
Lloh6:
	adrp	x27, _DBG_LOUD@GOTPAGE
Lloh7:
	ldr	x27, [x27, _DBG_LOUD@GOTPAGEOFF]
	ldr	w2, [x27]
Lloh8:
	adrp	x3, l_.str@PAGE
Lloh9:
	add	x3, x3, l_.str@PAGEOFF
	mov	x0, x20
	bl	_RT_TRACE
Lloh10:
	adrp	x22, _FORCE_EXEC@GOTPAGE
Lloh11:
	ldr	x22, [x22, _FORCE_EXEC@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	mov	w2, #0
	mov	w3, #8
	bl	_halbtc8723b1ant_ps_tdma
Lloh12:
	adrp	x8, _BTC_ANT_PATH_PTA@GOTPAGE
Lloh13:
	ldr	x8, [x8, _BTC_ANT_PATH_PTA@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	ldr	w2, [x22]
	mov	x0, x19
	mov	w3, #0
	mov	w4, #0
	bl	_halbtc8723b1ant_set_ant_path
	ldr	x8, [x19]
	mov	x0, x19
	mov	w1, #2376
	blr	x8
	mov	x22, x0
	ldr	x8, [x19, #8]
	mov	x0, x19
	mov	w1, #1893
	blr	x8
	mov	x23, x0
	ldr	x8, [x19, #8]
	mov	x0, x19
	mov	w1, #103
	blr	x8
	ldr	w1, [x26]
	ldr	w2, [x27]
	stp	x23, x0, [sp, #8]
	str	x22, [sp]
Lloh15:
	adrp	x3, l_.str.1@PAGE
Lloh16:
	add	x3, x3, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_RT_TRACE
	b	LBB0_5
LBB0_4:
	str	wzr, [x8]
Lloh17:
	adrp	x8, _COMP_BT_COEXIST@GOTPAGE
Lloh18:
	ldr	x8, [x8, _COMP_BT_COEXIST@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
Lloh20:
	adrp	x8, _DBG_LOUD@GOTPAGE
Lloh21:
	ldr	x8, [x8, _DBG_LOUD@GOTPAGEOFF]
Lloh22:
	ldr	w2, [x8]
Lloh23:
	adrp	x3, l_.str.2@PAGE
Lloh24:
	add	x3, x3, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_RT_TRACE
	ldr	x8, [x19, #16]
Lloh25:
	adrp	x9, _BTC_GET_U1_AP_NUM@GOTPAGE
Lloh26:
	ldr	x9, [x9, _BTC_GET_U1_AP_NUM@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x9]
	ldr	x9, [x25]
	add	x2, x9, #4
	mov	x0, x19
	blr	x8
LBB0_5:
	ldr	x8, [x25]
	ldr	x8, [x8, #16]
	cbnz	x8, LBB0_12
; %bb.6:
	ldr	x8, [x19, #16]
Lloh28:
	adrp	x9, _BTC_GET_BL_HS_OPERATION@GOTPAGE
Lloh29:
	ldr	x9, [x9, _BTC_GET_BL_HS_OPERATION@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x9]
	add	x2, sp, #40
	mov	x0, x19
	blr	x8
	ldr	x8, [x19, #16]
Lloh31:
	adrp	x9, _BTC_GET_BL_WIFI_CONNECTED@GOTPAGE
Lloh32:
	ldr	x9, [x9, _BTC_GET_BL_WIFI_CONNECTED@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x9]
	add	x2, sp, #44
	mov	x0, x19
	blr	x8
	mov	x0, x19
	bl	_halbtc8723b1ant_query_bt_info
	ldr	x8, [x19, #16]
Lloh34:
	adrp	x9, _BTC_GET_U4_WIFI_LINK_STATUS@GOTPAGE
Lloh35:
	ldr	x9, [x9, _BTC_GET_U4_WIFI_LINK_STATUS@GOTPAGEOFF]
Lloh36:
	ldr	w1, [x9]
	add	x2, sp, #36
	mov	x0, x19
	blr	x8
	ldr	w8, [sp, #36]
	cmp	w8, #32, lsl #12                ; =131072
	b.lt	LBB0_8
; %bb.7:
Lloh37:
	adrp	x20, _NORMAL_EXEC@GOTPAGE
Lloh38:
	ldr	x20, [x20, _NORMAL_EXEC@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	mov	w2, #0
	mov	w3, #0
	mov	w4, #0
	mov	w5, #0
	bl	_halbtc8723b1ant_limited_tx
	ldr	w1, [x20]
	mov	x0, x19
	mov	w2, #0
	mov	w3, #0
	mov	w4, #5
	bl	_halbtc8723b1ant_limited_rx
	mov	x0, x19
	bl	_halbtc8723b1ant_action_wifi_multiport
	b	LBB0_12
LBB0_8:
	ldr	x8, [x25]
	ldr	x8, [x8, #8]
	cbz	x8, LBB0_10
; %bb.9:
	mov	x0, x19
	bl	_halbtc8723b1ant_action_bt_inquiry
	b	LBB0_12
LBB0_10:
	ldr	w8, [sp, #40]
	cbz	w8, LBB0_13
; %bb.11:
	mov	x0, x19
	bl	_halbtc8723b1ant_action_hs
LBB0_12:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_13:
	ldr	x8, [x24]
	cmp	x8, x21
	b.ne	LBB0_16
; %bb.14:
Lloh39:
	adrp	x8, _COMP_BT_COEXIST@GOTPAGE
Lloh40:
	ldr	x8, [x8, _COMP_BT_COEXIST@GOTPAGEOFF]
Lloh41:
	ldr	w1, [x8]
Lloh42:
	adrp	x8, _DBG_LOUD@GOTPAGE
Lloh43:
	ldr	x8, [x8, _DBG_LOUD@GOTPAGEOFF]
Lloh44:
	ldr	w2, [x8]
Lloh45:
	adrp	x3, l_.str@PAGE
Lloh46:
	add	x3, x3, l_.str@PAGEOFF
	mov	x0, x20
	bl	_RT_TRACE
	ldr	w8, [sp, #44]
	cbz	w8, LBB0_19
; %bb.15:
	mov	x0, x19
	bl	_btc8723b1ant_action_wifi_conn_scan
	b	LBB0_12
LBB0_16:
Lloh47:
	adrp	x8, _BTC_SCAN_FINISH@GOTPAGE
Lloh48:
	ldr	x8, [x8, _BTC_SCAN_FINISH@GOTPAGEOFF]
Lloh49:
	ldr	x8, [x8]
	cmp	x8, x21
	b.ne	LBB0_12
; %bb.17:
Lloh50:
	adrp	x8, _COMP_BT_COEXIST@GOTPAGE
Lloh51:
	ldr	x8, [x8, _COMP_BT_COEXIST@GOTPAGEOFF]
Lloh52:
	ldr	w1, [x8]
Lloh53:
	adrp	x8, _DBG_LOUD@GOTPAGE
Lloh54:
	ldr	x8, [x8, _DBG_LOUD@GOTPAGEOFF]
Lloh55:
	ldr	w2, [x8]
Lloh56:
	adrp	x3, l_.str.2@PAGE
Lloh57:
	add	x3, x3, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_RT_TRACE
	ldr	w8, [sp, #44]
	cbz	w8, LBB0_20
; %bb.18:
	mov	x0, x19
	bl	_halbtc8723b1ant_action_wifi_connected
	b	LBB0_12
LBB0_19:
	mov	x0, x19
	bl	_btc8723b1ant_action_wifi_not_conn_scan
	b	LBB0_12
LBB0_20:
	mov	x0, x19
	bl	_btc8723b1ant_action_wifi_not_conn
	b	LBB0_12
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpAdd	Lloh56, Lloh57
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.cfi_endproc
                                        ; -- End function
	.comm	_BTC_SCAN_START,8,3             ; @BTC_SCAN_START
	.comm	_coex_sta,8,3                   ; @coex_sta
	.comm	_COMP_BT_COEXIST,4,2            ; @COMP_BT_COEXIST
	.comm	_DBG_LOUD,4,2                   ; @DBG_LOUD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"[BTCoex], SCAN START notify\n"

	.comm	_FORCE_EXEC,4,2                 ; @FORCE_EXEC
	.comm	_BTC_ANT_PATH_PTA,4,2           ; @BTC_ANT_PATH_PTA
l_.str.1:                               ; @.str.1
	.asciz	"[BTCoex], 0x948=0x%x, 0x765=0x%x, 0x67=0x%x\n"

l_.str.2:                               ; @.str.2
	.asciz	"[BTCoex], SCAN FINISH notify\n"

	.comm	_BTC_GET_U1_AP_NUM,4,2          ; @BTC_GET_U1_AP_NUM
	.comm	_BTC_GET_BL_HS_OPERATION,4,2    ; @BTC_GET_BL_HS_OPERATION
	.comm	_BTC_GET_BL_WIFI_CONNECTED,4,2  ; @BTC_GET_BL_WIFI_CONNECTED
	.comm	_BTC_GET_U4_WIFI_LINK_STATUS,4,2 ; @BTC_GET_U4_WIFI_LINK_STATUS
	.comm	_NORMAL_EXEC,4,2                ; @NORMAL_EXEC
	.comm	_BTC_SCAN_FINISH,8,3            ; @BTC_SCAN_FINISH
.subsections_via_symbols
