	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath10k_qmi_send_cal_report_req
_ath10k_qmi_send_cal_report_req:        ## @ath10k_qmi_send_cal_report_req
	.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	$56, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -48(%rbp)
	movaps	%xmm0, -64(%rbp)
	movq	16(%rdi), %r14
	movq	_wlfw_cal_report_resp_msg_v01_ei@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-32(%rbp), %rsi
	leaq	-48(%rbp), %rcx
	callq	_qmi_txn_init
	testl	%eax, %eax
	js	LBB0_7
## %bb.1:
	movq	_QMI_WLFW_MAX_NUM_CAL_V01@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	testq	%rax, %rax
	jle	LBB0_8
## %bb.2:
	movq	8(%r15), %rcx
	addq	$16, %rcx
	xorl	%esi, %esi
	xorl	%edx, %edx
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_4 Depth=1
	incq	%rsi
	addq	$24, %rcx
	cmpq	%rax, %rsi
	jge	LBB0_9
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$0, (%rcx)
	je	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpq	$0, -8(%rcx)
	je	LBB0_3
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	incl	%edx
	jmp	LBB0_3
LBB0_8:
	xorl	%edx, %edx
LBB0_9:
	movl	%edx, -64(%rbp)
	movq	_QMI_WLFW_CAL_REPORT_REQ_V01@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	_wlfw_cal_report_req_msg_v01_ei@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	leaq	-64(%rbp), %rax
	movq	%rax, (%rsp)
	leaq	-32(%rbp), %rdx
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_qmi_send_request
	testl	%eax, %eax
	js	LBB0_13
## %bb.10:
	movq	_ATH10K_QMI_TIMEOUT@GOTPCREL(%rip), %rax
	movq	_HZ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	imull	(%rax), %esi
	leaq	-32(%rbp), %rdi
	callq	_qmi_txn_wait
	testl	%eax, %eax
	js	LBB0_7
## %bb.11:
	movq	-48(%rbp), %rax
	movq	_QMI_RESULT_SUCCESS_V01@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_15
## %bb.12:
	movq	_ATH10K_DBG_QMI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	movq	%r14, %rdi
	callq	_ath10k_dbg
	xorl	%ebx, %ebx
	jmp	LBB0_16
LBB0_7:
	movl	%eax, %ebx
	jmp	LBB0_16
LBB0_13:
	movl	%eax, %ebx
	leaq	-32(%rbp), %rdi
	callq	_qmi_txn_cancel
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_ath10k_err
	jmp	LBB0_16
LBB0_15:
	movl	-40(%rbp), %edx
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_ath10k_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_16:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_wlfw_cal_report_resp_msg_v01_ei,4,2 ## @wlfw_cal_report_resp_msg_v01_ei
	.comm	_QMI_WLFW_MAX_NUM_CAL_V01,4,2   ## @QMI_WLFW_MAX_NUM_CAL_V01
	.comm	_QMI_WLFW_CAL_REPORT_REQ_V01,4,2 ## @QMI_WLFW_CAL_REPORT_REQ_V01
	.comm	_WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN,4,2 ## @WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN
	.comm	_wlfw_cal_report_req_msg_v01_ei,4,2 ## @wlfw_cal_report_req_msg_v01_ei
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to send calibration request: %d\n"

	.comm	_ATH10K_QMI_TIMEOUT,4,2         ## @ATH10K_QMI_TIMEOUT
	.comm	_HZ,4,2                         ## @HZ
	.comm	_QMI_RESULT_SUCCESS_V01,8,3     ## @QMI_RESULT_SUCCESS_V01
L_.str.1:                               ## @.str.1
	.asciz	"calibration request rejected: %d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ATH10K_DBG_QMI,4,2             ## @ATH10K_DBG_QMI
L_.str.2:                               ## @.str.2
	.asciz	"qmi cal report request completed\n"

	.no_dead_strip	_ath10k_qmi_send_cal_report_req
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath10k_qmi_send_cal_report_req
_ath10k_qmi_send_cal_report_req:        ; @ath10k_qmi_send_cal_report_req
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x20, x0
	stp	xzr, xzr, [sp, #32]
	stp	xzr, xzr, [sp, #16]
	ldr	x19, [x0, #16]
Lloh0:
	adrp	x8, _wlfw_cal_report_resp_msg_v01_ei@GOTPAGE
Lloh1:
	ldr	x8, [x8, _wlfw_cal_report_resp_msg_v01_ei@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	add	x1, sp, #8
	add	x3, sp, #32
	bl	_qmi_txn_init
	tbnz	w0, #31, LBB0_11
; %bb.1:
Lloh3:
	adrp	x8, _QMI_WLFW_MAX_NUM_CAL_V01@GOTPAGE
Lloh4:
	ldr	x8, [x8, _QMI_WLFW_MAX_NUM_CAL_V01@GOTPAGEOFF]
Lloh5:
	ldrsw	x9, [x8]
	cmp	w9, #1
	b.lt	LBB0_6
; %bb.2:
	mov	x10, #0
	mov	w8, #0
	ldr	x11, [x20, #8]
	add	x11, x11, #16
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x10, x10, #1
	add	x11, x11, #24
	cmp	x10, x9
	b.ge	LBB0_7
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x12, [x11]
	cbz	x12, LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldur	x12, [x11, #-8]
	cmp	x12, #0
	cinc	w8, w8, ne
	b	LBB0_3
LBB0_6:
	mov	w8, #0
LBB0_7:
	str	w8, [sp, #16]
Lloh6:
	adrp	x8, _QMI_WLFW_CAL_REPORT_REQ_V01@GOTPAGE
Lloh7:
	ldr	x8, [x8, _QMI_WLFW_CAL_REPORT_REQ_V01@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
Lloh9:
	adrp	x8, _WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN@GOTPAGEOFF]
Lloh11:
	ldr	w4, [x8]
Lloh12:
	adrp	x8, _wlfw_cal_report_req_msg_v01_ei@GOTPAGE
Lloh13:
	ldr	x8, [x8, _wlfw_cal_report_req_msg_v01_ei@GOTPAGEOFF]
Lloh14:
	ldr	w5, [x8]
	add	x2, sp, #8
	add	x6, sp, #16
	mov	x0, x20
	mov	x1, #0
	bl	_qmi_send_request
	tbnz	w0, #31, LBB0_12
; %bb.8:
Lloh15:
	adrp	x8, _ATH10K_QMI_TIMEOUT@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ATH10K_QMI_TIMEOUT@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
Lloh18:
	adrp	x9, _HZ@GOTPAGE
Lloh19:
	ldr	x9, [x9, _HZ@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	mul	w1, w9, w8
	add	x0, sp, #8
	bl	_qmi_txn_wait
	tbnz	w0, #31, LBB0_11
; %bb.9:
	ldr	x8, [sp, #32]
Lloh21:
	adrp	x9, _QMI_RESULT_SUCCESS_V01@GOTPAGE
Lloh22:
	ldr	x9, [x9, _QMI_RESULT_SUCCESS_V01@GOTPAGEOFF]
Lloh23:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_13
; %bb.10:
Lloh24:
	adrp	x8, _ATH10K_DBG_QMI@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ATH10K_DBG_QMI@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
Lloh27:
	adrp	x2, l_.str.2@PAGE
Lloh28:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_ath10k_dbg
	mov	w21, #0
	b	LBB0_14
LBB0_11:
	mov	x21, x0
	b	LBB0_14
LBB0_12:
	mov	x21, x0
	add	x0, sp, #8
	bl	_qmi_txn_cancel
Lloh29:
	adrp	x1, l_.str@PAGE
Lloh30:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x21
	bl	_ath10k_err
	b	LBB0_14
LBB0_13:
	ldr	w2, [sp, #40]
Lloh31:
	adrp	x1, l_.str.1@PAGE
Lloh32:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_ath10k_err
Lloh33:
	adrp	x8, _EINVAL@GOTPAGE
Lloh34:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_14:
	mov	x0, x21
	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
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_wlfw_cal_report_resp_msg_v01_ei,4,2 ; @wlfw_cal_report_resp_msg_v01_ei
	.comm	_QMI_WLFW_MAX_NUM_CAL_V01,4,2   ; @QMI_WLFW_MAX_NUM_CAL_V01
	.comm	_QMI_WLFW_CAL_REPORT_REQ_V01,4,2 ; @QMI_WLFW_CAL_REPORT_REQ_V01
	.comm	_WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN,4,2 ; @WLFW_CAL_REPORT_REQ_MSG_V01_MAX_MSG_LEN
	.comm	_wlfw_cal_report_req_msg_v01_ei,4,2 ; @wlfw_cal_report_req_msg_v01_ei
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to send calibration request: %d\n"

	.comm	_ATH10K_QMI_TIMEOUT,4,2         ; @ATH10K_QMI_TIMEOUT
	.comm	_HZ,4,2                         ; @HZ
	.comm	_QMI_RESULT_SUCCESS_V01,8,3     ; @QMI_RESULT_SUCCESS_V01
l_.str.1:                               ; @.str.1
	.asciz	"calibration request rejected: %d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ATH10K_DBG_QMI,4,2             ; @ATH10K_DBG_QMI
l_.str.2:                               ; @.str.2
	.asciz	"qmi cal report request completed\n"

	.no_dead_strip	_ath10k_qmi_send_cal_report_req
.subsections_via_symbols
