	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ssm2602_hw_params
_ssm2602_hw_params:                     ## @ssm2602_hw_params
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, %r14
	movq	(%rdi), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movq	(%rax), %r13
	movq	(%r13), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	8(%r13), %r15
	movq	_SSM2602_IFACE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_ssm2602_read_reg_cache
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	8(%r15), %ebx
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	callq	_params_rate
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_get_coeff
	cmpq	%r14, (%r15)
	je	LBB0_1
## %bb.2:
	movl	%eax, %ebx
	movq	_coeff_div@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	callq	_ARRAY_SIZE
	cmpl	%eax, %ebx
	jne	LBB0_4
## %bb.3:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_12
LBB0_1:
	leaq	L_.str(%rip), %rsi
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_dev_dbg
	jmp	LBB0_11
LBB0_4:
	movl	-44(%rbp), %r15d                ## 4-byte Reload
	andl	$65523, %r15d                   ## imm = 0xFFF3
	movq	(%r14), %rax
	movslq	%ebx, %rcx
	leaq	(%rcx,%rcx,2), %rcx
	movl	(%rax,%rcx,4), %edx
	movl	4(%rax,%rcx,4), %ebx
	shll	$2, %edx
	addl	%ebx, %ebx
	orl	%edx, %ebx
	orl	8(%rax,%rcx,4), %ebx
	movq	_SSM2602_ACTIVE@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_ssm2602_write
	movq	_SSM2602_SRATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	%ebx, %edx
	callq	_ssm2602_write
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_params_format
	cmpl	$128, %eax
	je	LBB0_9
## %bb.5:
	cmpl	$129, %eax
	je	LBB0_8
## %bb.6:
	cmpl	$130, %eax
	jne	LBB0_10
## %bb.7:
	orl	$4, %r15d
	jmp	LBB0_10
LBB0_9:
	orl	$12, %r15d
	jmp	LBB0_10
LBB0_8:
	orl	$8, %r15d
LBB0_10:
	movq	_SSM2602_IFACE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	%r15d, %edx
	callq	_ssm2602_write
	movl	(%r14), %esi
	movq	_ACTIVE_ACTIVATE_CODEC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	callq	_ssm2602_write
LBB0_11:
	xorl	%eax, %eax
LBB0_12:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SSM2602_IFACE,4,2              ## @SSM2602_IFACE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Ignoring hw_params for slave substream\n"

	.comm	_coeff_div,8,3                  ## @coeff_div
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_SSM2602_ACTIVE,4,2             ## @SSM2602_ACTIVE
	.comm	_SSM2602_SRATE,4,2              ## @SSM2602_SRATE
	.comm	_ACTIVE_ACTIVATE_CODEC,4,2      ## @ACTIVE_ACTIVATE_CODEC
	.no_dead_strip	_ssm2602_hw_params
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ssm2602_hw_params
_ssm2602_hw_params:                     ; @ssm2602_hw_params
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x20, x1
	mov	x24, x0
	ldr	x8, [x0]
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	x19, [x8]
	ldp	x22, x26, [x19]
Lloh0:
	adrp	x25, _SSM2602_IFACE@GOTPAGE
Lloh1:
	ldr	x25, [x25, _SSM2602_IFACE@GOTPAGEOFF]
	ldr	w1, [x25]
	mov	x0, x19
	bl	_ssm2602_read_reg_cache
	mov	x21, x0
	ldr	w23, [x26, #8]
	mov	x0, x20
	bl	_params_rate
	mov	x1, x0
	mov	x0, x23
	bl	_get_coeff
	ldr	x8, [x26]
	cmp	x8, x24
	b.eq	LBB0_3
; %bb.1:
	mov	x23, x0
Lloh2:
	adrp	x22, _coeff_div@GOTPAGE
Lloh3:
	ldr	x22, [x22, _coeff_div@GOTPAGEOFF]
	ldr	x0, [x22]
	bl	_ARRAY_SIZE
	cmp	w23, w0
	b.ne	LBB0_4
; %bb.2:
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_6
LBB0_3:
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	bl	_dev_dbg
	b	LBB0_5
LBB0_4:
	mov	w8, #65523
	and	w24, w21, w8
	ldr	x8, [x22]
	mov	w9, #12
	smaddl	x8, w23, w9, x8
	ldp	w9, w10, [x8]
	lsl	w10, w10, #1
	orr	w9, w10, w9, lsl #2
	ldr	w8, [x8, #8]
	orr	w21, w9, w8
Lloh9:
	adrp	x22, _SSM2602_ACTIVE@GOTPAGE
Lloh10:
	ldr	x22, [x22, _SSM2602_ACTIVE@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	mov	w2, #0
	bl	_ssm2602_write
Lloh11:
	adrp	x8, _SSM2602_SRATE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SSM2602_SRATE@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x21
	bl	_ssm2602_write
	mov	x0, x20
	bl	_params_format
	orr	w8, w24, #0xc
	orr	w9, w24, #0x8
	orr	w10, w24, #0x4
	cmp	w0, #130
	csel	w10, w24, w10, ne
	cmp	w0, #129
	csel	w9, w9, w10, eq
	cmp	w0, #128
	csel	w2, w8, w9, eq
	ldr	w1, [x25]
	mov	x0, x19
	bl	_ssm2602_write
	ldr	w1, [x22]
Lloh14:
	adrp	x8, _ACTIVE_ACTIVATE_CODEC@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ACTIVE_ACTIVATE_CODEC@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_ssm2602_write
LBB0_5:
	mov	w0, #0
LBB0_6:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_SSM2602_IFACE,4,2              ; @SSM2602_IFACE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Ignoring hw_params for slave substream\n"

	.comm	_coeff_div,8,3                  ; @coeff_div
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_SSM2602_ACTIVE,4,2             ; @SSM2602_ACTIVE
	.comm	_SSM2602_SRATE,4,2              ; @SSM2602_SRATE
	.comm	_ACTIVE_ACTIVATE_CODEC,4,2      ; @ACTIVE_ACTIVATE_CODEC
	.no_dead_strip	_ssm2602_hw_params
.subsections_via_symbols
