	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wlan_get_channel_list          ## -- Begin function wlan_get_channel_list
	.p2align	4, 0x90
_wlan_get_channel_list:                 ## @wlan_get_channel_list
	.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	%rdi, %r13
	movl	$0, -44(%rbp)
	movq	_WLAN_SNMP_MAX_CHANS@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	leaq	24(,%rax,4), %rdi
	movq	%rdi, -56(%rbp)
	callq	_malloc
	movl	$-1, %r15d
	testq	%rax, %rax
	je	LBB0_17
## %bb.1:
	movq	%rax, %r12
	movl	16(%r13), %edi
	movq	_IEEE80211_IOC_CHANINFO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdx
	leaq	-56(%rbp), %r8
	movq	%r12, %rcx
	xorl	%r9d, %r9d
	callq	_wlan_ioctl
	testq	%rax, %rax
	js	LBB0_17
## %bb.2:
	movq	$24, -56(%rbp)
	movl	16(%r13), %edi
	movq	_IEEE80211_IOC_CHANLIST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdx
	leaq	-88(%rbp), %rcx
	leaq	-56(%rbp), %r8
	xorl	%r9d, %r9d
	callq	_wlan_ioctl
	testq	%rax, %rax
	js	LBB0_13
## %bb.3:
	cmpq	$0, (%r12)
	je	LBB0_6
## %bb.4:
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	16(%r12), %rax
	movl	-80(%rbp), %edi
	movl	(%rax,%rbx,4), %esi
	callq	_isset
	cmpl	$1, %eax
	sbbq	$-1, %r14
	incq	%rbx
	cmpq	(%r12), %rbx
	jb	LBB0_5
	jmp	LBB0_7
LBB0_6:
	xorl	%r14d, %r14d
LBB0_7:
	movq	8(%r13), %rdi
	leaq	(,%r14,4), %rsi
	callq	_reallocf
	movq	%rax, 8(%r13)
	testq	%rax, %rax
	je	LBB0_13
## %bb.8:
	movq	%r14, (%r13)
	cmpq	$0, (%r12)
	je	LBB0_15
## %bb.9:
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_11 Depth=1
	incq	%r14
	addq	$4, %rbx
	cmpq	(%r12), %r14
	jae	LBB0_15
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	16(%r12), %r15
	movl	-80(%rbp), %edi
	movl	(%r15,%rbx), %esi
	callq	_isset
	testl	%eax, %eax
	je	LBB0_10
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	addq	%rbx, %r15
	leaq	(,%r13,4), %rdi
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	addq	8(%rax), %rdi
	movq	%r15, %rsi
	movl	$4, %edx
	callq	_memcpy
	incq	%r13
	jmp	LBB0_10
LBB0_13:
	movq	$0, (%r13)
	movl	$-1, %r15d
	jmp	LBB0_16
LBB0_15:
	xorl	%r15d, %r15d
LBB0_16:
	movq	%r12, %rdi
	callq	_free
LBB0_17:
	movl	%r15d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_WLAN_SNMP_MAX_CHANS,4,2        ## @WLAN_SNMP_MAX_CHANS
	.comm	_IEEE80211_IOC_CHANINFO,4,2     ## @IEEE80211_IOC_CHANINFO
	.comm	_IEEE80211_IOC_CHANLIST,4,2     ## @IEEE80211_IOC_CHANLIST
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wlan_get_channel_list          ; -- Begin function wlan_get_channel_list
	.p2align	2
_wlan_get_channel_list:                 ; @wlan_get_channel_list
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x20, x0
	str	wzr, [sp, #44]
Lloh0:
	adrp	x8, _WLAN_SNMP_MAX_CHANS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WLAN_SNMP_MAX_CHANS@GOTPAGEOFF]
Lloh2:
	ldrsw	x8, [x8]
	lsl	x8, x8, #2
	add	x0, x8, #24
	str	x0, [sp, #32]
	bl	_malloc
	cbz	x0, LBB0_6
; %bb.1:
	mov	x19, x0
	ldr	w0, [x20, #16]
Lloh3:
	adrp	x8, _IEEE80211_IOC_CHANINFO@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IEEE80211_IOC_CHANINFO@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #44
	add	x4, sp, #32
	mov	x3, x19
	mov	w5, #0
	bl	_wlan_ioctl
	tbnz	x0, #63, LBB0_6
; %bb.2:
	mov	w8, #24
	str	x8, [sp, #32]
	ldr	w0, [x20, #16]
Lloh6:
	adrp	x8, _IEEE80211_IOC_CHANLIST@GOTPAGE
Lloh7:
	ldr	x8, [x8, _IEEE80211_IOC_CHANLIST@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	add	x2, sp, #44
	add	x3, sp, #8
	add	x4, sp, #32
	mov	w5, #0
	bl	_wlan_ioctl
	tbnz	x0, #63, LBB0_14
; %bb.3:
	ldr	x8, [x19]
	cbz	x8, LBB0_7
; %bb.4:
	mov	x21, #0
	mov	x22, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #16]
	ldr	w0, [sp, #16]
	ldr	w1, [x8, x22, lsl #2]
	bl	_isset
	cmp	w0, #0
	cinc	x21, x21, ne
	add	x22, x22, #1
	ldr	x8, [x19]
	cmp	x22, x8
	b.lo	LBB0_5
	b	LBB0_8
LBB0_6:
	mov	w20, #-1
	b	LBB0_17
LBB0_7:
	mov	x21, #0
LBB0_8:
	ldr	x0, [x20, #8]
	lsl	x1, x21, #2
	bl	_reallocf
	str	x0, [x20, #8]
	cbz	x0, LBB0_14
; %bb.9:
	str	x21, [x20]
	ldr	x8, [x19]
	cbz	x8, LBB0_15
; %bb.10:
	mov	x22, #0
	mov	x23, #0
	mov	x24, #0
	b	LBB0_12
LBB0_11:                                ;   in Loop: Header=BB0_12 Depth=1
	add	x24, x24, #1
	ldr	x8, [x19]
	add	x22, x22, #4
	cmp	x24, x8
	b.hs	LBB0_15
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #16]
	add	x21, x8, x22
	ldr	w0, [sp, #16]
	ldr	w1, [x21]
	bl	_isset
	cbz	w0, LBB0_11
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=1
	ldr	x8, [x20, #8]
	add	x0, x8, x23, lsl #2
	mov	x1, x21
	mov	w2, #4
	bl	_memcpy
	add	x23, x23, #1
	b	LBB0_11
LBB0_14:
	str	xzr, [x20]
	mov	w20, #-1
	b	LBB0_16
LBB0_15:
	mov	w20, #0
LBB0_16:
	mov	x0, x19
	bl	_free
LBB0_17:
	mov	x0, x20
	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
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_WLAN_SNMP_MAX_CHANS,4,2        ; @WLAN_SNMP_MAX_CHANS
	.comm	_IEEE80211_IOC_CHANINFO,4,2     ; @IEEE80211_IOC_CHANINFO
	.comm	_IEEE80211_IOC_CHANLIST,4,2     ; @IEEE80211_IOC_CHANLIST
.subsections_via_symbols
