	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vpu_dec_init                   ## -- Begin function vpu_dec_init
	.p2align	4, 0x90
_vpu_dec_init:                          ## @vpu_dec_init
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	callq	_mtk_vcodec_debug_enter
	leaq	12(%rbx), %rdi
	callq	_init_waitqueue_head
	movl	8(%rbx), %edi
	movl	(%rbx), %edx
	movl	4(%rbx), %esi
	leaq	L_.str(%rip), %rcx
	xorl	%r8d, %r8d
	callq	_vpu_ipi_register
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %r14d
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_mtk_vcodec_err
	jmp	LBB0_3
LBB0_2:
	leaq	-32(%rbp), %r14
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$16, %edx
	callq	_memset
	movq	_AP_IPIMSG_DEC_INIT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -24(%rbp)
	movq	%rbx, -32(%rbp)
	leaq	L_.str.2(%rip), %rsi
	movq	%rbx, %rdi
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_mtk_vcodec_debug
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movl	$16, %edx
	callq	_vcodec_vpu_send_msg
	movl	%eax, %r14d
	leaq	L_.str.3(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_mtk_vcodec_debug
LBB0_3:
	movl	%r14d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"vdec"

L_.str.1:                               ## @.str.1
	.asciz	"vpu_ipi_register fail status=%d"

	.comm	_AP_IPIMSG_DEC_INIT,4,2         ## @AP_IPIMSG_DEC_INIT
L_.str.2:                               ## @.str.2
	.asciz	"vdec_inst=%p"

L_.str.3:                               ## @.str.3
	.asciz	"- ret=%d"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vpu_dec_init                   ; -- Begin function vpu_dec_init
	.p2align	2
_vpu_dec_init:                          ; @vpu_dec_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_mtk_vcodec_debug_enter
	add	x0, x19, #12
	bl	_init_waitqueue_head
	ldp	w1, w0, [x19, #4]
	ldr	w2, [x19]
Lloh0:
	adrp	x3, l_.str@PAGE
Lloh1:
	add	x3, x3, l_.str@PAGEOFF
	mov	x4, #0
	bl	_vpu_ipi_register
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	bl	_mtk_vcodec_err
	b	LBB0_3
LBB0_2:
	add	x0, sp, #16
	mov	w1, #0
	mov	w2, #16
	bl	_memset
Lloh4:
	adrp	x8, _AP_IPIMSG_DEC_INIT@GOTPAGE
Lloh5:
	ldr	x8, [x8, _AP_IPIMSG_DEC_INIT@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	str	w8, [sp, #24]
	str	x19, [sp, #16]
	str	x19, [sp]
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_mtk_vcodec_debug
	add	x1, sp, #16
	mov	x0, x19
	mov	w2, #16
	bl	_vcodec_vpu_send_msg
	mov	x20, x0
	str	x20, [sp]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_mtk_vcodec_debug
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"vdec"

l_.str.1:                               ; @.str.1
	.asciz	"vpu_ipi_register fail status=%d"

	.comm	_AP_IPIMSG_DEC_INIT,4,2         ; @AP_IPIMSG_DEC_INIT
l_.str.2:                               ; @.str.2
	.asciz	"vdec_inst=%p"

l_.str.3:                               ; @.str.3
	.asciz	"- ret=%d"

.subsections_via_symbols
