	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function switch_asic
_switch_asic:                           ## @switch_asic
	.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
	xorl	%r15d, %r15d
	cmpq	%rsi, 8(%rdi)
	je	LBB0_7
## %bb.1:
	movq	%rsi, %r12
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movl	(%rax), %edi
	movq	_MONITOR_ARRAY_SIZE@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_kmemdup
	testq	%rax, %rax
	je	LBB0_2
## %bb.4:
	movq	%rax, %r14
	movq	(%rbx), %rax
	movl	(%rax), %edi
	movq	_ECHOGAIN_MUTED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r13), %edx
	callq	_memset
	movq	_DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movq	%r12, %rdx
	callq	_load_asic_generic
	testq	%rax, %rax
	js	LBB0_5
## %bb.6:
	movq	%r12, 8(%rbx)
	movq	(%rbx), %rax
	movl	(%rax), %edi
	movl	(%r13), %edx
	movq	%r14, %rsi
	callq	_memcpy
	movq	%r14, %rdi
	callq	_kfree
	jmp	LBB0_7
LBB0_2:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_5:
	movq	(%rbx), %rax
	movl	(%rax), %edi
	movl	(%r13), %edx
	movq	%r14, %rsi
	callq	_memcpy
	movq	%r14, %rdi
	callq	_kfree
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_3:
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_7:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MONITOR_ARRAY_SIZE,4,2         ## @MONITOR_ARRAY_SIZE
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ECHOGAIN_MUTED,4,2             ## @ECHOGAIN_MUTED
	.comm	_DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC,4,2 ## @DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_switch_asic
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function switch_asic
_switch_asic:                           ; @switch_asic
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	ldr	x8, [x0, #8]
	cmp	x8, x1
	b.eq	LBB0_4
; %bb.1:
	mov	x21, x1
	mov	x20, x0
	ldr	x8, [x0]
	ldr	w0, [x8]
Lloh0:
	adrp	x22, _MONITOR_ARRAY_SIZE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _MONITOR_ARRAY_SIZE@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh2:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	bl	_kmemdup
	cbz	x0, LBB0_5
; %bb.2:
	mov	x19, x0
	ldr	x8, [x20]
	ldr	w0, [x8]
Lloh5:
	adrp	x8, _ECHOGAIN_MUTED@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ECHOGAIN_MUTED@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	ldr	w2, [x22]
	bl	_memset
Lloh8:
	adrp	x8, _DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, x21
	bl	_load_asic_generic
	tbnz	x0, #63, LBB0_6
; %bb.3:
	str	x21, [x20, #8]
	ldr	x8, [x20]
	ldr	w0, [x8]
	ldr	w2, [x22]
	mov	x1, x19
	bl	_memcpy
	mov	x0, x19
	bl	_kfree
LBB0_4:
	mov	w0, #0
	b	LBB0_8
LBB0_5:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_7
LBB0_6:
	ldr	x8, [x20]
	ldr	w0, [x8]
	ldr	w2, [x22]
	mov	x1, x19
	bl	_memcpy
	mov	x0, x19
	bl	_kfree
Lloh13:
	adrp	x8, _EIO@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_7:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_MONITOR_ARRAY_SIZE,4,2         ; @MONITOR_ARRAY_SIZE
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ECHOGAIN_MUTED,4,2             ; @ECHOGAIN_MUTED
	.comm	_DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC,4,2 ; @DSP_FNC_LOAD_LAYLA24_EXTERNAL_ASIC
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_switch_asic
.subsections_via_symbols
