	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function b43legacy_op_add_interface
_b43legacy_op_add_interface:            ## @b43legacy_op_add_interface
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	callq	_hw_to_b43legacy_wl
	movq	%rax, %r15
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movl	4(%r12), %eax
	movq	_NL80211_IFTYPE_AP@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_4
## %bb.1:
	movq	_NL80211_IFTYPE_STATION@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_4
## %bb.2:
	movq	_NL80211_IFTYPE_WDS@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_4
## %bb.3:
	movq	_NL80211_IFTYPE_ADHOC@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_7
LBB0_4:
	leaq	4(%r15), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	cmpl	$0, (%r15)
	jne	LBB0_6
## %bb.5:
	movl	4(%r12), %edx
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	callq	_b43legacydbg
	movq	32(%r15), %r13
	movl	$1, (%r15)
	movq	%r12, 24(%r15)
	movl	4(%r12), %eax
	movl	%eax, 16(%r15)
	movl	12(%r15), %edi
	movl	(%r12), %esi
	movq	_ETH_ALEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_memcpy
	addq	$8, %r15
	movq	%r15, %rdi
	callq	_spin_lock_irqsave
	movq	%r13, %rdi
	callq	_b43legacy_adjust_opmode
	movq	%r13, %rdi
	callq	_b43legacy_set_pretbtt
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_b43legacy_set_synth_pu_delay
	movq	%r13, %rdi
	callq	_b43legacy_upload_card_macaddress
	movq	%r15, %rdi
	callq	_spin_unlock_irqrestore
LBB0_6:
	movq	%r14, %rdi
	callq	_mutex_unlock
LBB0_7:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_NL80211_IFTYPE_AP,4,2          ## @NL80211_IFTYPE_AP
	.comm	_NL80211_IFTYPE_STATION,4,2     ## @NL80211_IFTYPE_STATION
	.comm	_NL80211_IFTYPE_WDS,4,2         ## @NL80211_IFTYPE_WDS
	.comm	_NL80211_IFTYPE_ADHOC,4,2       ## @NL80211_IFTYPE_ADHOC
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Adding Interface type %d\n"

	.comm	_ETH_ALEN,4,2                   ## @ETH_ALEN
	.no_dead_strip	_b43legacy_op_add_interface
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function b43legacy_op_add_interface
_b43legacy_op_add_interface:            ; @b43legacy_op_add_interface
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	bl	_hw_to_b43legacy_wl
Lloh0:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w22, w8
	ldr	w8, [x21, #4]
Lloh3:
	adrp	x9, _NL80211_IFTYPE_AP@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NL80211_IFTYPE_AP@GOTPAGEOFF]
Lloh5:
	adrp	x10, _NL80211_IFTYPE_STATION@GOTPAGE
Lloh6:
	ldr	x10, [x10, _NL80211_IFTYPE_STATION@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
Lloh8:
	ldr	w10, [x10]
Lloh9:
	adrp	x11, _NL80211_IFTYPE_WDS@GOTPAGE
Lloh10:
	ldr	x11, [x11, _NL80211_IFTYPE_WDS@GOTPAGEOFF]
Lloh11:
	adrp	x12, _NL80211_IFTYPE_ADHOC@GOTPAGE
Lloh12:
	ldr	x12, [x12, _NL80211_IFTYPE_ADHOC@GOTPAGEOFF]
Lloh13:
	ldr	w11, [x11]
Lloh14:
	ldr	w12, [x12]
	cmp	w8, w9
	ccmp	w8, w10, #4, ne
	ccmp	w8, w11, #4, ne
	ccmp	w8, w12, #4, ne
	b.ne	LBB0_4
; %bb.1:
	mov	x20, x0
	add	x19, x0, #4
	mov	x0, x19
	bl	_mutex_lock
	ldr	w8, [x20]
	cbnz	w8, LBB0_3
; %bb.2:
	ldr	w2, [x21, #4]
Lloh15:
	adrp	x1, l_.str@PAGE
Lloh16:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_b43legacydbg
	ldr	x22, [x20, #32]
	mov	w8, #1
	str	w8, [x20]
	str	x21, [x20, #24]
	ldp	w1, w8, [x21]
	str	w8, [x20, #16]
	ldr	w0, [x20, #12]
Lloh17:
	adrp	x8, _ETH_ALEN@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ETH_ALEN@GOTPAGEOFF]
Lloh19:
	ldr	w2, [x8]
	bl	_memcpy
	add	x20, x20, #8
	mov	x0, x20
	bl	_spin_lock_irqsave
	mov	x0, x22
	bl	_b43legacy_adjust_opmode
	mov	x0, x22
	bl	_b43legacy_set_pretbtt
	mov	x0, x22
	mov	w1, #0
	bl	_b43legacy_set_synth_pu_delay
	mov	x0, x22
	bl	_b43legacy_upload_card_macaddress
	mov	x0, x20
	bl	_spin_unlock_irqrestore
	mov	w22, #0
LBB0_3:
	mov	x0, x19
	bl	_mutex_unlock
LBB0_4:
	mov	x0, x22
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh13
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_NL80211_IFTYPE_AP,4,2          ; @NL80211_IFTYPE_AP
	.comm	_NL80211_IFTYPE_STATION,4,2     ; @NL80211_IFTYPE_STATION
	.comm	_NL80211_IFTYPE_WDS,4,2         ; @NL80211_IFTYPE_WDS
	.comm	_NL80211_IFTYPE_ADHOC,4,2       ; @NL80211_IFTYPE_ADHOC
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Adding Interface type %d\n"

	.comm	_ETH_ALEN,4,2                   ; @ETH_ALEN
	.no_dead_strip	_b43legacy_op_add_interface
.subsections_via_symbols
