	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function b43legacy_adjust_opmode
_b43legacy_adjust_opmode:               ## @b43legacy_adjust_opmode
	.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	%rdi, %r14
	movq	8(%rdi), %r15
	movq	_B43legacy_MMIO_MACCTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_b43legacy_read32
	movq	_B43legacy_MACCTL_AP@GOTPCREL(%rip), %r13
	movq	_B43legacy_MACCTL_KEEP_CTL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%r13), %ebx
	movq	_B43legacy_MACCTL_KEEP_BADPLCP@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movq	_B43legacy_MACCTL_KEEP_BAD@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movq	_B43legacy_MACCTL_PROMISC@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movq	_B43legacy_MACCTL_BEACPROMISC@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	notl	%ebx
	andl	%eax, %ebx
	movq	_B43legacy_MACCTL_INFRA@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_NL80211_IFTYPE_AP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_b43legacy_is_mode
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	%r13, %r12
	orl	(%r13), %ebx
LBB0_3:
	movq	_B43legacy_MMIO_MACCTL@GOTPCREL(%rip), %rdi
	movq	_B43legacy_MACCTL_INFRA@GOTPCREL(%rip), %r13
	jmp	LBB0_5
LBB0_2:
	movq	%r13, %r12
	movq	_NL80211_IFTYPE_ADHOC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_b43legacy_is_mode
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	_B43legacy_MACCTL_INFRA@GOTPCREL(%rip), %r13
	movl	(%r13), %eax
	notl	%eax
	andl	%eax, %ebx
	movq	_B43legacy_MMIO_MACCTL@GOTPCREL(%rip), %rdi
LBB0_5:
	movl	(%r15), %ecx
	movq	_FIF_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	%ecx, %eax
	je	LBB0_7
## %bb.6:
	movq	_B43legacy_MACCTL_KEEP_CTL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_7:
	movq	_FIF_FCSFAIL@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	andl	%ecx, %edx
	je	LBB0_9
## %bb.8:
	movq	_B43legacy_MACCTL_KEEP_BAD@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
LBB0_9:
	movq	_FIF_PLCPFAIL@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
	andl	%ecx, %esi
	je	LBB0_11
## %bb.10:
	movq	_B43legacy_MACCTL_KEEP_BADPLCP@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
LBB0_11:
	orl	%esi, %eax
	movq	_FIF_BCN_PRBRESP_PROMISC@GOTPCREL(%rip), %rsi
	andl	(%rsi), %ecx
	je	LBB0_13
## %bb.12:
	movq	_B43legacy_MACCTL_BEACPROMISC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_13:
	orl	%ecx, %eax
	orl	%edx, %ebx
	movq	(%r14), %rdx
	xorl	%ecx, %ecx
	cmpl	$5, 8(%rdx)
	jge	LBB0_15
## %bb.14:
	movq	_B43legacy_MACCTL_PROMISC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_15:
	orl	%ecx, %eax
	orl	%eax, %ebx
	movl	(%rdi), %esi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_b43legacy_write32
	movl	$2, %edx
	testl	%ebx, (%r13)
	je	LBB0_20
## %bb.16:
	testl	%ebx, (%r12)
	jne	LBB0_20
## %bb.17:
	movq	(%r14), %rax
	movq	(%rax), %rax
	cmpl	$17158, (%rax)                  ## imm = 0x4306
	jne	LBB0_19
## %bb.18:
	movl	$100, %edx
	cmpl	$3, 4(%rax)
	je	LBB0_20
LBB0_19:
	movl	$50, %edx
LBB0_20:
	movq	%r14, %rdi
	movl	$1554, %esi                     ## imm = 0x612
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_b43legacy_write16              ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_B43legacy_MMIO_MACCTL,4,2      ## @B43legacy_MMIO_MACCTL
	.comm	_B43legacy_MACCTL_AP,4,2        ## @B43legacy_MACCTL_AP
	.comm	_B43legacy_MACCTL_KEEP_CTL,4,2  ## @B43legacy_MACCTL_KEEP_CTL
	.comm	_B43legacy_MACCTL_KEEP_BADPLCP,4,2 ## @B43legacy_MACCTL_KEEP_BADPLCP
	.comm	_B43legacy_MACCTL_KEEP_BAD,4,2  ## @B43legacy_MACCTL_KEEP_BAD
	.comm	_B43legacy_MACCTL_PROMISC,4,2   ## @B43legacy_MACCTL_PROMISC
	.comm	_B43legacy_MACCTL_BEACPROMISC,4,2 ## @B43legacy_MACCTL_BEACPROMISC
	.comm	_B43legacy_MACCTL_INFRA,4,2     ## @B43legacy_MACCTL_INFRA
	.comm	_NL80211_IFTYPE_AP,4,2          ## @NL80211_IFTYPE_AP
	.comm	_NL80211_IFTYPE_ADHOC,4,2       ## @NL80211_IFTYPE_ADHOC
	.comm	_FIF_CONTROL,4,2                ## @FIF_CONTROL
	.comm	_FIF_FCSFAIL,4,2                ## @FIF_FCSFAIL
	.comm	_FIF_PLCPFAIL,4,2               ## @FIF_PLCPFAIL
	.comm	_FIF_BCN_PRBRESP_PROMISC,4,2    ## @FIF_BCN_PRBRESP_PROMISC
	.no_dead_strip	_b43legacy_adjust_opmode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function b43legacy_adjust_opmode
_b43legacy_adjust_opmode:               ; @b43legacy_adjust_opmode
	.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
	mov	x19, x0
	ldr	x20, [x0, #8]
Lloh0:
	adrp	x8, _B43legacy_MMIO_MACCTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _B43legacy_MMIO_MACCTL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_b43legacy_read32
Lloh3:
	adrp	x21, _B43legacy_MACCTL_AP@GOTPAGE
Lloh4:
	ldr	x21, [x21, _B43legacy_MACCTL_AP@GOTPAGEOFF]
	ldr	w8, [x21]
Lloh5:
	adrp	x28, _B43legacy_MACCTL_KEEP_CTL@GOTPAGE
Lloh6:
	ldr	x28, [x28, _B43legacy_MACCTL_KEEP_CTL@GOTPAGEOFF]
	ldr	w9, [x28]
	orr	w8, w9, w8
Lloh7:
	adrp	x25, _B43legacy_MACCTL_KEEP_BADPLCP@GOTPAGE
Lloh8:
	ldr	x25, [x25, _B43legacy_MACCTL_KEEP_BADPLCP@GOTPAGEOFF]
	ldr	w9, [x25]
	orr	w8, w8, w9
Lloh9:
	adrp	x27, _B43legacy_MACCTL_KEEP_BAD@GOTPAGE
Lloh10:
	ldr	x27, [x27, _B43legacy_MACCTL_KEEP_BAD@GOTPAGEOFF]
	ldr	w9, [x27]
	orr	w8, w8, w9
Lloh11:
	adrp	x24, _B43legacy_MACCTL_PROMISC@GOTPAGE
Lloh12:
	ldr	x24, [x24, _B43legacy_MACCTL_PROMISC@GOTPAGEOFF]
	ldr	w9, [x24]
	orr	w8, w8, w9
Lloh13:
	adrp	x26, _B43legacy_MACCTL_BEACPROMISC@GOTPAGE
Lloh14:
	ldr	x26, [x26, _B43legacy_MACCTL_BEACPROMISC@GOTPAGEOFF]
	ldr	w9, [x26]
	orr	w8, w8, w9
Lloh15:
	adrp	x23, _B43legacy_MACCTL_INFRA@GOTPAGE
Lloh16:
	ldr	x23, [x23, _B43legacy_MACCTL_INFRA@GOTPAGEOFF]
	bic	w8, w0, w8
	ldr	w9, [x23]
	orr	w22, w8, w9
Lloh17:
	adrp	x8, _NL80211_IFTYPE_AP@GOTPAGE
Lloh18:
	ldr	x8, [x8, _NL80211_IFTYPE_AP@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_b43legacy_is_mode
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w8, [x21]
	orr	w22, w8, w22
	b	LBB0_4
LBB0_2:
Lloh20:
	adrp	x8, _NL80211_IFTYPE_ADHOC@GOTPAGE
Lloh21:
	ldr	x8, [x8, _NL80211_IFTYPE_ADHOC@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_b43legacy_is_mode
	cbz	x0, LBB0_4
; %bb.3:
	ldr	w8, [x23]
	bic	w22, w22, w8
LBB0_4:
Lloh23:
	adrp	x12, _B43legacy_MMIO_MACCTL@GOTPAGE
Lloh24:
	ldr	x12, [x12, _B43legacy_MMIO_MACCTL@GOTPAGEOFF]
	ldr	w8, [x20]
Lloh25:
	adrp	x9, _FIF_CONTROL@GOTPAGE
Lloh26:
	ldr	x9, [x9, _FIF_CONTROL@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
	ldr	w10, [x28]
	tst	w9, w8
	csel	w9, wzr, w10, eq
	orr	w9, w9, w22
Lloh28:
	adrp	x10, _FIF_FCSFAIL@GOTPAGE
Lloh29:
	ldr	x10, [x10, _FIF_FCSFAIL@GOTPAGEOFF]
Lloh30:
	ldr	w10, [x10]
	ldr	w11, [x27]
	tst	w10, w8
	csel	w10, wzr, w11, eq
	orr	w9, w9, w10
Lloh31:
	adrp	x10, _FIF_PLCPFAIL@GOTPAGE
Lloh32:
	ldr	x10, [x10, _FIF_PLCPFAIL@GOTPAGEOFF]
Lloh33:
	ldr	w10, [x10]
	ldr	w11, [x25]
	tst	w10, w8
	csel	w10, wzr, w11, eq
	orr	w9, w9, w10
Lloh34:
	adrp	x10, _FIF_BCN_PRBRESP_PROMISC@GOTPAGE
Lloh35:
	ldr	x10, [x10, _FIF_BCN_PRBRESP_PROMISC@GOTPAGEOFF]
Lloh36:
	ldr	w10, [x10]
	ldr	w11, [x26]
	tst	w10, w8
	csel	w8, wzr, w11, eq
	orr	w8, w9, w8
	ldr	x9, [x19]
	ldr	w9, [x9, #8]
	ldr	w10, [x24]
	cmp	w9, #5
	csel	w9, w10, wzr, lt
	orr	w20, w8, w9
Lloh37:
	ldr	w1, [x12]
	mov	x0, x19
	mov	x2, x20
	bl	_b43legacy_write32
	ldr	w8, [x23]
	tst	w8, w20
	b.eq	LBB0_6
; %bb.5:
	ldr	w8, [x21]
	tst	w8, w20
	b.eq	LBB0_8
LBB0_6:
	mov	w2, #2
LBB0_7:
	mov	x0, x19
	mov	w1, #1554
	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
	b	_b43legacy_write16
LBB0_8:
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	w9, [x8]
	mov	w10, #17158
	cmp	w9, w10
	b.ne	LBB0_11
; %bb.9:
	ldr	w8, [x8, #4]
	cmp	w8, #3
	b.ne	LBB0_11
; %bb.10:
	mov	w2, #100
	b	LBB0_7
LBB0_11:
	mov	w2, #50
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_B43legacy_MMIO_MACCTL,4,2      ; @B43legacy_MMIO_MACCTL
	.comm	_B43legacy_MACCTL_AP,4,2        ; @B43legacy_MACCTL_AP
	.comm	_B43legacy_MACCTL_KEEP_CTL,4,2  ; @B43legacy_MACCTL_KEEP_CTL
	.comm	_B43legacy_MACCTL_KEEP_BADPLCP,4,2 ; @B43legacy_MACCTL_KEEP_BADPLCP
	.comm	_B43legacy_MACCTL_KEEP_BAD,4,2  ; @B43legacy_MACCTL_KEEP_BAD
	.comm	_B43legacy_MACCTL_PROMISC,4,2   ; @B43legacy_MACCTL_PROMISC
	.comm	_B43legacy_MACCTL_BEACPROMISC,4,2 ; @B43legacy_MACCTL_BEACPROMISC
	.comm	_B43legacy_MACCTL_INFRA,4,2     ; @B43legacy_MACCTL_INFRA
	.comm	_NL80211_IFTYPE_AP,4,2          ; @NL80211_IFTYPE_AP
	.comm	_NL80211_IFTYPE_ADHOC,4,2       ; @NL80211_IFTYPE_ADHOC
	.comm	_FIF_CONTROL,4,2                ; @FIF_CONTROL
	.comm	_FIF_FCSFAIL,4,2                ; @FIF_FCSFAIL
	.comm	_FIF_PLCPFAIL,4,2               ; @FIF_PLCPFAIL
	.comm	_FIF_BCN_PRBRESP_PROMISC,4,2    ; @FIF_BCN_PRBRESP_PROMISC
	.no_dead_strip	_b43legacy_adjust_opmode
.subsections_via_symbols
