	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wcn36xx_smd_exit_bmps          ## -- Begin function wcn36xx_smd_exit_bmps
	.p2align	4, 0x90
_wcn36xx_smd_exit_bmps:                 ## @wcn36xx_smd_exit_bmps
	.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
	movq	%rdi, %r12
	movq	%rsi, %rdi
	callq	_wcn36xx_vif_to_priv
	movq	%rax, %rbx
	movq	%r12, %rdi
	callq	_mutex_lock
	movq	_WCN36XX_HAL_EXIT_BMPS_REQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r14d, %r14d
	xorl	%edi, %edi
	callq	_INIT_HAL_MSG
	movl	8(%r12), %edi
	movl	(%rbx), %esi
	shlq	$32, %rsi
	callq	_PREPARE_HAL_BUF
	movq	%r12, %rdi
	callq	_wcn36xx_smd_send_and_wait
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_wcn36xx_err
	movl	%ebx, %r14d
	jmp	LBB0_4
LBB0_2:
	movl	4(%r12), %esi
	movl	8(%r12), %edi
	callq	_wcn36xx_smd_rsp_status_check
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	movl	%eax, %r15d
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_wcn36xx_err
	movl	%r15d, %r14d
LBB0_4:
	movq	%r12, %rdi
	callq	_mutex_unlock
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_WCN36XX_HAL_EXIT_BMPS_REQ,4,2  ## @WCN36XX_HAL_EXIT_BMPS_REQ
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Sending hal_exit_bmps failed\n"

L_.str.1:                               ## @.str.1
	.asciz	"hal_exit_bmps response failed err=%d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wcn36xx_smd_exit_bmps          ; -- Begin function wcn36xx_smd_exit_bmps
	.p2align	2
_wcn36xx_smd_exit_bmps:                 ; @wcn36xx_smd_exit_bmps
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	mov	x0, x1
	bl	_wcn36xx_vif_to_priv
	mov	x20, x0
	mov	x0, x19
	bl	_mutex_lock
Lloh0:
	adrp	x8, _WCN36XX_HAL_EXIT_BMPS_REQ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WCN36XX_HAL_EXIT_BMPS_REQ@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, #0
	bl	_INIT_HAL_MSG
	ldr	w0, [x19, #8]
	ldr	w8, [x20]
	lsl	x1, x8, #32
	bl	_PREPARE_HAL_BUF
	mov	x0, x19
	bl	_wcn36xx_smd_send_and_wait
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_4
LBB0_2:
	ldp	w1, w0, [x19, #4]
	bl	_wcn36xx_smd_rsp_status_check
	mov	x20, x0
	cbz	w0, LBB0_5
; %bb.3:
	str	x20, [sp]
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_4:
	bl	_wcn36xx_err
LBB0_5:
	mov	x0, x19
	bl	_mutex_unlock
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_WCN36XX_HAL_EXIT_BMPS_REQ,4,2  ; @WCN36XX_HAL_EXIT_BMPS_REQ
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Sending hal_exit_bmps failed\n"

l_.str.1:                               ; @.str.1
	.asciz	"hal_exit_bmps response failed err=%d\n"

.subsections_via_symbols
