	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath5k_write_pwr_to_pdadc_table
_ath5k_write_pwr_to_pdadc_table:        ## @ath5k_write_pwr_to_pdadc_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	%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	(%rdi), %r12
	movq	8(%rdi), %rax
	movq	(%rax,%rsi,8), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	16(%rdi), %rax
	movq	(%rax,%rsi,8), %rbx
	movq	_AR5K_PHY_TPC_RG1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ath5k_hw_reg_read
	movq	_AR5K_PHY_TPC_RG1_PDGAIN_1@GOTPCREL(%rip), %rcx
	movq	_AR5K_PHY_TPC_RG1_PDGAIN_2@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r13d
	orl	(%rcx), %r13d
	movq	_AR5K_PHY_TPC_RG1_PDGAIN_3@GOTPCREL(%rip), %rcx
	orl	(%rcx), %r13d
	movq	_AR5K_PHY_TPC_RG1_NUM_PD_GAIN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	%esi, %r13d
	notl	%r13d
	andl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_AR5K_REG_SM
	movl	%eax, %r15d
	orl	%r13d, %r15d
	cmpq	$1, %rbx
	je	LBB0_1
## %bb.2:
	cmpq	$2, %rbx
	je	LBB0_3
## %bb.4:
	cmpq	$3, %rbx
	jne	LBB0_8
## %bb.5:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	16(%rbx), %rdi
	movq	_AR5K_PHY_TPC_RG1_PDGAIN_3@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_AR5K_REG_SM
	orl	%eax, %r15d
	jmp	LBB0_6
LBB0_1:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_7
LBB0_3:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_6:
	movq	8(%rbx), %rdi
	movq	_AR5K_PHY_TPC_RG1_PDGAIN_2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_AR5K_REG_SM
	orl	%eax, %r15d
LBB0_7:
	movq	(%rbx), %rdi
	movq	_AR5K_PHY_TPC_RG1_PDGAIN_1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_AR5K_REG_SM
	orl	%eax, %r15d
LBB0_8:
	movq	_AR5K_PHY_TPC_RG1@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_ath5k_hw_reg_write
	movq	_AR5K_EEPROM_POWER_TABLE_SIZE@GOTPCREL(%rip), %r13
	movl	(%r13), %eax
	incl	%eax
	cmpl	$3, %eax
	jb	LBB0_11
## %bb.9:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	callq	_get_unaligned_le32
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_AR5K_PHY_PDADC_TXPOWER
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_ath5k_hw_reg_write
	incq	%rbx
	movl	(%r13), %eax
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%eax, %ecx
	sarl	%ecx
	movslq	%ecx, %rax
	addq	$32, %r12
	cmpq	%rax, %rbx
	jb	LBB0_10
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AR5K_PHY_TPC_RG1,4,2           ## @AR5K_PHY_TPC_RG1
	.comm	_AR5K_PHY_TPC_RG1_PDGAIN_1,4,2  ## @AR5K_PHY_TPC_RG1_PDGAIN_1
	.comm	_AR5K_PHY_TPC_RG1_PDGAIN_2,4,2  ## @AR5K_PHY_TPC_RG1_PDGAIN_2
	.comm	_AR5K_PHY_TPC_RG1_PDGAIN_3,4,2  ## @AR5K_PHY_TPC_RG1_PDGAIN_3
	.comm	_AR5K_PHY_TPC_RG1_NUM_PD_GAIN,4,2 ## @AR5K_PHY_TPC_RG1_NUM_PD_GAIN
	.comm	_AR5K_EEPROM_POWER_TABLE_SIZE,4,2 ## @AR5K_EEPROM_POWER_TABLE_SIZE
	.no_dead_strip	_ath5k_write_pwr_to_pdadc_table
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath5k_write_pwr_to_pdadc_table
_ath5k_write_pwr_to_pdadc_table:        ; @ath5k_write_pwr_to_pdadc_table
	.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
	ldp	x20, x8, [x0]
	lsl	x9, x1, #3
	ldr	x24, [x8, x9]
	ldr	x8, [x0, #16]
	ldr	x22, [x8, x9]
Lloh0:
	adrp	x23, _AR5K_PHY_TPC_RG1@GOTPAGE
Lloh1:
	ldr	x23, [x23, _AR5K_PHY_TPC_RG1@GOTPAGEOFF]
	ldr	w1, [x23]
	bl	_ath5k_hw_reg_read
Lloh2:
	adrp	x25, _AR5K_PHY_TPC_RG1_PDGAIN_1@GOTPAGE
Lloh3:
	ldr	x25, [x25, _AR5K_PHY_TPC_RG1_PDGAIN_1@GOTPAGEOFF]
Lloh4:
	adrp	x26, _AR5K_PHY_TPC_RG1_PDGAIN_2@GOTPAGE
Lloh5:
	ldr	x26, [x26, _AR5K_PHY_TPC_RG1_PDGAIN_2@GOTPAGEOFF]
	ldr	w8, [x25]
	ldr	w9, [x26]
	orr	w8, w9, w8
Lloh6:
	adrp	x27, _AR5K_PHY_TPC_RG1_PDGAIN_3@GOTPAGE
Lloh7:
	ldr	x27, [x27, _AR5K_PHY_TPC_RG1_PDGAIN_3@GOTPAGEOFF]
	ldr	w9, [x27]
	orr	w8, w8, w9
Lloh8:
	adrp	x9, _AR5K_PHY_TPC_RG1_NUM_PD_GAIN@GOTPAGE
Lloh9:
	ldr	x9, [x9, _AR5K_PHY_TPC_RG1_NUM_PD_GAIN@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x9]
	orr	w8, w8, w1
	bic	w21, w0, w8
	mov	x0, x22
	bl	_AR5K_REG_SM
	orr	w21, w21, w0
	cmp	x22, #1
	b.eq	LBB0_5
; %bb.1:
	cmp	x22, #2
	b.eq	LBB0_4
; %bb.2:
	cmp	x22, #3
	b.ne	LBB0_6
; %bb.3:
	ldr	x0, [x24, #16]
	ldr	w1, [x27]
	bl	_AR5K_REG_SM
	orr	w21, w0, w21
LBB0_4:
	ldr	x0, [x24, #8]
	ldr	w1, [x26]
	bl	_AR5K_REG_SM
	orr	w21, w0, w21
LBB0_5:
	ldr	x0, [x24]
	ldr	w1, [x25]
	bl	_AR5K_REG_SM
	orr	w21, w0, w21
LBB0_6:
	ldr	w2, [x23]
	mov	x0, x19
	mov	x1, x21
	bl	_ath5k_hw_reg_write
Lloh11:
	adrp	x23, _AR5K_EEPROM_POWER_TABLE_SIZE@GOTPAGE
Lloh12:
	ldr	x23, [x23, _AR5K_EEPROM_POWER_TABLE_SIZE@GOTPAGEOFF]
	ldr	w8, [x23]
	add	w8, w8, #1
	cmp	w8, #3
	b.lo	LBB0_9
; %bb.7:
	mov	x21, #0
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_get_unaligned_le32
	mov	x22, x0
	mov	x0, x21
	bl	_AR5K_PHY_PDADC_TXPOWER
	mov	x2, x0
	mov	x0, x19
	mov	x1, x22
	bl	_ath5k_hw_reg_write
	add	x21, x21, #1
	ldr	w8, [x23]
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w8, w8, #1
	add	x20, x20, #32
	cmp	x21, w8, sxtw
	b.lo	LBB0_8
LBB0_9:
	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
	ret
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_AR5K_PHY_TPC_RG1,4,2           ; @AR5K_PHY_TPC_RG1
	.comm	_AR5K_PHY_TPC_RG1_PDGAIN_1,4,2  ; @AR5K_PHY_TPC_RG1_PDGAIN_1
	.comm	_AR5K_PHY_TPC_RG1_PDGAIN_2,4,2  ; @AR5K_PHY_TPC_RG1_PDGAIN_2
	.comm	_AR5K_PHY_TPC_RG1_PDGAIN_3,4,2  ; @AR5K_PHY_TPC_RG1_PDGAIN_3
	.comm	_AR5K_PHY_TPC_RG1_NUM_PD_GAIN,4,2 ; @AR5K_PHY_TPC_RG1_NUM_PD_GAIN
	.comm	_AR5K_EEPROM_POWER_TABLE_SIZE,4,2 ; @AR5K_EEPROM_POWER_TABLE_SIZE
	.no_dead_strip	_ath5k_write_pwr_to_pdadc_table
.subsections_via_symbols
