	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lpphy_adjust_gain_table
_lpphy_adjust_gain_table:               ## @lpphy_adjust_gain_table
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	16(%rdi), %r15
	xorl	%edi, %edi
	cmpl	$2, 8(%rbx)
	setge	%dil
	callq	_B43_WARN_ON
	movl	(%rbx), %edi
	callq	_b43_current_band
	movq	_NL80211_BAND_2GHZ@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_5
## %bb.1:
	cmpl	$5320, %r14d                    ## imm = 0x14C8
	jg	LBB0_3
## %bb.2:
	addq	$4, %r15
	jmp	LBB0_5
LBB0_3:
	cmpl	$5700, %r14d                    ## imm = 0x1644
	jbe	LBB0_5
## %bb.4:
	addq	$8, %r15
LBB0_5:
	movl	(%r15), %eax
	addl	$-26, %eax
	cltq
	imulq	$715827883, %rax, %rax          ## imm = 0x2AAAAAAB
	movq	%rax, %rcx
	shrq	$63, %rcx
	shrq	$33, %rax
	addl	%ecx, %eax
	shll	$12, %eax
	movl	%eax, -44(%rbp)
	leal	4096(%rax), %ecx
	movl	%ecx, -40(%rbp)
	addl	$8192, %eax                     ## imm = 0x2000
	movl	%eax, -36(%rbp)
	movl	$13, %edi
	xorl	%esi, %esi
	callq	_B43_LPTAB16
	leaq	-44(%rbp), %r14
	movq	%rbx, %rdi
	movl	%eax, %esi
	movl	$3, %edx
	movq	%r14, %rcx
	callq	_b43_lptab_write_bulk
	movl	$12, %edi
	xorl	%esi, %esi
	callq	_B43_LPTAB16
	movq	%rbx, %rdi
	movl	%eax, %esi
	movl	$3, %edx
	movq	%r14, %rcx
	callq	_b43_lptab_write_bulk
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_7
## %bb.6:
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_NL80211_BAND_2GHZ,8,3          ## @NL80211_BAND_2GHZ
	.no_dead_strip	_lpphy_adjust_gain_table
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function lpphy_adjust_gain_table
lCPI0_0:
	.long	4096                            ; 0x1000
	.long	8192                            ; 0x2000
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_lpphy_adjust_gain_table:               ; @lpphy_adjust_gain_table
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	ldr	x21, [x0, #16]
	ldr	w8, [x0, #8]
	cmp	w8, #1
	cset	w0, gt
	bl	_B43_WARN_ON
	ldr	w0, [x19]
	bl	_b43_current_band
Lloh3:
	adrp	x8, _NL80211_BAND_2GHZ@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NL80211_BAND_2GHZ@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	mov	w9, #5320
	mov	w10, #5700
	cmp	w20, w10
	add	x10, x21, #8
	csel	x10, x10, x21, hi
	add	x11, x21, #4
	cmp	w20, w9
	csel	x9, x10, x11, gt
	cmp	x0, x8
	csel	x8, x9, x21, ne
	ldr	w8, [x8]
	sub	w8, w8, #26
	mov	w9, #43691
	movk	w9, #10922, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	lsr	x8, x8, #33
	add	w8, w8, w9
	lsl	w8, w8, #12
	str	w8, [sp, #12]
	dup.2s	v0, w8
Lloh6:
	adrp	x8, lCPI0_0@PAGE
Lloh7:
	ldr	d1, [x8, lCPI0_0@PAGEOFF]
	add.2s	v0, v0, v1
	stur	d0, [sp, #16]
	mov	w0, #13
	mov	w1, #0
	bl	_B43_LPTAB16
	mov	x1, x0
	add	x3, sp, #12
	mov	x0, x19
	mov	w2, #3
	bl	_b43_lptab_write_bulk
	mov	w0, #12
	mov	w1, #0
	bl	_B43_LPTAB16
	mov	x1, x0
	add	x3, sp, #12
	mov	x0, x19
	mov	w2, #3
	bl	_b43_lptab_write_bulk
	ldr	x8, [sp, #24]
Lloh8:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh9:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_2
; %bb.1:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_2:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdr	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_NL80211_BAND_2GHZ,8,3          ; @NL80211_BAND_2GHZ
	.no_dead_strip	_lpphy_adjust_gain_table
.subsections_via_symbols
