	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_p2p_check_pref_chan            ## -- Begin function p2p_check_pref_chan
	.p2align	4, 0x90
_p2p_check_pref_chan:                   ## @p2p_check_pref_chan
	.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	$200, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movq	%rdx, %r15
	movl	%esi, %r13d
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_P2P_MAX_PREF_CHANNELS@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	leaq	(,%rbx,4), %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rcx
	movq	(%r12), %rsi
	movq	16(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_30
## %bb.1:
	cmpq	$0, 32(%rsi)
	jne	LBB0_30
## %bb.2:
	movq	_P2P_DEV_FORCE_FREQ@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	testl	%edx, (%r15)
	jne	LBB0_30
## %bb.3:
	cmpq	$0, 24(%rsi)
	jne	LBB0_30
## %bb.4:
	movl	%ebx, -164(%rbp)
	movl	8(%rsi), %edi
	leaq	-164(%rbp), %rdx
	movl	%r13d, %esi
	movq	%rcx, -176(%rbp)                ## 8-byte Spill
	callq	*%rax
	movq	-176(%rbp), %rcx                ## 8-byte Reload
	testq	%rax, %rax
	jne	LBB0_30
## %bb.5:
	movq	%r15, -216(%rbp)                ## 8-byte Spill
	leaq	-160(%rbp), %rbx
	cmpl	$0, -164(%rbp)
	movq	%r14, -224(%rbp)                ## 8-byte Spill
	movl	%r13d, -196(%rbp)               ## 4-byte Spill
	je	LBB0_20
## %bb.6:
	xorl	%r15d, %r15d
LBB0_7:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
	leaq	(%rcx,%r15,4), %r14
	movl	%r15d, %eax
	notl	%eax
	movl	%eax, -200(%rbp)                ## 4-byte Spill
	leaq	1(%r15), %rax
	movq	%rax, -208(%rbp)                ## 8-byte Spill
	leaq	(%rcx,%r15,4), %rax
	addq	$4, %rax
	movq	%rax, -232(%rbp)                ## 8-byte Spill
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=2
	decl	%eax
	movl	%eax, -164(%rbp)
	cmpq	%rax, %r15
	jae	LBB0_16
LBB0_8:                                 ##   Parent Loop BB0_7 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r14), %edi
	leaq	-192(%rbp), %rsi
	leaq	-184(%rbp), %rdx
	callq	_p2p_freq_to_channel
	testq	%rax, %rax
	js	LBB0_12
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=2
	movq	(%r12), %rdi
	movq	-192(%rbp), %rsi
	movq	-184(%rbp), %rdx
	callq	_p2p_channels_includes
	testl	%eax, %eax
	jne	LBB0_15
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=2
	testl	%r13d, %r13d
	jne	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	(%r12), %rdi
	addq	$4, %rdi
	movq	-192(%rbp), %rsi
	movq	-184(%rbp), %rdx
	callq	_p2p_channels_includes
	testl	%eax, %eax
	jne	LBB0_15
LBB0_12:                                ##   in Loop: Header=BB0_8 Depth=2
	movl	(%r14), %edx
	movq	%r12, %rdi
	leaq	L_.str(%rip), %rsi
	movl	%r13d, %ecx
	xorl	%eax, %eax
	callq	_p2p_dbg
	movl	-164(%rbp), %eax
	movl	%eax, %edx
	addl	-200(%rbp), %edx                ## 4-byte Folded Reload
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=2
	shll	$2, %edx
	movq	%r14, %rdi
	movq	-232(%rbp), %rsi                ## 8-byte Reload
	callq	_os_memmove
	movl	-164(%rbp), %eax
	jmp	LBB0_14
LBB0_15:                                ##   in Loop: Header=BB0_7 Depth=1
	movl	-164(%rbp), %eax
	movq	-208(%rbp), %r15                ## 8-byte Reload
	cmpq	%rax, %r15
	movq	-176(%rbp), %rcx                ## 8-byte Reload
	jb	LBB0_7
LBB0_16:
	testl	%eax, %eax
	movq	-176(%rbp), %rax                ## 8-byte Reload
	je	LBB0_20
## %bb.17:
	leaq	-160(%rbp), %rbx
	xorl	%r13d, %r13d
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	leaq	-60(%rbp), %rcx
	movl	%ecx, %r15d
	subl	%ebx, %r15d
	movl	(%rax,%r13,4), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	leaq	L_.str.1(%rip), %rdx
	callq	_os_snprintf
	movl	%eax, %r14d
	movl	%r15d, %edi
	movl	%eax, %esi
	callq	_os_snprintf_error
	testq	%rax, %rax
	jne	LBB0_20
## %bb.19:                              ##   in Loop: Header=BB0_18 Depth=1
	movslq	%r14d, %rax
	addq	%rax, %rbx
	incq	%r13
	movl	-164(%rbp), %eax
	cmpq	%rax, %r13
	movq	-176(%rbp), %rax                ## 8-byte Reload
	jb	LBB0_18
LBB0_20:
	movb	$0, (%rbx)
	movl	-164(%rbp), %edx
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	leaq	-160(%rbp), %rcx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_p2p_dbg
	movq	-176(%rbp), %rdx                ## 8-byte Reload
	movl	-164(%rbp), %eax
	testq	%rax, %rax
	movq	-224(%rbp), %r14                ## 8-byte Reload
	movq	-216(%rbp), %r15                ## 8-byte Reload
	movl	-196(%rbp), %r13d               ## 4-byte Reload
	je	LBB0_26
## %bb.21:
	movl	8(%r15), %ecx
	xorl	%ebx, %ebx
LBB0_22:                                ## =>This Inner Loop Header: Depth=1
	cmpl	%ecx, (%rdx,%rbx,4)
	je	LBB0_26
## %bb.23:                              ##   in Loop: Header=BB0_22 Depth=1
	incq	%rbx
	cmpq	%rbx, %rax
	jne	LBB0_22
	jmp	LBB0_24
LBB0_26:
	cmpl	%eax, %ebx
	je	LBB0_24
## %bb.27:
	movl	%ebx, %eax
	movl	(%rdx,%rax,4), %edi
	leaq	-192(%rbp), %rsi
	leaq	-184(%rbp), %rdx
	callq	_p2p_freq_to_channel
	testq	%rax, %rax
	je	LBB0_28
LBB0_24:
	movl	8(%r15), %edx
	leaq	L_.str.3(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_p2p_dbg
	cmpq	$0, (%r14)
	movl	-164(%rbp), %r9d
	movq	%r12, %rdi
	movl	%r13d, %esi
	movq	%r15, %rdx
	movq	%r14, %rcx
	je	LBB0_25
## %bb.29:
	movq	-176(%rbp), %r8                 ## 8-byte Reload
	callq	_p2p_check_pref_chan_recv
	jmp	LBB0_30
LBB0_25:
	movq	-176(%rbp), %r8                 ## 8-byte Reload
	callq	_p2p_check_pref_chan_no_recv
	jmp	LBB0_30
LBB0_28:
	movq	-192(%rbp), %rax
	movq	%rax, 24(%r12)
	movq	-184(%rbp), %rax
	movq	%rax, 16(%r12)
	movq	(%r12), %rsi
	addq	$8, %r12
	movq	%r12, %rdi
	movl	$4, %edx
	callq	_os_memcpy
LBB0_30:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_32
## %bb.31:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_32:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_P2P_MAX_PREF_CHANNELS,4,2      ## @P2P_MAX_PREF_CHANNELS
	.comm	_P2P_DEV_FORCE_FREQ,4,2         ## @P2P_DEV_FORCE_FREQ
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Ignore local driver frequency preference %u MHz since it is not acceptable for P2P use (go=%d)"

L_.str.1:                               ## @.str.1
	.asciz	" %u"

L_.str.2:                               ## @.str.2
	.asciz	"Local driver frequency preference (size=%u):%s"

L_.str.3:                               ## @.str.3
	.asciz	"Peer operating channel preference: %d MHz is not in our preferred channel list"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_p2p_check_pref_chan            ; -- Begin function p2p_check_pref_chan
	.p2align	2
_p2p_check_pref_chan:                   ; @p2p_check_pref_chan
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	sub	sp, sp, #144
	mov	x19, x3
	mov	x21, x2
	mov	x22, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _P2P_MAX_PREF_CHANNELS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _P2P_MAX_PREF_CHANNELS@GOTPAGEOFF]
Lloh5:
	ldr	w12, [x8]
	lsl	x8, x12, #2
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x7fffffff0
	sub	x23, x9, x8
	mov	sp, x23
	ldr	x9, [x0]
	ldr	x8, [x9, #16]
	cbz	x8, LBB0_33
; %bb.1:
	ldr	x10, [x9, #32]
	cbnz	x10, LBB0_33
; %bb.2:
	ldr	w10, [x21]
Lloh8:
	adrp	x11, _P2P_DEV_FORCE_FREQ@GOTPAGE
Lloh9:
	ldr	x11, [x11, _P2P_DEV_FORCE_FREQ@GOTPAGEOFF]
Lloh10:
	ldr	w11, [x11]
	tst	w11, w10
	b.ne	LBB0_33
; %bb.3:
	ldr	x10, [x9, #24]
	cbnz	x10, LBB0_33
; %bb.4:
	stur	w12, [x29, #-192]
	ldr	w0, [x9, #8]
	sub	x2, x29, #192
	mov	x1, x22
	mov	x3, x23
	blr	x8
	cbnz	x0, LBB0_33
; %bb.5:
	ldur	w8, [x29, #-192]
	cbz	w8, LBB0_21
; %bb.6:
	mov	x27, #0
Lloh11:
	adrp	x24, l_.str@PAGE
Lloh12:
	add	x24, x24, l_.str@PAGEOFF
LBB0_7:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	add	x25, x23, x27, lsl #2
	mvn	w28, w27
	add	x8, x27, #1
	stur	x8, [x29, #-216]                ; 8-byte Folded Spill
	add	x26, x23, x8, lsl #2
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=2
	sub	w8, w8, #1
	stur	w8, [x29, #-192]
	cmp	x27, x8
	b.hs	LBB0_17
LBB0_9:                                 ;   Parent Loop BB0_7 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w0, [x25]
	sub	x1, x29, #200
	sub	x2, x29, #208
	bl	_p2p_freq_to_channel
	tbnz	x0, #63, LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=2
	ldr	x0, [x20]
	ldp	x2, x1, [x29, #-208]
	bl	_p2p_channels_includes
	cbnz	w0, LBB0_15
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=2
	cbnz	w22, LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=2
	ldr	x8, [x20]
	add	x0, x8, #4
	ldp	x2, x1, [x29, #-208]
	bl	_p2p_channels_includes
	cbnz	w0, LBB0_15
LBB0_13:                                ;   in Loop: Header=BB0_9 Depth=2
	ldr	w2, [x25]
	str	x22, [sp, #-16]!
	mov	x0, x20
	mov	x1, x24
	bl	_p2p_dbg
	add	sp, sp, #16
	ldur	w8, [x29, #-192]
	adds	w9, w8, w28
	b.eq	LBB0_8
; %bb.14:                               ;   in Loop: Header=BB0_9 Depth=2
	lsl	w2, w9, #2
	mov	x0, x25
	mov	x1, x26
	bl	_os_memmove
	ldur	w8, [x29, #-192]
	b	LBB0_8
LBB0_15:                                ;   in Loop: Header=BB0_7 Depth=1
	ldur	w8, [x29, #-192]
	ldur	x27, [x29, #-216]               ; 8-byte Folded Reload
	cmp	x27, x8
	b.lo	LBB0_7
; %bb.16:
                                        ; kill: def $w8 killed $w8 killed $x8 def $x8
LBB0_17:
	sub	x24, x29, #188
	cbz	w8, LBB0_22
; %bb.18:
	mov	x28, #0
	add	x25, x24, #100
	sub	x24, x29, #188
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	sub	w27, w25, w24
	ldr	w3, [x23, x28, lsl #2]
	mov	x0, x24
	mov	x1, x27
Lloh13:
	adrp	x2, l_.str.1@PAGE
Lloh14:
	add	x2, x2, l_.str.1@PAGEOFF
	bl	_os_snprintf
	mov	x26, x0
	mov	x0, x27
	mov	x1, x26
	bl	_os_snprintf_error
	cbnz	x0, LBB0_22
; %bb.20:                               ;   in Loop: Header=BB0_19 Depth=1
	add	x24, x24, w26, sxtw
	add	x28, x28, #1
	ldur	w8, [x29, #-192]
	cmp	x28, x8
	b.lo	LBB0_19
	b	LBB0_22
LBB0_21:
	sub	x24, x29, #188
LBB0_22:
	strb	wzr, [x24]
	ldur	w2, [x29, #-192]
	sub	x8, x29, #188
	str	x8, [sp, #-16]!
Lloh15:
	adrp	x1, l_.str.2@PAGE
Lloh16:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_p2p_dbg
	add	sp, sp, #16
	ldur	w8, [x29, #-192]
	cbz	w8, LBB0_26
; %bb.23:
	mov	x9, #0
	ldr	w10, [x21, #8]
LBB0_24:                                ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x23, x9, lsl #2]
	cmp	w11, w10
	b.eq	LBB0_27
; %bb.25:                               ;   in Loop: Header=BB0_24 Depth=1
	add	x9, x9, #1
	cmp	x8, x9
	b.ne	LBB0_24
	b	LBB0_29
LBB0_26:
	mov	w9, #0
LBB0_27:
	cmp	w9, w8
	b.eq	LBB0_29
; %bb.28:
	ldr	w0, [x23, w9, uxtw #2]
	sub	x1, x29, #200
	sub	x2, x29, #208
	bl	_p2p_freq_to_channel
	cbz	x0, LBB0_32
LBB0_29:
	ldr	w2, [x21, #8]
Lloh17:
	adrp	x1, l_.str.3@PAGE
Lloh18:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	bl	_p2p_dbg
	ldr	x8, [x19]
	ldur	w5, [x29, #-192]
	mov	x0, x20
	mov	x1, x22
	mov	x2, x21
	mov	x3, x19
	mov	x4, x23
	cbz	x8, LBB0_31
; %bb.30:
	bl	_p2p_check_pref_chan_recv
	b	LBB0_33
LBB0_31:
	bl	_p2p_check_pref_chan_no_recv
	b	LBB0_33
LBB0_32:
	ldp	x9, x8, [x29, #-208]
	stp	x9, x8, [x20, #16]
	add	x0, x20, #8
	ldr	x1, [x20]
	mov	w2, #4
	bl	_os_memcpy
LBB0_33:
	ldur	x8, [x29, #-88]
Lloh19:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh20:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_35
; %bb.34:
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_35:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_P2P_MAX_PREF_CHANNELS,4,2      ; @P2P_MAX_PREF_CHANNELS
	.comm	_P2P_DEV_FORCE_FREQ,4,2         ; @P2P_DEV_FORCE_FREQ
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Ignore local driver frequency preference %u MHz since it is not acceptable for P2P use (go=%d)"

l_.str.1:                               ; @.str.1
	.asciz	" %u"

l_.str.2:                               ; @.str.2
	.asciz	"Local driver frequency preference (size=%u):%s"

l_.str.3:                               ; @.str.3
	.asciz	"Peer operating channel preference: %d MHz is not in our preferred channel list"

.subsections_via_symbols
