	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function b43_radio_2057_rccal
_b43_radio_2057_rccal:                  ## @b43_radio_2057_rccal
	.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, %r15
	movl	4(%rdi), %eax
	cmpl	$6, %eax
	ja	LBB0_3
## %bb.1:
	movl	$88, %ecx
	btl	%eax, %ecx
	jae	LBB0_3
## %bb.2:
	movb	$1, %r12b
	movl	$192, %r14d
	movq	_R2057_RCCAL_MASTER@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_3:
	movl	$233, %r14d
	movq	_R2057v7_RCCAL_MASTER@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
LBB0_4:
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$97, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_TRC0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_X1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$110, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_START_R1_Q1_P1@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%r15, %rdi
	movl	$85, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_DONE_OSCCAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$2, %edx
	movl	$2, %ecx
	movl	$500, %r8d                      ## imm = 0x1F4
	movl	$5000000, %r9d                  ## imm = 0x4C4B40
	callq	_b43_radio_wait_value
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	callq	_b43dbg
LBB0_6:
	movl	$35, %edi
	movl	$70, %esi
	callq	_usleep_range
	movl	(%r14), %esi
	movq	%r15, %rdi
	movl	$21, %edx
	callq	_b43_radio_write
	movl	$70, %edi
	movl	$140, %esi
	callq	_usleep_range
	testb	%r12b, %r12b
	movl	$176, %eax
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	movl	$213, %ebx
	cmovnel	%eax, %ebx
	movq	%r14, %r12
	movq	_R2057v7_RCCAL_MASTER@GOTPCREL(%rip), %r13
	movq	_R2057_RCCAL_MASTER@GOTPCREL(%rip), %rax
	cmoveq	%r13, %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$105, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_TRC0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_X1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$110, %r14d
	movq	%r15, %rdi
	movl	$110, %edx
	callq	_b43_radio_write
	movl	$35, %edi
	movl	$70, %esi
	callq	_usleep_range
	movl	(%r12), %esi
	movq	%r15, %rdi
	movl	$85, %edx
	callq	_b43_radio_write
	movl	$70, %edi
	movl	$140, %esi
	callq	_usleep_range
	movq	_R2057_RCCAL_DONE_OSCCAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$2, %edx
	movl	$2, %ecx
	movl	$500, %r8d                      ## imm = 0x1F4
	movl	$5000000, %r9d                  ## imm = 0x4C4B40
	callq	_b43_radio_wait_value
	testl	%eax, %eax
	jne	LBB0_8
## %bb.7:
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	callq	_b43dbg
LBB0_8:
	movl	$35, %edi
	movl	$70, %esi
	callq	_usleep_range
	movl	(%r12), %esi
	movq	%r15, %rdi
	movl	$21, %edx
	callq	_b43_radio_write
	movl	$70, %edi
	movl	$140, %esi
	callq	_usleep_range
	cmpb	$0, -44(%rbp)                   ## 1-byte Folded Reload
	movl	$40, %eax
	cmovnel	%eax, %r14d
	movl	$153, %ebx
	movl	$176, %eax
	cmovnel	%eax, %ebx
	movq	_R2057_RCCAL_MASTER@GOTPCREL(%rip), %rax
	cmoveq	%r13, %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$115, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_X1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_b43_radio_write
	movq	_R2057_RCCAL_TRC0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_b43_radio_write
	movl	$35, %edi
	movl	$70, %esi
	callq	_usleep_range
	movl	(%r12), %esi
	movq	%r15, %rdi
	movl	$85, %edx
	callq	_b43_radio_write
	movl	$70, %edi
	movl	$140, %esi
	callq	_usleep_range
	movq	_R2057_RCCAL_DONE_OSCCAP@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r15, %rdi
	movl	$2, %edx
	movl	$2, %ecx
	movl	$500, %r8d                      ## imm = 0x1F4
	movl	$5000000, %r9d                  ## imm = 0x4C4B40
	callq	_b43_radio_wait_value
	testl	%eax, %eax
	je	LBB0_9
## %bb.10:
	movl	(%rbx), %esi
	movq	%r15, %rdi
	callq	_b43_radio_read
	movl	%eax, %r14d
	movl	$35, %edi
	movl	$70, %esi
	callq	_usleep_range
	movl	(%r12), %esi
	movq	%r15, %rdi
	movl	$21, %edx
	callq	_b43_radio_write
	movl	$70, %edi
	movl	$140, %esi
	callq	_usleep_range
	cmpb	$0, -44(%rbp)                   ## 1-byte Folded Reload
	je	LBB0_12
## %bb.11:
	movq	_R2057_RCCAL_MASTER@GOTPCREL(%rip), %rax
	jmp	LBB0_13
LBB0_9:
	movl	(%r15), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_b43err
	xorl	%r14d, %r14d
	jmp	LBB0_14
LBB0_12:
	movq	_R2057v7_RCCAL_MASTER@GOTPCREL(%rip), %rax
LBB0_13:
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$-2, %edx
	callq	_b43_radio_mask
LBB0_14:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_R2057_RCCAL_MASTER,4,2         ## @R2057_RCCAL_MASTER
	.comm	_R2057_RCCAL_TRC0,4,2           ## @R2057_RCCAL_TRC0
	.comm	_R2057v7_RCCAL_MASTER,4,2       ## @R2057v7_RCCAL_MASTER
	.comm	_R2057_RCCAL_X1,4,2             ## @R2057_RCCAL_X1
	.comm	_R2057_RCCAL_START_R1_Q1_P1,4,2 ## @R2057_RCCAL_START_R1_Q1_P1
	.comm	_R2057_RCCAL_DONE_OSCCAP,4,2    ## @R2057_RCCAL_DONE_OSCCAP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Radio 0x2057 rccal timeout\n"

L_.str.1:                               ## @.str.1
	.asciz	"Radio 0x2057 rcal timeout\n"

	.no_dead_strip	_b43_radio_2057_rccal
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function b43_radio_2057_rccal
_b43_radio_2057_rccal:                  ; @b43_radio_2057_rccal
	.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	w8, [x0, #4]
Lloh0:
	adrp	x22, _R2057_RCCAL_MASTER@GOTPAGE
Lloh1:
	ldr	x22, [x22, _R2057_RCCAL_MASTER@GOTPAGEOFF]
	mov	w23, #1
	cmp	w8, #6
	lsl	w8, w23, w8
	mov	w9, #88
	and	w8, w8, w9
	ccmp	w8, #0, #4, ls
	b.eq	LBB0_2
; %bb.1:
	mov	w20, #192
	mov	x8, x22
	b	LBB0_3
LBB0_2:
	mov	w23, #0
	mov	w20, #233
Lloh2:
	adrp	x8, _R2057v7_RCCAL_MASTER@GOTPAGE
Lloh3:
	ldr	x8, [x8, _R2057v7_RCCAL_MASTER@GOTPAGEOFF]
LBB0_3:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #97
	bl	_b43_radio_write
Lloh4:
	adrp	x26, _R2057_RCCAL_TRC0@GOTPAGE
Lloh5:
	ldr	x26, [x26, _R2057_RCCAL_TRC0@GOTPAGEOFF]
	ldr	w1, [x26]
	mov	x0, x19
	mov	x2, x20
	bl	_b43_radio_write
Lloh6:
	adrp	x28, _R2057_RCCAL_X1@GOTPAGE
Lloh7:
	ldr	x28, [x28, _R2057_RCCAL_X1@GOTPAGEOFF]
	ldr	w1, [x28]
	mov	x0, x19
	mov	w2, #110
	bl	_b43_radio_write
Lloh8:
	adrp	x24, _R2057_RCCAL_START_R1_Q1_P1@GOTPAGE
Lloh9:
	ldr	x24, [x24, _R2057_RCCAL_START_R1_Q1_P1@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #85
	bl	_b43_radio_write
Lloh10:
	adrp	x25, _R2057_RCCAL_DONE_OSCCAP@GOTPAGE
Lloh11:
	ldr	x25, [x25, _R2057_RCCAL_DONE_OSCCAP@GOTPAGEOFF]
	ldr	w1, [x25]
	mov	x0, x19
	mov	w2, #2
	mov	w3, #2
	mov	w4, #500
	mov	w5, #19264
	movk	w5, #76, lsl #16
	bl	_b43_radio_wait_value
	cbnz	w0, LBB0_5
; %bb.4:
	ldr	w0, [x19]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_b43dbg
LBB0_5:
	mov	w0, #35
	mov	w1, #70
	bl	_usleep_range
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #21
	bl	_b43_radio_write
	mov	w0, #70
	mov	w1, #140
	bl	_usleep_range
	mov	w8, #213
	mov	w21, #176
	cmp	w23, #0
	csel	w20, w21, w8, ne
Lloh14:
	adrp	x27, _R2057v7_RCCAL_MASTER@GOTPAGE
Lloh15:
	ldr	x27, [x27, _R2057v7_RCCAL_MASTER@GOTPAGEOFF]
	csel	x8, x22, x27, ne
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #105
	bl	_b43_radio_write
	ldr	w1, [x26]
	mov	x0, x19
	mov	x2, x20
	bl	_b43_radio_write
	ldr	w1, [x28]
	mov	w20, #110
	mov	x0, x19
	mov	w2, #110
	bl	_b43_radio_write
	mov	w0, #35
	mov	w1, #70
	bl	_usleep_range
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #85
	bl	_b43_radio_write
	mov	w0, #70
	mov	w1, #140
	bl	_usleep_range
	ldr	w1, [x25]
	mov	x0, x19
	mov	w2, #2
	mov	w3, #2
	mov	w4, #500
	mov	w5, #19264
	movk	w5, #76, lsl #16
	bl	_b43_radio_wait_value
	cbnz	w0, LBB0_7
; %bb.6:
	ldr	w0, [x19]
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	bl	_b43dbg
LBB0_7:
	mov	w0, #35
	mov	w1, #70
	bl	_usleep_range
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #21
	bl	_b43_radio_write
	mov	w0, #70
	mov	w1, #140
	bl	_usleep_range
	mov	w8, #40
	cmp	w23, #0
	csel	w20, w8, w20, ne
	mov	w8, #153
	csel	w21, w21, w8, ne
	csel	x8, x22, x27, ne
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #115
	bl	_b43_radio_write
	ldr	w1, [x28]
	mov	x0, x19
	mov	x2, x20
	bl	_b43_radio_write
	ldr	w1, [x26]
	mov	x0, x19
	mov	x2, x21
	bl	_b43_radio_write
	mov	w0, #35
	mov	w1, #70
	bl	_usleep_range
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #85
	bl	_b43_radio_write
	mov	w0, #70
	mov	w1, #140
	bl	_usleep_range
	ldr	w1, [x25]
	mov	x0, x19
	mov	w2, #2
	mov	w3, #2
	mov	w4, #500
	mov	w5, #19264
	movk	w5, #76, lsl #16
	bl	_b43_radio_wait_value
	cbz	w0, LBB0_10
; %bb.8:
	ldr	w1, [x25]
	mov	x0, x19
	bl	_b43_radio_read
	mov	x20, x0
	mov	w0, #35
	mov	w1, #70
	bl	_usleep_range
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #21
	bl	_b43_radio_write
	mov	w0, #70
	mov	w1, #140
	bl	_usleep_range
	cbz	w23, LBB0_11
; %bb.9:
	ldr	w1, [x22]
	b	LBB0_12
LBB0_10:
	ldr	w0, [x19]
Lloh18:
	adrp	x1, l_.str.1@PAGE
Lloh19:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_b43err
	mov	w20, #0
	b	LBB0_13
LBB0_11:
	ldr	w1, [x27]
LBB0_12:
	mov	x0, x19
	mov	w2, #-2
	bl	_b43_radio_mask
LBB0_13:
	mov	x0, x20
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_R2057_RCCAL_MASTER,4,2         ; @R2057_RCCAL_MASTER
	.comm	_R2057_RCCAL_TRC0,4,2           ; @R2057_RCCAL_TRC0
	.comm	_R2057v7_RCCAL_MASTER,4,2       ; @R2057v7_RCCAL_MASTER
	.comm	_R2057_RCCAL_X1,4,2             ; @R2057_RCCAL_X1
	.comm	_R2057_RCCAL_START_R1_Q1_P1,4,2 ; @R2057_RCCAL_START_R1_Q1_P1
	.comm	_R2057_RCCAL_DONE_OSCCAP,4,2    ; @R2057_RCCAL_DONE_OSCCAP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Radio 0x2057 rccal timeout\n"

l_.str.1:                               ; @.str.1
	.asciz	"Radio 0x2057 rcal timeout\n"

	.no_dead_strip	_b43_radio_2057_rccal
.subsections_via_symbols
