	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wcn36xx_smd_start              ## -- Begin function wcn36xx_smd_start
	.p2align	4, 0x90
_wcn36xx_smd_start:                     ## @wcn36xx_smd_start
	.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
	subq	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_mutex_lock
	movq	_WCN36XX_HAL_START_REQ@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	-56(%rbp), %rax
	movq	%rax, 16(%rsp)
	movups	-72(%rbp), %xmm0
	movups	%xmm0, (%rsp)
	callq	_INIT_HAL_MSG
	movq	_DRIVER_TYPE_PRODUCTION@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)
	movq	$0, -64(%rbp)
	movq	8(%r14), %rdi
	movq	-56(%rbp), %rax
	movq	%rax, 16(%rsp)
	movups	-72(%rbp), %xmm0
	movups	%xmm0, (%rsp)
	callq	_PREPARE_HAL_BUF
	movq	8(%r14), %rbx
	movq	(%rbx), %r15
	movq	%r15, -48(%rbp)
	movq	_wcn36xx_cfg_vals@GOTPCREL(%rip), %r13
	movq	(%r13), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	jle	LBB0_6
## %bb.1:
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	xorl	%r12d, %r12d
	leaq	-48(%rbp), %r15
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rax
	movl	(%rax,%r12,8), %ecx
	movl	4(%rax,%r12,8), %edx
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_put_cfg_tlv_u32
	testl	%eax, %eax
	jne	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%r12
	movq	(%r13), %rdi
	callq	_ARRAY_SIZE
	cltq
	cmpq	%rax, %r12
	jl	LBB0_3
## %bb.5:
	movq	-48(%rbp), %r15
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
LBB0_6:
	movq	%r15, (%rbx)
	movq	-48(%rbp), %rax
	addq	$-24, %rax
	movq	%rax, 8(%rbx)
	movq	_WCN36XX_DBG_HAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	-56(%rbp), %edx
	leaq	L_.str(%rip), %rsi
	callq	_wcn36xx_dbg
	movq	(%rbx), %rsi
	movq	%r14, %rdi
	callq	_wcn36xx_smd_send_and_wait
	testl	%eax, %eax
	je	LBB0_8
## %bb.7:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_wcn36xx_err
	jmp	LBB0_11
LBB0_4:
	movl	%eax, %ebx
	jmp	LBB0_11
LBB0_8:
	movq	8(%r14), %rsi
	movl	4(%r14), %edx
	movq	%r14, %rdi
	callq	_wcn36xx_smd_start_rsp
	testl	%eax, %eax
	je	LBB0_9
## %bb.10:
	movl	%eax, %ebx
	leaq	L_.str.2(%rip), %rdi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_wcn36xx_err
	jmp	LBB0_11
LBB0_9:
	xorl	%ebx, %ebx
LBB0_11:
	movq	%r14, %rdi
	callq	_mutex_unlock
	movl	%ebx, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_WCN36XX_HAL_START_REQ,4,2      ## @WCN36XX_HAL_START_REQ
	.comm	_DRIVER_TYPE_PRODUCTION,4,2     ## @DRIVER_TYPE_PRODUCTION
	.comm	_wcn36xx_cfg_vals,8,3           ## @wcn36xx_cfg_vals
	.comm	_WCN36XX_DBG_HAL,4,2            ## @WCN36XX_DBG_HAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"hal start type %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"Sending hal_start failed\n"

L_.str.2:                               ## @.str.2
	.asciz	"hal_start 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_start              ; -- Begin function wcn36xx_smd_start
	.p2align	2
_wcn36xx_smd_start:                     ; @wcn36xx_smd_start
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x19, x0
	bl	_mutex_lock
Lloh0:
	adrp	x8, _WCN36XX_HAL_START_REQ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WCN36XX_HAL_START_REQ@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	str	xzr, [sp, #16]
	add	x0, sp, #8
	bl	_INIT_HAL_MSG
Lloh3:
	adrp	x8, _DRIVER_TYPE_PRODUCTION@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DRIVER_TYPE_PRODUCTION@GOTPAGEOFF]
Lloh5:
	ldr	w20, [x8]
	ldr	x0, [x19, #8]
	str	xzr, [sp, #16]
	str	w20, [sp, #24]
	add	x1, sp, #8
	bl	_PREPARE_HAL_BUF
	ldr	x22, [x19, #8]
	ldr	x21, [x22]
	str	x21, [sp, #8]
Lloh6:
	adrp	x23, _wcn36xx_cfg_vals@GOTPAGE
Lloh7:
	ldr	x23, [x23, _wcn36xx_cfg_vals@GOTPAGEOFF]
	ldr	x0, [x23]
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_5
; %bb.1:
	mov	x24, #0
	mov	x25, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x23]
	add	x8, x8, x24
	ldp	w3, w2, [x8]
	add	x1, sp, #8
	mov	x0, x19
	bl	_put_cfg_tlv_u32
	cbnz	w0, LBB0_7
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x25, x25, #1
	ldr	x0, [x23]
	bl	_ARRAY_SIZE
	add	x24, x24, #8
	cmp	x25, w0, sxtw
	b.lt	LBB0_2
; %bb.4:
	ldr	x21, [sp, #8]
LBB0_5:
	str	x21, [x22]
	ldr	x8, [sp, #8]
	sub	x8, x8, #24
	str	x8, [x22, #8]
Lloh8:
	adrp	x8, _WCN36XX_DBG_HAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _WCN36XX_DBG_HAL@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_wcn36xx_dbg
	ldr	x1, [x22]
	mov	x0, x19
	bl	_wcn36xx_smd_send_and_wait
	cbz	w0, LBB0_8
; %bb.6:
	mov	x21, x0
Lloh13:
	adrp	x0, l_.str.1@PAGE
Lloh14:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_10
LBB0_7:
	mov	x21, x0
	b	LBB0_11
LBB0_8:
	ldr	x1, [x19, #8]
	ldr	w2, [x19, #4]
	mov	x0, x19
	bl	_wcn36xx_smd_start_rsp
	mov	x21, x0
	cbz	w0, LBB0_11
; %bb.9:
	str	x21, [sp]
Lloh15:
	adrp	x0, l_.str.2@PAGE
Lloh16:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_10:
	bl	_wcn36xx_err
LBB0_11:
	mov	x0, x19
	bl	_mutex_unlock
	mov	x0, x21
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_WCN36XX_HAL_START_REQ,4,2      ; @WCN36XX_HAL_START_REQ
	.comm	_DRIVER_TYPE_PRODUCTION,4,2     ; @DRIVER_TYPE_PRODUCTION
	.comm	_wcn36xx_cfg_vals,8,3           ; @wcn36xx_cfg_vals
	.comm	_WCN36XX_DBG_HAL,4,2            ; @WCN36XX_DBG_HAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"hal start type %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"Sending hal_start failed\n"

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

.subsections_via_symbols
