	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function alloc_libipw
LCPI0_0:
	.long	1                               ## 0x1
	.long	1                               ## 0x1
	.long	1                               ## 0x1
	.long	1                               ## 0x1
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_alloc_libipw
	.p2align	4, 0x90
_alloc_libipw:                          ## @alloc_libipw
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	movl	%edi, %ebx
	leaq	L_.str(%rip), %rdi
	callq	_LIBIPW_DEBUG_INFO
	addl	$104, %ebx
	movl	%ebx, %edi
	callq	_alloc_etherdev
	testq	%rax, %rax
	je	LBB0_9
## %bb.1:
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_netdev_priv
	movq	%rax, %rbx
	movq	%r14, 96(%rax)
	testl	%r15d, %r15d
	jne	LBB0_5
## %bb.2:
	movq	_libipw_config_ops@GOTPCREL(%rip), %rdi
	xorl	%esi, %esi
	callq	_wiphy_new
	movq	%rax, 24(%rbx)
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	leaq	24(%rbx), %rcx
	movq	96(%rbx), %rdx
	movq	%rcx, 8(%rdx)
	movq	_NL80211_IFTYPE_STATION@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%edx, 32(%rbx)
	movq	_libipw_wiphy_privid@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	movl	%edx, 16(%rax)
	movl	$1, (%rax)
	movq	$0, 8(%rax)
	movl	(%rcx), %edi
	callq	_BIT
	movl	%eax, %r12d
	movq	_NL80211_IFTYPE_ADHOC@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_BIT
	orl	%r12d, %eax
	movq	24(%rbx), %rcx
	movl	%eax, 4(%rcx)
LBB0_5:
	movq	%rbx, %rdi
	callq	_libipw_networks_allocate
	testl	%eax, %eax
	je	LBB0_11
## %bb.6:
	leaq	L_.str.2(%rip), %rdi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_LIBIPW_ERROR
	testl	%r15d, %r15d
	jne	LBB0_8
## %bb.7:
	movq	24(%rbx), %rdi
	callq	_wiphy_free
	jmp	LBB0_8
LBB0_11:
	movq	%rbx, %rdi
	callq	_libipw_networks_initialize
	movq	_DEFAULT_FTS@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 88(%rbx)
	movq	%rax, 80(%rbx)
	movq	_DEFAULT_MAX_SCAN_AGE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 72(%rbx)
	movaps	LCPI0_0(%rip), %xmm0            ## xmm0 = [1,1,1,1]
	movups	%xmm0, (%rbx)
	movabsq	$4294967297, %rax               ## imm = 0x100000001
	movq	%rax, 16(%rbx)
	leaq	64(%rbx), %r15
	movq	%r15, %rdi
	callq	_spin_lock_init
	movq	%rbx, %rdi
	addq	$68, %rdi
	movl	(%r14), %esi
	movq	%r15, %rdx
	callq	_lib80211_crypt_info_init
	xorps	%xmm0, %xmm0
	movups	%xmm0, 40(%rbx)
	movq	$0, 56(%rbx)
	jmp	LBB0_10
LBB0_3:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_LIBIPW_ERROR
LBB0_8:
	movq	%r14, %rdi
	callq	_free_netdev
LBB0_9:
	xorl	%r14d, %r14d
LBB0_10:
	movq	%r14, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Initializing...\n"

	.comm	_libipw_config_ops,4,2          ## @libipw_config_ops
L_.str.1:                               ## @.str.1
	.asciz	"Unable to allocate wiphy.\n"

	.comm	_NL80211_IFTYPE_STATION,4,2     ## @NL80211_IFTYPE_STATION
	.comm	_libipw_wiphy_privid,4,2        ## @libipw_wiphy_privid
	.comm	_NL80211_IFTYPE_ADHOC,4,2       ## @NL80211_IFTYPE_ADHOC
L_.str.2:                               ## @.str.2
	.asciz	"Unable to allocate beacon storage: %d\n"

	.comm	_DEFAULT_FTS,8,3                ## @DEFAULT_FTS
	.comm	_DEFAULT_MAX_SCAN_AGE,4,2       ## @DEFAULT_MAX_SCAN_AGE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_alloc_libipw                   ; -- Begin function alloc_libipw
	.p2align	2
_alloc_libipw:                          ; @alloc_libipw
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_LIBIPW_DEBUG_INFO
	add	w0, w19, #104
	bl	_alloc_etherdev
	mov	x19, x0
	cbz	x0, LBB0_10
; %bb.1:
	mov	x0, x19
	bl	_netdev_priv
	mov	x20, x0
	str	x19, [x0, #96]
	cbnz	w21, LBB0_4
; %bb.2:
Lloh2:
	adrp	x0, _libipw_config_ops@GOTPAGE
Lloh3:
	ldr	x0, [x0, _libipw_config_ops@GOTPAGEOFF]
	mov	w1, #0
	bl	_wiphy_new
	mov	x8, x20
	str	x0, [x8, #24]!
	cbz	x0, LBB0_8
; %bb.3:
	ldr	x9, [x20, #96]
	str	x8, [x9, #8]
Lloh4:
	adrp	x8, _NL80211_IFTYPE_STATION@GOTPAGE
Lloh5:
	ldr	x8, [x8, _NL80211_IFTYPE_STATION@GOTPAGEOFF]
	ldr	w9, [x8]
	str	w9, [x20, #32]
Lloh6:
	adrp	x9, _libipw_wiphy_privid@GOTPAGE
Lloh7:
	ldr	x9, [x9, _libipw_wiphy_privid@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	str	w9, [x0, #16]
	mov	w9, #1
	str	w9, [x0]
	str	xzr, [x0, #8]
	ldr	w0, [x8]
	bl	_BIT
	mov	x22, x0
Lloh9:
	adrp	x8, _NL80211_IFTYPE_ADHOC@GOTPAGE
Lloh10:
	ldr	x8, [x8, _NL80211_IFTYPE_ADHOC@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	bl	_BIT
	orr	w8, w0, w22
	ldr	x9, [x20, #24]
	str	w8, [x9, #4]
LBB0_4:
	mov	x0, x20
	bl	_libipw_networks_allocate
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_7
; %bb.5:
	str	x0, [sp]
Lloh12:
	adrp	x0, l_.str.2@PAGE
Lloh13:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_LIBIPW_ERROR
	cbnz	w21, LBB0_9
; %bb.6:
	ldr	x0, [x20, #24]
	bl	_wiphy_free
	b	LBB0_9
LBB0_7:
	mov	x0, x20
	bl	_libipw_networks_initialize
Lloh14:
	adrp	x8, _DEFAULT_FTS@GOTPAGE
Lloh15:
	ldr	x8, [x8, _DEFAULT_FTS@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	stp	x8, x8, [x20, #80]
Lloh17:
	adrp	x8, _DEFAULT_MAX_SCAN_AGE@GOTPAGE
Lloh18:
	ldr	x8, [x8, _DEFAULT_MAX_SCAN_AGE@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	str	w8, [x20, #72]
	movi.4s	v0, #1
	str	q0, [x20]
	movi.2s	v0, #1
	str	d0, [x20, #16]
	add	x21, x20, #64
	mov	x0, x21
	bl	_spin_lock_init
	add	x0, x20, #68
	ldr	w1, [x19]
	mov	x2, x21
	bl	_lib80211_crypt_info_init
	stp	xzr, xzr, [x20, #48]
	str	xzr, [x20, #40]
	b	LBB0_10
LBB0_8:
Lloh20:
	adrp	x0, l_.str.1@PAGE
Lloh21:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_LIBIPW_ERROR
LBB0_9:
	mov	x0, x19
	bl	_free_netdev
	mov	x19, #0
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
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Initializing...\n"

	.comm	_libipw_config_ops,4,2          ; @libipw_config_ops
l_.str.1:                               ; @.str.1
	.asciz	"Unable to allocate wiphy.\n"

	.comm	_NL80211_IFTYPE_STATION,4,2     ; @NL80211_IFTYPE_STATION
	.comm	_libipw_wiphy_privid,4,2        ; @libipw_wiphy_privid
	.comm	_NL80211_IFTYPE_ADHOC,4,2       ; @NL80211_IFTYPE_ADHOC
l_.str.2:                               ; @.str.2
	.asciz	"Unable to allocate beacon storage: %d\n"

	.comm	_DEFAULT_FTS,8,3                ; @DEFAULT_FTS
	.comm	_DEFAULT_MAX_SCAN_AGE,4,2       ; @DEFAULT_MAX_SCAN_AGE
.subsections_via_symbols
