	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_b43legacy_radio_set_txpower_bg ## -- Begin function b43legacy_radio_set_txpower_bg
	.p2align	4, 0x90
_b43legacy_radio_set_txpower_bg:        ## @b43legacy_radio_set_txpower_bg
	.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	%ecx, %r14d
	movl	%edx, %r15d
	movl	%esi, %r12d
	movq	%rdi, %rbx
	cmpl	$65535, %esi                    ## imm = 0xFFFF
	je	LBB0_1
## %bb.2:
	cmpl	$65535, %r15d                   ## imm = 0xFFFF
	je	LBB0_3
LBB0_4:
	cmpl	$65535, %r14d                   ## imm = 0xFFFF
	jne	LBB0_6
LBB0_5:
	movl	8(%rbx), %r14d
LBB0_6:
	movl	%r12d, (%rbx)
	movl	%r15d, 4(%rbx)
	movl	%r14d, 8(%rbx)
	xorl	%edi, %edi
	cmpl	$12, %r12d
	setge	%dil
	callq	_B43legacy_WARN_ON
	cmpl	$6, 12(%rbx)
	movl	$9, %eax
	movl	$31, %ecx
	cmovll	%eax, %ecx
	xorl	%edi, %edi
	cmpl	%ecx, %r15d
	setg	%dil
	callq	_B43legacy_WARN_ON
	xorl	%edi, %edi
	cmpl	$8, %r14d
	setge	%dil
	callq	_B43legacy_WARN_ON
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_b43legacy_phy_set_baseband_attenuation
	movq	%rbx, %rdi
	movl	$67, %esi
	movl	%r15d, %edx
	callq	_b43legacy_radio_write16
	movq	_B43legacy_SHM_SHARED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$100, %edx
	movl	%r15d, %ecx
	callq	_b43legacy_shm_write16
	cmpl	$8272, 16(%rbx)                 ## imm = 0x2050
	jne	LBB0_8
## %bb.7:
	movq	%rbx, %rdi
	movl	$82, %esi
	callq	_b43legacy_radio_read16
	andl	$-113, %eax
	shll	$4, %r14d
	andl	$112, %r14d
	orl	%eax, %r14d
	movq	%rbx, %rdi
	movl	$82, %esi
	movl	%r14d, %edx
	callq	_b43legacy_radio_write16
LBB0_8:
	movq	24(%rbx), %rax
	movq	_B43legacy_PHYTYPE_G@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.10:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_b43legacy_phy_lo_adjust        ## TAILCALL
LBB0_1:
	movl	(%rbx), %r12d
	cmpl	$65535, %r15d                   ## imm = 0xFFFF
	jne	LBB0_4
LBB0_3:
	movl	4(%rbx), %r15d
	cmpl	$65535, %r14d                   ## imm = 0xFFFF
	je	LBB0_5
	jmp	LBB0_6
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_B43legacy_SHM_SHARED,4,2       ## @B43legacy_SHM_SHARED
	.comm	_B43legacy_PHYTYPE_G,8,3        ## @B43legacy_PHYTYPE_G
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_b43legacy_radio_set_txpower_bg ; -- Begin function b43legacy_radio_set_txpower_bg
	.p2align	2
_b43legacy_radio_set_txpower_bg:        ; @b43legacy_radio_set_txpower_bg
	.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	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	mov	w8, #65535
	cmp	w1, w8
	b.ne	LBB0_2
; %bb.1:
	ldr	w22, [x19]
LBB0_2:
	cmp	w21, w8
	b.ne	LBB0_4
; %bb.3:
	ldr	w21, [x19, #4]
LBB0_4:
	mov	w8, #65535
	cmp	w20, w8
	b.ne	LBB0_6
; %bb.5:
	ldr	w20, [x19, #8]
LBB0_6:
	stp	w22, w21, [x19]
	str	w20, [x19, #8]
	cmp	w22, #11
	cset	w0, gt
	bl	_B43legacy_WARN_ON
	ldr	w8, [x19, #12]
	mov	w9, #31
	mov	w10, #9
	cmp	w8, #6
	csel	w8, w10, w9, lt
	cmp	w21, w8
	cset	w0, gt
	bl	_B43legacy_WARN_ON
	cmp	w20, #7
	cset	w0, gt
	bl	_B43legacy_WARN_ON
	mov	x0, x19
	mov	x1, x22
	bl	_b43legacy_phy_set_baseband_attenuation
	mov	x0, x19
	mov	w1, #67
	mov	x2, x21
	bl	_b43legacy_radio_write16
Lloh0:
	adrp	x8, _B43legacy_SHM_SHARED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _B43legacy_SHM_SHARED@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #100
	mov	x3, x21
	bl	_b43legacy_shm_write16
	ldr	w8, [x19, #16]
	mov	w9, #8272
	cmp	w8, w9
	b.ne	LBB0_8
; %bb.7:
	mov	x0, x19
	mov	w1, #82
	bl	_b43legacy_radio_read16
	mov	x2, x0
	bfi	w2, w20, #4, #3
	mov	x0, x19
	mov	w1, #82
	bl	_b43legacy_radio_write16
LBB0_8:
	ldr	x8, [x19, #24]
Lloh3:
	adrp	x9, _B43legacy_PHYTYPE_G@GOTPAGE
Lloh4:
	ldr	x9, [x9, _B43legacy_PHYTYPE_G@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.9:
	mov	x0, x19
	mov	w1, #0
	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
	b	_b43legacy_phy_lo_adjust
LBB0_10:
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_B43legacy_SHM_SHARED,4,2       ; @B43legacy_SHM_SHARED
	.comm	_B43legacy_PHYTYPE_G,8,3        ; @B43legacy_PHYTYPE_G
.subsections_via_symbols
